public override void Die() { //Debug.Log(ScoreManager.score); base.Die(); BossBehaviour bb = gameObject.GetComponent <BossBehaviour>(); if (bb) { GameManager.instance.UpdateScore(BossPointValue); bb.Die(); } else { GameManager.instance.UpdateScore(EnemyPointValue); SpawnDieFX(); // if (DieFX) { Instantiate(DieFX, this.transform.position, Quaternion.identity); } Destroy(this.gameObject); } GameManager.EnemiesKilled++; }