コード例 #1
0
        // Token: 0x06000038 RID: 56 RVA: 0x00003434 File Offset: 0x00001834
        public static void init()
        {
            string selectAndroidAppId     = CBSettings.getSelectAndroidAppId();
            string selectAndroidAppSecret = CBSettings.getSelectAndroidAppSecret();

            CBExternal.initWithAppId(selectAndroidAppId, selectAndroidAppSecret);
        }
コード例 #2
0
 public static void Log(string message)
 {
     if (CBSettings.isLogging() && Debug.isDebugBuild)
     {
         Debug.Log(_logTag + "/" + message);
     }
 }
コード例 #3
0
        public static void OnPostProcessBuildCleanup(BuildTarget target, string path)

        {
            CBCleanup.Clean();

            CBSettings.resetSettings();
        }
コード例 #4
0
 // Token: 0x0600008E RID: 142 RVA: 0x00004E8F File Offset: 0x0000328F
 public static string getSelectAndroidAppSecret()
 {
     if (CBSettings.Instance.selectedAndroidPlatformIndex == 0)
     {
         return CBSettings.getAndroidAppSecret();
     }
     return CBSettings.getAmazonAppSecret();
 }
コード例 #5
0
 // Token: 0x06000081 RID: 129 RVA: 0x00004AB2 File Offset: 0x00002EB2
 public void SetIOSAppId(string id)
 {
     if (!CBSettings.Instance.iOSAppId.Equals(id))
     {
         CBSettings.Instance.iOSAppId = id;
         CBSettings.DirtyEditor();
     }
 }
コード例 #6
0
 // Token: 0x06000083 RID: 131 RVA: 0x00004B53 File Offset: 0x00002F53
 public void SetIOSAppSecret(string secret)
 {
     if (!CBSettings.Instance.iOSAppSecret.Equals(secret))
     {
         CBSettings.Instance.iOSAppSecret = secret;
         CBSettings.DirtyEditor();
     }
 }
コード例 #7
0
        /// Initialize the android sdk
        public static void init()
        {
            // get the AppID and AppSecret from CBSettings
            string appID     = CBSettings.getSelectAndroidAppId();
            string appSecret = CBSettings.getSelectAndroidAppSecret();

            initWithAppId(appID, appSecret);
        }
コード例 #8
0
 // Token: 0x0600007D RID: 125 RVA: 0x00004A69 File Offset: 0x00002E69
 public void SetAndroidPlatformIndex(int index)
 {
     if (this.selectedAndroidPlatformIndex != index)
     {
         this.selectedAndroidPlatformIndex = index;
         CBSettings.DirtyEditor();
     }
 }
コード例 #9
0
        /// Initialize the android sdk
        public static void init()
        {
            // get the AppID and AppSecret from CBSettings
            string appID     = CBSettings.getSelectAndroidAppId();
            string appSecret = CBSettings.getSelectAndroidAppSecret();

            // find the plugin instance
            using (var pluginClass = new AndroidJavaClass("com.chartboost.sdk.unity.CBPlugin"))
                _plugin = pluginClass.CallStatic <AndroidJavaObject>("instance");
            _plugin.Call("init", appID, appSecret);
            initialized = true;
        }
コード例 #10
0
        /// Initializes the Chartboost plugin.
        /// This must be called before using any other Chartboost features.
        public static void init()
        {
            Log("Unity : init");

            // Will verify all the id and signatures against example ones.
            CBSettings.getIOSAppId();
            CBSettings.getIOSAppSecret();
            CBSettings.getAndroidAppId();
            CBSettings.getAndroidAppSecret();
            CBSettings.getAmazonAppId();
            CBSettings.getAmazonAppSecret();
        }
コード例 #11
0
        /// Initializes the Chartboost plugin.
        /// This must be called before using any other Chartboost features.
        public static void init()
        {
            // get the AppID and AppSecret from CBSettings
            string appID     = CBSettings.getIOSAppId();
            string appSecret = CBSettings.getIOSAppSecret();

            if (Application.platform == RuntimePlatform.IPhonePlayer)
            {
                _chartBoostInit(appID, appSecret, Application.unityVersion);
            }
            initialized = true;
        }
