added the new banks in

removed unneeded bank
added new audio
This commit is contained in:
Glence 2022-11-25 22:32:41 +08:00
parent 6694ce2e17
commit fb512e7fc5
7 changed files with 5 additions and 12 deletions

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -59,6 +59,7 @@ public class Breakable : Script
} }
isBreak = false; isBreak = false;
Audio.PlaySFXOnce2D("event:/Props/impact_break");
Owner.SetActive(false); Owner.SetActive(false);
} }
} }

View File

@ -76,33 +76,25 @@ public class GameManager : Script
if(timeText) if(timeText)
timeText.GetComponent<TextRenderable>().Text = $"Time Left: {timer.ToString("0.00")}"; timeText.GetComponent<TextRenderable>().Text = $"Time Left: {timer.ToString("0.00")}";
if (timer > 0 && totalItemCount <= 0) if ((timer > 0 && totalItemCount <= 0) || Input.GetKeyDown(Input.KeyCode.F1))
{ {
currGameState = GameState.WIN; currGameState = GameState.WIN;
Audio.StopAllSounds(); Audio.StopAllSounds();
SceneManager.ChangeScene(winScene); SceneManager.ChangeScene(winScene);
Audio.PlaySFXOnce2D("event:/Music/stingers/game_win");
} }
else if(timer < 0) else if(timer < 0 || Input.GetKeyDown(Input.KeyCode.F2))
{ {
currGameState = GameState.LOSE; currGameState = GameState.LOSE;
Audio.StopAllSounds(); Audio.StopAllSounds();
SceneManager.ChangeScene(loseScene); SceneManager.ChangeScene(loseScene);
Audio.PlaySFXOnce2D("event:/Music/stingers/game_lose");
} }
} }
} }
private void Cheats() private void Cheats()
{ {
if (Input.GetKeyDown(Input.KeyCode.F1))
{
Audio.StopAllSounds();
SceneManager.ChangeScene(loseScene);
}
if (Input.GetKeyDown(Input.KeyCode.F2))
{
Audio.StopAllSounds();
SceneManager.ChangeScene(winScene);
}
if (Input.GetKeyDown(Input.KeyCode.Escape)) if (Input.GetKeyDown(Input.KeyCode.Escape))
{ {
Audio.StopAllSounds(); Audio.StopAllSounds();