feat: added minigames (button_mash, rhythm, ddr), correction in makefiles readline, placed games in init.context
Some checks failed
ci/woodpecker/push/woodpecker Pipeline failed
ci/woodpecker/pr/woodpecker Pipeline was successful

This commit is contained in:
Zoltan Timar
2026-02-12 16:31:03 +01:00
parent 3dc28849c4
commit c9db82cce7
14 changed files with 857 additions and 18 deletions

View File

@@ -24,6 +24,18 @@ local STATE_HANDLERS = {
ConfigurationWindow.update()
ConfigurationWindow.draw()
end,
[WINDOW_MINIGAME_BUTTON_MASH] = function()
MinigameButtonMashWindow.update()
MinigameButtonMashWindow.draw()
end,
[WINDOW_MINIGAME_RHYTHM] = function()
MinigameRhythmWindow.update()
MinigameRhythmWindow.draw()
end,
[WINDOW_MINIGAME_DDR] = function()
MinigameDDRWindow.update()
MinigameDDRWindow.draw()
end,
}
local initialized_game = false

View File

@@ -5,4 +5,11 @@ function Print.text(text, x, y, color, fixed, scale)
scale = scale or 1
print(text, x + 1, y + 1, shadow_color, fixed, scale)
print(text, x, y, color, fixed, scale)
end
function Print.text_center(text, x, y, color, fixed, scale)
scale = scale or 1
local text_width = print(text, 0, -6, 0, fixed, scale)
local centered_x = x - (text_width / 2)
Print.text(text, centered_x, y, color, fixed, scale)
end