コード例 #12
0
        /// Initializes the Chartboost plugin.
        /// This must be called before using any other Chartboost features.
        public static void init()
        {
            // get the AppID and AppSecret from CBSettings
            string appID     = CBSettings.getIOSAppId();
            string appSecret = CBSettings.getIOSAppSecret();

            if (Application.platform == RuntimePlatform.IPhonePlayer)
            {
                _chartBoostInit(appID, appSecret);
            }
            initialized = true;
            Log("iOS : init (ID:" + appID + ", Signature: " + appSecret + ")");
        }
コード例 #13
0
 // Token: 0x0600008C RID: 140 RVA: 0x00004DFC File Offset: 0x000031FC
 public static string getAmazonAppSecret()
 {
     if (CBSettings.Instance.amazonAppSecret.Equals("CB_AMAZON_APP_SIGNATURE"))
     {
         CBSettings.CredentialsWarning("CHARTBOOST: You are using the Chartboost {0} example {1}! Go to the Chartboost dashboard and replace these with an App ID & App Signature from your account! If you need help, email us: [email protected]", "Amazon", "App Signature");
         return "90654a340386c9fb8de33315e4210d7c09989c43";
     }
     if (CBSettings.Instance.amazonAppSecret.Equals(string.Empty))
     {
         CBSettings.CredentialsWarning("CHARTBOOST: You are using an empty string for the {0} {1}! Go to the Chartboost dashboard and replace these with an App ID & App Signature from your account! If you need help, email us: [email protected]", "Amazon", "App Signature");
     }
     return CBSettings.Instance.amazonAppSecret;
 }
コード例 #14
0
 // Token: 0x06000086 RID: 134 RVA: 0x00004C1C File Offset: 0x0000301C
 public static string getAndroidAppId()
 {
     if (CBSettings.Instance.androidAppId.Equals("CB_ANDROID_APP_ID"))
     {
         CBSettings.CredentialsWarning("CHARTBOOST: You are using the Chartboost {0} example {1}! Go to the Chartboost dashboard and replace these with an App ID & App Signature from your account! If you need help, email us: [email protected]", "Android", "App ID");
         return "4f7b433509b6025804000002";
     }
     if (CBSettings.Instance.androidAppId.Equals(string.Empty))
     {
         CBSettings.CredentialsWarning("CHARTBOOST: You are using an empty string for the {0} {1}! Go to the Chartboost dashboard and replace these with an App ID & App Signature from your account! If you need help, email us: [email protected]", "Android", "App ID");
     }
     return CBSettings.Instance.androidAppId;
 }
コード例 #15
0
 // Token: 0x0600008A RID: 138 RVA: 0x00004D5C File Offset: 0x0000315C
 public static string getAmazonAppId()
 {
     if (CBSettings.Instance.amazonAppId.Equals("CB_AMAZON_APP_ID"))
     {
         CBSettings.CredentialsWarning("CHARTBOOST: You are using the Chartboost {0} example {1}! Go to the Chartboost dashboard and replace these with an App ID & App Signature from your account! If you need help, email us: [email protected]", "Amazon", "App ID");
         return "542ca35d1873da32dbc90488";
     }
     if (CBSettings.Instance.amazonAppId.Equals(string.Empty))
     {
         CBSettings.CredentialsWarning("CHARTBOOST: You are using an empty string for the {0} {1}! Go to the Chartboost dashboard and replace these with an App ID & App Signature from your account! If you need help, email us: [email protected]", "Amazon", "App ID");
     }
     return CBSettings.Instance.amazonAppId;
 }
