using Sog; namespace HttpProxyPay { public static class HttpProxyPayServerUtils { public static uint HttpWorkThreadCount = 10; public static HttpProxyPayServerData GetHttpProxyServerData() { return ServerDataObjMgr.GetDataObj(HttpProxyPayDataObjType.HttpProxyPayServerData); } public static ProtoCSStructPacker GetProtoPacker() { return ProtoPackerFactory.Instance.GetProtoCSStructPacker(); } public static StructPacketSender GetPacketSender() { return GetHttpProxyServerData().m_packetSender; } public static HttpProxyPayMsgHandler GetMsgHandler() { return ServiceMgr.GetService(HttpProxyPayServiceType.HttpProxyMsgHandler); } public static long GetTimeSecond() { return GetHttpProxyServerData().m_app.Time.GetTimeSecond(); } public static ServerApp GetApp() { return GetHttpProxyServerData().m_app; } public static uint GetAppID() { return GetHttpProxyServerData().m_app.ServerID; } public static PlayerTable GetPlayerTable() { return ServerDataObjMgr.GetDataObj(HttpProxyPayDataObjType.PlayerTable); } //server service public static PlayerTableOp GetPlayerTableOp() { return ServiceMgr.GetService(HttpProxyPayServiceType.PlayerTableOp); } /// /// 获取服务器配置方法 /// public static HttpProxyPayServerConfig GetServerConfig() { return (HttpProxyPayServerConfig)ServerConfigMgr.Instance.m_serverConfig; } } }