refact by claude
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
ci/woodpecker/pr/woodpecker Pipeline was successful
ci/woodpecker/pull_request_closed/woodpecker Pipeline was successful

This commit is contained in:
Zsolt Tasnadi
2026-02-23 10:22:41 +01:00
parent 272a54ea87
commit 7deeffa8d6
20 changed files with 85 additions and 77 deletions

View File

@@ -5,12 +5,12 @@ function MinigameRhythmWindow.init(params)
end
--- Starts the rhythm minigame.
-- @param return_window number The window ID to return to after the minigame.
-- @param return_window string The window ID to return to after the minigame.
-- @param[opt] params table Optional parameters for minigame configuration.
function MinigameRhythmWindow.start(return_window, params)
MinigameRhythmWindow.init(params)
Context.minigame_rhythm.return_window = return_window or "game"
Context.current_window = "minigame_rhythm"
Window.set_current("minigame_rhythm")
end
--- Updates rhythm minigame logic.
@@ -48,7 +48,7 @@ function MinigameRhythmWindow.update()
if mg.score >= mg.max_score then
Meter.on_minigame_complete()
Meter.show()
Context.current_window = mg.return_window
Window.set_current(mg.return_window)
return
end
if mg.button_pressed_timer > 0 then