diff --git a/assets/sounds/Hit18.wav b/assets/sounds/Hit18.wav new file mode 100644 index 0000000..19aacbd Binary files /dev/null and b/assets/sounds/Hit18.wav differ diff --git a/src/samples/ghhb_game.h b/src/samples/ghhb_game.h index efb7519..34e6069 100644 --- a/src/samples/ghhb_game.h +++ b/src/samples/ghhb_game.h @@ -363,6 +363,7 @@ public: Sound note_sounds[MAX_INSTRUMENT_TYPES][MIDI_LANE_COUNT] = {{0}}; bool note_sounds_loaded[MAX_INSTRUMENT_TYPES][MIDI_LANE_COUNT] = {{false}}; std::deque note_sounds_playing[LANE_COUNT][MAX_INSTRUMENT_TYPES]; + Sound oof = {0}; static constexpr float PRESS_FLASH_DURATION = 0.12f; float press_flash_timer[LANE_COUNT] = {0}; float hit_flash_timer[LANE_COUNT] = {0}; @@ -425,6 +426,7 @@ public: StopMusicStream(music); UnloadMusicStream(music); } + UnloadSound(oof); for (int slot = 0; slot < MAX_INSTRUMENT_TYPES; slot++) { for (int lane = 0; lane < MIDI_LANE_COUNT; lane++) @@ -446,6 +448,7 @@ public: auto font_manager = game->get_manager(); font = font_manager->get_font("Roboto"); update_layout(); + oof = LoadSound("assets/sounds/Hit18.wav"); for (int slot = 0; slot < MAX_INSTRUMENT_TYPES; slot++) { for (int lane = 0; lane < MIDI_LANE_COUNT; lane++) @@ -759,6 +762,7 @@ public: TraceLog(LOG_WARNING, "COMBO RESET -> 0 (missed note: lane %d, inst %d)", n->lane, n->instrument_slot); combo = 0; + PlaySound(oof); } }