1
This commit is contained in:
parent
3e75f8b83e
commit
b88c1cd02e
@ -48,7 +48,6 @@ type Team interface {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type TeamMgr interface {
|
type TeamMgr interface {
|
||||||
ProcessCMMsg(*cs.CsNetMsgHandler, *f5.MsgHdr)
|
|
||||||
CreateTeam(Player, *cs.CMLogin) Team
|
CreateTeam(Player, *cs.CMLogin) Team
|
||||||
GetTeamByUuid(string) Team
|
GetTeamByUuid(string) Team
|
||||||
OnEnterNewUser(Player)
|
OnEnterNewUser(Player)
|
||||||
@ -70,7 +69,6 @@ type Player interface {
|
|||||||
type PlayerMgr interface {
|
type PlayerMgr interface {
|
||||||
ProcessCMMsg(*cs.CsNetMsgHandler, *f5.MsgHdr)
|
ProcessCMMsg(*cs.CsNetMsgHandler, *f5.MsgHdr)
|
||||||
GetPlayerBySocket(f5.WspCliConn) Player
|
GetPlayerBySocket(f5.WspCliConn) Player
|
||||||
GetPlayerByAccountId(string) Player
|
|
||||||
}
|
}
|
||||||
|
|
||||||
type WspListener interface {
|
type WspListener interface {
|
||||||
|
@ -22,11 +22,12 @@ func (this *teamMgr) Init() {
|
|||||||
func (this *teamMgr) UnInit() {
|
func (this *teamMgr) UnInit() {
|
||||||
}
|
}
|
||||||
|
|
||||||
func (this *teamMgr) CreateTeam(hum common.Player, msg *cs.CMLogin) {
|
func (this *teamMgr) CreateTeam(hum common.Player, msg *cs.CMLogin) common.Team {
|
||||||
teamUuid := this.genTeamUuid(hum.GetZoneId(), hum.GetNodeId())
|
teamUuid := this.genTeamUuid(hum.GetZoneId(), hum.GetNodeId())
|
||||||
team := newTeam()
|
team := newTeam()
|
||||||
team.init(teamUuid, hum)
|
team.init(teamUuid, hum)
|
||||||
this.teamUuidHash[team.teamUuid] = team
|
this.teamUuidHash[team.teamUuid] = team
|
||||||
|
return team
|
||||||
}
|
}
|
||||||
|
|
||||||
func (this *teamMgr) genTeamUuid(zoneId int32, nodeId int32) string {
|
func (this *teamMgr) genTeamUuid(zoneId int32, nodeId int32) string {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user