private void handleGameMode() { if (currentGM is GameModeSurvival) { GameModeSurvival survivalMode = (GameModeSurvival)currentGM; survivalMode.HandleEnemyDeath(this); } }
private void Start() { boxComp = GetComponent <BoxCollider2D>(); gameMode = FindObjectOfType <GameModeSurvival>(); }