消息服务优化

This commit is contained in:
hahwu 2025-12-25 09:52:06 +08:00
parent d123fc93d5
commit e21aac1c08
2 changed files with 2 additions and 2 deletions

View File

@ -10,7 +10,7 @@ var (
LogFlag = log.LstdFlags | log.Lmicroseconds
// gate conf
PendingWriteNum = 2000
PendingWriteNum = 65536
MaxMsgLen uint32 = 65536 // 16KB
HTTPTimeout = 10 * time.Second
LenMsgLen = 2

View File

@ -59,7 +59,7 @@ type TaskResult struct {
}
func (m *MessageMgr) MessageMgrInit() {
m.key = MESSAGE_MGR_KEY
m.key = MESSAGE_MGR_KEY + fmt.Sprintf("_%d", conf.Server.ServerID)
m.data = &MessageData{
MessageList: make(map[int64]*MessageList),
PlayerList: make(map[int64]int),