public override void OnUGUIInit()
        {
            Debug.Log("GameScene.OnUGUIInit()");

            base.OnUGUIInit();

            _btnMainMenuScene = MyUtilities.FindObject(GameObject, "Buttons/ButtonMainMenuScene").GetComponent <MyUGUIButton>();
        }
        public static void CreateMyUGUIButtonColorTint()
        {
            GameObject go = MyUGUIButton.CreateTextTemplate();

            MyUGUIButton button = go.GetComponent <MyUGUIButton>();

            button.Button.transition = Selectable.Transition.ColorTint;

            Debug.Log("[MyClasses] Text Button (Color Tint) was created.");
        }
        public static void CreateMyUGUITextMeshProButtonScaleAnimation()
        {
            GameObject go = MyUGUIButton.CreateTextMeshProTemplate();

            MyUGUIButton button = go.GetComponent <MyUGUIButton>();

            button.Button.transition = Selectable.Transition.ColorTint;

            Debug.Log("[MyClasses] TextMeshPro Button (Scale Animation) was created.");
        }
Beispiel #4
0
        public override void OnUGUIInit()
        {
            Debug.Log("LocalizationPopup.OnUGUIInit()");

            base.OnUGUIInit();

            _btnClose      = MyUtilities.FindObject(GameObject, "Container/ButtonClose").GetComponent <MyUGUIButton>();
            _btnEnglish    = MyUtilities.FindObject(GameObject, "Container/ButtonEnglish").GetComponent <MyUGUIButton>();
            _btnVietnamese = MyUtilities.FindObject(GameObject, "Container/ButtonVietnamese").GetComponent <MyUGUIButton>();
        }
        public override void OnUGUIInit()
        {
            Debug.Log("PoolPopup.OnUGUIInit()");

            base.OnUGUIInit();

            _btnClose      = MyUtilities.FindObject(GameObject, "Container/ButtonClose").GetComponent <MyUGUIButton>();
            _btnUse        = MyUtilities.FindObject(GameObject, "Container/ButtonUse").GetComponent <MyUGUIButton>();
            _btnReturn     = MyUtilities.FindObject(GameObject, "Container/ButtonReturn").GetComponent <MyUGUIButton>();
            _trfItemParent = MyUtilities.FindObject(GameObject, "Container/Items").transform;
        }
        public override void OnUGUIInit()
        {
            Debug.Log("AdMobPopup.OnUGUIInit()");

            base.OnUGUIInit();

            _btnClose             = MyUtilities.FindObject(GameObject, "Container/ButtonClose").GetComponent <MyUGUIButton>();
            _btnShowBanner        = MyUtilities.FindObject(GameObject, "Container/Buttons/ButtonShowBanner").GetComponent <MyUGUIButton>();
            _btnLoadInterstitial  = MyUtilities.FindObject(GameObject, "Container/Buttons/ButtonLoadInterstitial").GetComponent <MyUGUIButton>();
            _btnShowInterstitial  = MyUtilities.FindObject(GameObject, "Container/Buttons/ButtonShowInterstitial").GetComponent <MyUGUIButton>();
            _btnLoadRewardedVideo = MyUtilities.FindObject(GameObject, "Container/Buttons/ButtonLoadRewardedVideo").GetComponent <MyUGUIButton>();
            _btnShowRewardedVideo = MyUtilities.FindObject(GameObject, "Container/Buttons/ButtonShowRewardedVideo").GetComponent <MyUGUIButton>();
        }
Beispiel #7
0
        public override void OnUGUIInit()
        {
            base.OnUGUIInit();

            _btnRunningMessage   = MyUtilities.FindObject(GameObject, "Buttons/ButtonRunningMessage").GetComponent <MyUGUIButton>();
            _btnFlyingMessage    = MyUtilities.FindObject(GameObject, "Buttons/ButtonFlyingMessage").GetComponent <MyUGUIButton>();
            _btnToastMessage     = MyUtilities.FindObject(GameObject, "Buttons/ButtonToastMessage").GetComponent <MyUGUIButton>();
            _btnLoadingIndicator = MyUtilities.FindObject(GameObject, "Buttons/ButtonLoadingIndicator").GetComponent <MyUGUIButton>();
            _btnDialog2Buttons   = MyUtilities.FindObject(GameObject, "Buttons/ButtonDialog2Buttons").GetComponent <MyUGUIButton>();
            _btnGameScene        = MyUtilities.FindObject(GameObject, "Buttons/ButtonGameScene").GetComponent <MyUGUIButton>();
            _btnPool             = MyUtilities.FindObject(GameObject, "Buttons/ButtonPool").GetComponent <MyUGUIButton>();
            _btnLocalization     = MyUtilities.FindObject(GameObject, "Buttons/ButtonLocalization").GetComponent <MyUGUIButton>();
            _btnAdMob            = MyUtilities.FindObject(GameObject, "Buttons/ButtonAdMob").GetComponent <MyUGUIButton>();
        }
        public static void CreateMyUGUIButtonScaleAnimation()
        {
            GameObject go = MyUGUIButton.CreateTextTemplate();

            MyUGUIButton button = go.GetComponent <MyUGUIButton>();

            button.Button.transition = Selectable.Transition.Animation;

            Animator animator = go.AddComponent <Animator>();

            string[] paths = new string[] { "Assets/MyClasses", "Assets/Core/MyClasses", "Assets/Plugin/MyClasses", "Assets/Plugins/MyClasses", "Assets/Framework/MyClasses", "Assets/Frameworks/MyClasses" };
            for (int i = 0; i < paths.Length; i++)
            {
                if (System.IO.File.Exists(paths[i] + "/Sources/Animations/my_animator_button_click_scale.controller"))
                {
                    animator.runtimeAnimatorController = (RuntimeAnimatorController)UnityEditor.AssetDatabase.LoadAssetAtPath(paths[i] + "/Sources/Animations/my_animator_button_click_scale.controller", typeof(RuntimeAnimatorController));
                    break;
                }
            }

            Debug.Log("[MyClasses] Text Button (Scale Animation) was created.");
        }
        public override void OnUGUIInit()
        {
            base.OnUGUIInit();

            _btnBack = MyUtilities.FindObject(GameObject, "Something/ButtonBack").GetComponent <MyUGUIButton>();
        }
        public override void OnUGUIInit()
        {
            base.OnUGUIInit();

            _btnClose = MyUtilities.FindObject(GameObject, "Container/ButtonClose").GetComponent <MyUGUIButton>();
        }