/* Sog 游戏基础库 2016 by zouwei */ using System; using System.Collections.Generic; using System.Linq; using System.Threading.Tasks; using Sog; namespace Gate { public class GateServerData : IServerDataObj { //public const int MAX_SESSION_ID_COUNT = 10000000; public ServerApp m_app; public PacketSender m_packetSender; //public Queue m_freeSessionIndexID; public long SessionIDSeq; public Dictionary m_messageLimitMap; public GateServerData(ServerApp app) { m_app = app; m_packetSender = new PacketSender(); m_packetSender.Init(app.ServerID, app.GetCluster()); m_messageLimitMap = new Dictionary(); /* //申请1千万个id,加上inst id 刚好32位,24位Max是1千多万 m_freeSessionIndexID = new Queue(MAX_SESSION_ID_COUNT); for(uint i=1; i< MAX_SESSION_ID_COUNT; i++) { m_freeSessionIndexID.Enqueue(i); } */ } public override int GetDataType() { return GateDataObjType.GateServerData; } } }