コード例 #16
0
 // Token: 0x06000088 RID: 136 RVA: 0x00004CBC File Offset: 0x000030BC
 public static string getAndroidAppSecret()
 {
     if (CBSettings.Instance.androidAppSecret.Equals("CB_ANDROID_APP_SIGNATURE"))
     {
         CBSettings.CredentialsWarning("CHARTBOOST: You are using the Chartboost {0} example {1}! Go to the Chartboost dashboard and replace these with an App ID & App Signature from your account! If you need help, email us: [email protected]", "Android", "App Signature");
         return "dd2d41b69ac01b80f443f5b6cf06096d457f82bd";
     }
     if (CBSettings.Instance.androidAppSecret.Equals(string.Empty))
     {
         CBSettings.CredentialsWarning("CHARTBOOST: You are using an empty string for the {0} {1}! Go to the Chartboost dashboard and replace these with an App ID & App Signature from your account! If you need help, email us: [email protected]", "Android", "App Signature");
     }
     return CBSettings.Instance.androidAppSecret;
 }
コード例 #17
0
 // Token: 0x06000082 RID: 130 RVA: 0x00004ADC File Offset: 0x00002EDC
 public static string getIOSAppId()
 {
     if (CBSettings.Instance.iOSAppId.Equals("CB_IOS_APP_ID"))
     {
         CBSettings.CredentialsWarning("CHARTBOOST: You are using the Chartboost {0} example {1}! Go to the Chartboost dashboard and replace these with an App ID & App Signature from your account! If you need help, email us: [email protected]", "IOS", "App ID");
         return "4f21c409cd1cb2fb7000001b";
     }
     if (CBSettings.Instance.iOSAppId.Equals(string.Empty))
     {
         CBSettings.CredentialsWarning("CHARTBOOST: You are using an empty string for the {0} {1}! Go to the Chartboost dashboard and replace these with an App ID & App Signature from your account! If you need help, email us: [email protected]", "IOS", "App ID");
     }
     return CBSettings.Instance.iOSAppId;
 }
コード例 #18
0
 // Token: 0x06000084 RID: 132 RVA: 0x00004B7C File Offset: 0x00002F7C
 public static string getIOSAppSecret()
 {
     if (CBSettings.Instance.iOSAppSecret.Equals("CB_IOS_APP_SIGNATURE"))
     {
         CBSettings.CredentialsWarning("CHARTBOOST: You are using the Chartboost {0} example {1}! Go to the Chartboost dashboard and replace these with an App ID & App Signature from your account! If you need help, email us: [email protected]", "IOS", "App Signature");
         return "92e2de2fd7070327bdeb54c15a5295309c6fcd2d";
     }
     if (CBSettings.Instance.iOSAppSecret.Equals(string.Empty))
     {
         CBSettings.CredentialsWarning("CHARTBOOST: You are using an empty string for the {0} {1}! Go to the Chartboost dashboard and replace these with an App ID & App Signature from your account! If you need help, email us: [email protected]", "IOS", "App Signature");
     }
     return CBSettings.Instance.iOSAppSecret;
 }
コード例 #19
0
        /// Initializes the Chartboost plugin.

        /// This must be called before using any other Chartboost features.

        public static void init()
        {
            Log("Unity : init with version " + Application.unityVersion);
            Debug.Log("Unity : init with version " + Application.unityVersion);

            // Will verify all the id and signatures against example ones.

            CBSettings.getIOSAppId();

            CBSettings.getIOSAppSecret();

            CBSettings.getAndroidAppId();

            CBSettings.getAndroidAppSecret();

            CBSettings.getAmazonAppId();

            CBSettings.getAmazonAppSecret();
        }
コード例 #20
0
 // Token: 0x060000F2 RID: 242 RVA: 0x00005EBB File Offset: 0x000042BB
 public static Chartboost CreateWithAppId(string appId, string appSignature)
 {
     CBSettings.setAppId(appId, appSignature);
     return(Chartboost.Create());
 }
コード例 #21
0
		public override void OnInspectorGUI() {
			instance = (CBSettings)target;

			SetupUI();
		}
コード例 #22
0
        public override void OnInspectorGUI()
        {
            instance = (CBSettings)target;

            SetupUI();
        }
