private void Update() { if (Input.GetKeyDown(KeyCode.Q)) { gameManagerMaster.CallGameOverEvent(); } }
void DeductHealth(int healthChange) { if (gameManagerMaster.isGameOver) { return; } playerHealth -= healthChange; if (playerHealth <= 0) { playerHealth = 0; gameManagerMaster.CallGameOverEvent(); } SetUI(); }