1
This commit is contained in:
parent
5a819e7af4
commit
c7de963dd6
@ -11,17 +11,17 @@ type Player struct {
|
|||||||
socket f5.WspCliConn
|
socket f5.WspCliConn
|
||||||
accountId string
|
accountId string
|
||||||
sessionId string
|
sessionId string
|
||||||
chatChannel int
|
room *Room
|
||||||
privateTargetAccountId string // 私聊对象 accountId
|
|
||||||
worldChannelLastId uint64 // 世界聊天 last id
|
|
||||||
guildChannelLastId uint64 // 公会聊天 last id
|
|
||||||
privateChatLastId uint64 // 私聊 last id
|
|
||||||
}
|
}
|
||||||
|
|
||||||
func (p *Player) GetAccountId() string {
|
func (this *Player) GetAccountId() string {
|
||||||
return p.accountId
|
return this.accountId
|
||||||
}
|
}
|
||||||
|
|
||||||
func (p *Player) SendMsg(rspMsg proto.Message) {
|
func (this *Player) SendMsg(rspMsg proto.Message) {
|
||||||
wspListener.sendProxyMsg(p.socket.Conn, p.socket.SocketHandle, rspMsg)
|
wspListener.sendProxyMsg(this.socket.Conn, this.socket.SocketHandle, rspMsg)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (this *Player) GetRoom() *Room {
|
||||||
|
return this.room
|
||||||
}
|
}
|
||||||
|
@ -6,11 +6,13 @@ import (
|
|||||||
|
|
||||||
type RoomMgr struct {
|
type RoomMgr struct {
|
||||||
cs.MsgHandlerImpl
|
cs.MsgHandlerImpl
|
||||||
|
currRoomId int32
|
||||||
idHash map[int32]*Room
|
idHash map[int32]*Room
|
||||||
}
|
}
|
||||||
|
|
||||||
func (this *RoomMgr) init() {
|
func (this *RoomMgr) init() {
|
||||||
this.idHash = make(map[int32]*Room)
|
this.idHash = make(map[int32]*Room)
|
||||||
|
this.currRoomId = 10000
|
||||||
}
|
}
|
||||||
|
|
||||||
func (this *RoomMgr) unInit() {
|
func (this *RoomMgr) unInit() {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user