refactor: JD8_* a namespace Jd8::

This commit is contained in:
2026-05-16 14:24:22 +02:00
parent 1ce0d9c56c
commit f37308a5f0
41 changed files with 394 additions and 396 deletions
+8 -8
View File
@@ -24,8 +24,8 @@ namespace scenes {
// Inicialitza la paleta mínima per a la barra. La resta de
// colors queden a negre — després cada escena del joc carregarà
// la seua pròpia paleta.
JD8_SetPaletteColor(BG_COLOR, 0, 0, 0);
JD8_SetPaletteColor(BAR_COLOR, 63, 63, 63);
Jd8::setPaletteColor(BG_COLOR, 0, 0, 0);
Jd8::setPaletteColor(BAR_COLOR, 63, 63, 63);
}
void BootLoaderScene::tick(int /*delta_ms*/) {
@@ -36,7 +36,7 @@ namespace scenes {
}
void BootLoaderScene::render() {
JD8_ClearScreen(BG_COLOR);
Jd8::clearScreen(BG_COLOR);
if (!Options::game.show_preload) {
return;
@@ -46,14 +46,14 @@ namespace scenes {
const int filled = static_cast<int>(static_cast<float>(BAR_W) * pct);
// Vora de la barra (línia 1 píxel a dalt i a baix).
JD8_FillRect(BAR_X - 1, BAR_Y - 1, BAR_W + 2, 1, BAR_COLOR);
JD8_FillRect(BAR_X - 1, BAR_Y + BAR_H, BAR_W + 2, 1, BAR_COLOR);
JD8_FillRect(BAR_X - 1, BAR_Y, 1, BAR_H, BAR_COLOR);
JD8_FillRect(BAR_X + BAR_W, BAR_Y, 1, BAR_H, BAR_COLOR);
Jd8::fillRect(BAR_X - 1, BAR_Y - 1, BAR_W + 2, 1, BAR_COLOR);
Jd8::fillRect(BAR_X - 1, BAR_Y + BAR_H, BAR_W + 2, 1, BAR_COLOR);
Jd8::fillRect(BAR_X - 1, BAR_Y, 1, BAR_H, BAR_COLOR);
Jd8::fillRect(BAR_X + BAR_W, BAR_Y, 1, BAR_H, BAR_COLOR);
// Ompliment proporcional al progrés.
if (filled > 0) {
JD8_FillRect(BAR_X, BAR_Y, filled, BAR_H, BAR_COLOR);
Jd8::fillRect(BAR_X, BAR_Y, filled, BAR_H, BAR_COLOR);
}
}