public static bool Init(EPlatform ePlatform, bool isUseNetModule, ILPNetMessageHandler netMessageHandler) { bool bResult = false; bResult = _InitConfig(ePlatform); if (LPError.PTF_ERROR(bResult)) { goto Exit0; } bResult = _InitLogger(); if (LPError.PTF_ERROR(bResult)) { goto Exit0; } if (isUseNetModule) { bResult = _InitNet(netMessageHandler); if (LPError.LOG_ERROR(bResult)) { goto Exit0; } } return(true); Exit0: return(false); }
private static bool _InitNet(ILPNetMessageHandler netMessageHandler) { bool bResult = false; m_NetModule = new LPNet(); if (LPError.LOG_ERROR(m_NetModule != null)) { goto Exit0; } bResult = m_NetModule.Init(netMessageHandler); if (LPError.LOG_ERROR(bResult)) { goto Exit0; } return(true); Exit0: return(false); }