コード例 #1
0
    void IncreaseProgress()
    {
        if (isActive && hasVirus == false)
        {
            progress++;
        }

        if (progress > 5 && hasVirus == false)
        {
            hasVirus      = true;
            virusParticle = Instantiate(virusParticlePrefab);
            gameplayController.AddScore();
        }
    }
コード例 #2
0
 protected virtual void Die()
 {
     audioController.EnemyDestroyedSound();
     gameController.AddScore(score);
     Destroy(this.gameObject);
 }