using Sog; namespace HttpProxyWorld { public static class HttpProxyWorldServerUtils { public const int PayTaskCount = 10; //支付行为应该不多,考虑到iap苹果服务器超级慢,多搞几个 public const int PushTaskCount = 1; public static HttpProxyWorldServerData GetHttpProxyServerData() { return ServerDataObjMgr.GetDataObj(HttpProxyWorldDataObjType.HttpProxyWorldServerData); } public static ProtoCSStructPacker GetProtoPacker() { return ProtoPackerFactory.Instance.GetProtoCSStructPacker(); } public static StructPacketSender GetPacketSender() { return GetHttpProxyServerData().m_packetSender; } public static HttpProxyMsgHandler GetMsgHandler() { return ServiceMgr.GetService(HttpProxyServiceType.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 HttpProxyWorldServerConfig GetServerConfig() { return (HttpProxyWorldServerConfig)ServerConfigMgr.Instance.m_serverConfig; } } }