Exemplo n.º 1
0
    private void OnParticleCollision(GameObject collision)
    {
        print(collision.gameObject.tag);
        switch (collision.gameObject.tag)
        {
        case "Friendly Laser":
            if (alive)
            {
                scoreTracker.AddEnemyDestroyedScore();
                stunEffect.Play();
                laser.Stop();
                disabledSound.Play();
            }
            alive = false;
            break;

        default:
            break;
        }
    }