예제 #1
0
    public static void Game_Over()
    {
        if (score >= HighScore)
        {
            SaveManager.SetHighScore(HighScore);
            SaveManager.Save();
            GPS.ReportHighScore(score);
            //scoreReadout.GetComponent<TextMesh>().color = colors["Gold"];
        }
        //Destruction sound - Tyler
        AudioClip audiotemp = AudioManager.Destruction_Sound;

        AudioManager.Play_Audio(audiotemp);
        //Jays shit is below
        current_game_state = game_state.GameOver;
        player.GetComponent <Rigidbody2D> ().velocity = new Vector3(0f, 0f, 0f);
        line_number = 0;
        speed       = 5;
        Camera.main.GetComponent <Animator> ().Play("MainGame_Camera_ZoomOut");
        GameObject Colour_Particles = Instantiate(Resources.Load("Sprites/Ui/Particles/ColourParticles") as GameObject, new Vector3(Camera.main.transform.position.x, 4f, 11f), identity) as GameObject;
    }