Exemplo n.º 1
0
    private void OnTriggerEnter2D(Collider2D collision)
    {
        int count = 0;

        if (collision.gameObject.CompareTag("PlayerBullet"))
        {
            GameObject particle = Instantiate(particleSystem, collision.gameObject.transform.position, Quaternion.identity);
            Destroy(particle, 3f);
            count++;
            collision.gameObject.SetActive(false);
            if (count == 1)
            {
                LevelbarUpdate();
                ScoreControl.updateScoreui();
            }
            damageHealth();
        }
    }
Exemplo n.º 2
0
 private void levelpanelControl()                                           //for changing  the level bar and score controll
 {
     leveLCompletion.UpdateLevelbarBigEnemy(damageamount.getHelthdamage()); //calling another method when bigenemi is called
     ScoreControl.updateScoreui();
 }