diff --git a/src/samples/ghhb_game.h b/src/samples/ghhb_game.h index 517246b..699d7f0 100644 --- a/src/samples/ghhb_game.h +++ b/src/samples/ghhb_game.h @@ -16,6 +16,7 @@ namespace { constexpr int LANE_COUNT = 12; constexpr int OCTAVE_COUNT = 3; +constexpr int OCTAVE_OFFSET = 48; constexpr int MAX_GAMEPADS = 4; constexpr int MAX_INSTRUMENT_TYPES = MAX_GAMEPADS; constexpr float RECEPTOR_HEIGHT = 150.0f; @@ -258,7 +259,10 @@ std::vector chart_from_song(const Song& song, int track_override) float time_sec = note.ticks / ticks_per_sec; // This is now the BOTTOM time float duration_sec = note.duration_ticks / ticks_per_sec; int lane = note.midi % LANE_COUNT; - int octave = note.midi % (LANE_COUNT * OCTAVE_COUNT); + int offset = 0; + if (note.midi >= OCTAVE_OFFSET) + offset = OCTAVE_OFFSET; + int octave = (note.midi - offset) % (LANE_COUNT * OCTAVE_COUNT); int instrument_slot = note_index % MAX_INSTRUMENT_TYPES; // Log original glyph timing (time is bottom, time + duration is top)