private void OnTriggerEnter(Collider other) { if (other.gameObject.layer == Globals.playerLayer) { if (type == LevelTriggerType.End) { PlayerActions.playerActions.EndLevel(); startEnemy.EnableEnemy(); } else //if(type == LevelTriggerType.Half) { endEnemy.EnableEnemy(); tank.PlayerDetected(); } } }