/// <summary>Method initializes the BrainCloudClient.</summary> /// <param name="serverURL">The url to the brainCloud server</param> /// <param name="secretKey">The secret key for your game /// <param name="gameId ">The game id</param> /// <param name="gameVersion The game version</param> /// <param name="cachedProfileId The profile Id</param> /// <param name="anonymousId The anonymous Id</param> public void Initialize(string serverURL, string secretKey, string gameId, string gameVersion) { // TODO: what is our default c# platform? Platform platform = Platform.Windows; #if !(DOT_NET) platform = Platform.FromUnityRuntime(); #endif // set up braincloud which does the message handling m_bc.Initialize(serverURL, gameId, secretKey); m_gameVersion = gameVersion; m_platform = platform; //setup region/country code if (Util.GetCurrentCountryCode() == string.Empty) { #if (DOT_NET) Util.SetCurrentCountryCode(RegionInfo.CurrentRegion.TwoLetterISORegionName); #else Util.SetCurrentCountryCode(RegionLocale.UsersCountryLocale); #endif } m_initialized = true; }
/// <summary>Method initializes the BrainCloudClient.</summary> /// <param name="serverURL">The url to the brainCloud server</param> /// <param name="secretKey">The secret key for your game /// <param name="gameId ">The game id</param> /// <param name="gameVersion The game version</param> /// <param name="cachedProfileId The profile Id</param> /// <param name="anonymousId The anonymous Id</param> public void Initialize(string serverURL, string secretKey, string gameId, string gameVersion) { // TODO: what is our default c# platform? Platform platform = Platform.Windows; #if !(DOT_NET) platform = Platform.FromUnityRuntime(); #endif // set up braincloud which does the message handling m_bc.Initialize(serverURL, secretKey); m_gameId = gameId; m_gameVersion = gameVersion; m_platform = platform; m_initialized = true; }