Esempio n. 1
0
        private void OnWizardCreate()
        {
            NCMBSettingsExtended ncmbSettingsEx = FindObjectOfType <NCMBSettingsExtended>();

            if (ncmbSettingsEx == null)
            {
                GameObject ncmbSettingObject = new GameObject("NCMBSettingsExtended");
                ncmbSettingsEx = ncmbSettingObject.AddComponent <NCMBSettingsExtended>();
            }

            ncmbSettingsEx.Initialize(applicationKey, clientKey, usePush, useAnalytics, androidSenderId, responseValidation);

            if (useAPIKeyFile)
            {
                if (string.IsNullOrEmpty(apiKeyFilePath))
                {
                    Debug.Log("ファイルパスが空です");
                    return;
                }

                NCMBGenerateAPIKeyFile.GenerateAPIKeyFile(applicationKey, clientKey, apiKeyFilePath);
                ncmbSettingsEx.EnableToUseAPIKeyFile(apiKeyFilePath);
            }
            else
            {
                ncmbSettingsEx.DisableToUseAPIKeyFile();
            }

            //NCMB Managerもなかったら作る//
            if (FindObjectOfType <NCMBManager>() == null)
            {
                new GameObject("NCMBManager").AddComponent <NCMBManager>();
            }
        }
Esempio n. 2
0
        private static void Open()
        {
            if (Instance == null)
            {
                Instance = DisplayWizard <NCMBGenerateAPIKeyFile>("NCMB APIキーファイル再作成", "APIキーファイルを生成", "シーン内のNCMBSettingsExtentedからキーを読み込む");

                Instance.titleContent.image = AssetDatabase.LoadAssetAtPath <Texture>("Assets/Editor/NCMBExtensionPack/Textures/icon.png");
            }
        }