Пример #1
0
 public void Retry()
 {
     Time.timeScale     = 1;
     my_UIM.ActualScore = 0;
     my_UIM.score.text  = "" + 0;
     my_UIM.time        = my_UIM.startTime;
     my_UIM.t           = my_UIM.time * 60;
     Pause_Buttons.SetActive(false);
     End_Buttons.SetActive(false);
     Timer.SetActive(true);
     Pause_Icon.SetActive(true);
     Shoot_Button.SetActive(true);
     my_UIM.score.color              = Color.black;;
     my_UIM.score.fontSize           = 95;
     my_UIM.scoreOutline.effectColor = Color.white;
     for (int i = 0; i < BD_Cibles.Length; i++)
     {
         BD_Cibles[i].SetActive(false);
     }
     for (int i = 0; i < Angry_Cibles.Length; i++)
     {
         Debug.Log("angry_returns");
         Angry_Cibles[i].SetActive(false);
     }
 }
Пример #2
0
 public void Resume()
 {
     is_Paused      = false;
     Time.timeScale = 1;
     Pause_Buttons.SetActive(false);
     Shoot_Button.SetActive(true);
 }
Пример #3
0
 public void PauseGame()
 {
     is_Paused      = true;
     Time.timeScale = 0;
     Pause_Buttons.SetActive(true);
     Shoot_Button.SetActive(false);
 }
Пример #4
0
 public void Timeout()
 {
     my_SM.TimeOut_Sarbacane();
     Time.timeScale = 0;
     TimerText.text = "0:0";
     Endgame_Button.SetActive(true);
     Timer_Button.SetActive(false);
     Pause_Button.SetActive(false);
     t = 0;
     Shoot_Button.SetActive(false);
 }
Пример #5
0
    private void Update()
    {
        if (Static_Vars_1.mobile_ui)
        {
            joystick     = FindObjectOfType <Joystick>();
            shoot_button = FindObjectOfType <Shoot_Button>();

            if (joystick.Vertical > 0.1f)
            {
                Time.timeScale = 1f;
                Dialogue_Box_1.SetActive(false);
            }
        }

        if (Input.GetKeyDown(KeyCode.UpArrow) || Input.GetKeyDown(KeyCode.DownArrow) || Input.GetKeyDown(KeyCode.LeftArrow) || Input.GetKeyDown(KeyCode.RightArrow))
        {
            Time.timeScale = 1f;             //start game play
            Dialogue_Box_1.SetActive(false); //unshow dialogue box
        }
    }
Пример #6
0
 private void Start()
 {
     joystick     = FindObjectOfType <Joystick>();
     shoot_Button = FindObjectOfType <Shoot_Button>();
     jump_Button  = FindObjectOfType <Jump_Button>();
 }