示例#1
0
 void Start()
 {
     gameWon           = false;
     gameOver          = false;
     restart           = false;
     gameOverText.text = "";
     restartText.text  = "";
     score             = 0;
     UpdateScore();
     StartCoroutine(SpawnWaves());
     particles            = GameObject.FindObjectOfType <Particles>();
     particles2           = GameObject.FindObjectOfType <Particles2>();
     bG_Scroller          = GameObject.FindObjectOfType <BG_Scroller>();
     lighting             = GameObject.FindObjectOfType <Lighting>();
     mainMusicSource.clip = mainAudio;
     mainMusicSource.Play();
     mainMusicSource.loop = true;
 }
示例#2
0
 public void Update(GameTime gameTime)
 {
     DigitUpdate(gameTime);
     Particles1.Update(gameTime);
     Particles2.Update(gameTime);
 }
示例#3
0
 public void Draw(SpriteBatch spriteBatch, Texture2D texture)
 {
     Particles1.Draw(spriteBatch, texture);
     Particles2.Draw(spriteBatch, texture);
 }