예제 #1
0
 //----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 //                                                                                                                        HandleClickButton()
 //----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 void HandleClickButton()
 {
     if (Input.GetMouseButtonUp(0))
     {
         if (_back_button.HitTestPoint(Input.mouseX, Input.mouseY))
         {
             GoBackToVictoryMenu();
         }
     }
 }
예제 #2
0
        //----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
        //                                                                                                                        HandleClickButton()
        //----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
        void HandleClickButton()
        {
            if (Input.GetMouseButtonUp(0))
            {
                if (_restart_button.HitTestPoint(Input.mouseX, Input.mouseY))
                {
                    RestartLevel();
                    Globals.aIsPressed = false;
                    Globals.dIsPressed = false;
                }

                if (_main_menu_button.HitTestPoint(Input.mouseX, Input.mouseY))
                {
                    GoBackToStartMenu();
                    Globals.aIsPressed = false;
                    Globals.dIsPressed = false;
                }
            }
        }