コード例 #23
0
        private void SetupUI()
        {
            EditorGUILayout.HelpBox("Add the Chartboost App Id and App Secret associated with this game", MessageType.None);

            // iOS
            EditorGUILayout.BeginHorizontal();
            EditorGUILayout.LabelField(iOSLabel);
            EditorGUILayout.EndHorizontal();

            EditorGUILayout.BeginHorizontal();
            EditorGUILayout.LabelField(iOSAppIdLabel);
            EditorGUILayout.LabelField(iOSAppSecretLabel);
            EditorGUILayout.EndHorizontal();

            EditorGUILayout.BeginHorizontal();
            instance.SetIOSAppId(EditorGUILayout.TextField(instance.iOSAppId));
            instance.SetIOSAppSecret(EditorGUILayout.TextField(instance.iOSAppSecret));
            EditorGUILayout.EndHorizontal();
            EditorGUILayout.Space();
            EditorGUILayout.Space();

            // Android
            EditorGUILayout.BeginHorizontal();
            EditorGUILayout.LabelField(androidLabel);
            EditorGUILayout.EndHorizontal();

            EditorGUILayout.BeginHorizontal();
            EditorGUILayout.LabelField(androidAppIdLabel);
            EditorGUILayout.LabelField(androidAppSecretLabel);
            EditorGUILayout.EndHorizontal();

            EditorGUILayout.BeginHorizontal();
            instance.SetAndroidAppId(EditorGUILayout.TextField(instance.androidAppId));
            instance.SetAndroidAppSecret(EditorGUILayout.TextField(instance.androidAppSecret));
            EditorGUILayout.EndHorizontal();
            EditorGUILayout.Space();
            EditorGUILayout.Space();

            // Amazon
            EditorGUILayout.BeginHorizontal();
            EditorGUILayout.LabelField(amazonLabel);
            EditorGUILayout.EndHorizontal();

            EditorGUILayout.BeginHorizontal();
            EditorGUILayout.LabelField(amazonAppIdLabel);
            EditorGUILayout.LabelField(amazonAppSecretLabel);
            EditorGUILayout.EndHorizontal();

            EditorGUILayout.BeginHorizontal();
            instance.SetAmazonAppId(EditorGUILayout.TextField(instance.amazonAppId));
            instance.SetAmazonAppSecret(EditorGUILayout.TextField(instance.amazonAppSecret));
            EditorGUILayout.EndHorizontal();
            EditorGUILayout.Space();
            EditorGUILayout.Space();

            // Android Selector
            EditorGUILayout.BeginHorizontal();
            EditorGUILayout.LabelField(selectorLabel);
            EditorGUILayout.EndHorizontal();

            EditorGUILayout.BeginHorizontal();
            instance.SetAndroidPlatformIndex(EditorGUILayout.Popup("Android Platform", instance.SelectedAndroidPlatformIndex, instance.AndroidPlatformLabels));
            EditorGUILayout.EndHorizontal();
            EditorGUILayout.Space();
            EditorGUILayout.Space();

            // Loggin toggle.
            EditorGUILayout.BeginHorizontal();
            EditorGUILayout.LabelField(enableLoggingLabel);
            EditorGUILayout.EndHorizontal();

            EditorGUILayout.BeginHorizontal();
            CBSettings.enableLogging(EditorGUILayout.Toggle(enableLoggingToggle, instance.isLoggingEnabled));
            EditorGUILayout.EndHorizontal();
            EditorGUILayout.Space();
            EditorGUILayout.Space();

            EditorGUILayout.BeginHorizontal();
            if (GUILayout.Button("Setup Android SDK"))
            {
                DoSetup();
            }
            EditorGUILayout.EndHorizontal();
        }
コード例 #24
0
 // Token: 0x0600008F RID: 143 RVA: 0x00004EAB File Offset: 0x000032AB
 public static void enableLogging(bool enabled)
 {
     CBSettings.Instance.isLoggingEnabled = enabled;
     CBSettings.DirtyEditor();
 }