diff options
Diffstat (limited to 'src/main/ScoreController.java')
-rw-r--r-- | src/main/ScoreController.java | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/main/ScoreController.java b/src/main/ScoreController.java index 52907ad..d2606a4 100644 --- a/src/main/ScoreController.java +++ b/src/main/ScoreController.java @@ -2,6 +2,7 @@ package main; import javafx.beans.property.SimpleStringProperty; import javafx.beans.property.StringProperty; +import sound.ShortAudioPlayer; public class ScoreController{ @@ -11,6 +12,8 @@ public class ScoreController{ public StringProperty scoreProperty = new SimpleStringProperty("0"); public StringProperty comboProperty = new SimpleStringProperty("0"); + sound.ShortAudioPlayer fx = new ShortAudioPlayer(); + /** * Called when the user performs a perfect hit */ @@ -37,6 +40,7 @@ public class ScoreController{ * Called when the user misses a note */ public void miss() { + fx.play("src/assets/Miss.wav"); combo = 0; comboMultiplier = 1; scoreProperty.setValue(score+""); @@ -48,6 +52,7 @@ public class ScoreController{ * Increments the combo by one */ private void combo() { + fx.play("src/assets/Hitsound.wav"); combo++; if (combo == 2) { |