tweak(hud): NIVELL encès i el número amb els zeros de farciment atenuats com els punts
This commit is contained in:
@@ -230,8 +230,8 @@ namespace Systems::InitHud {
|
|||||||
drawSlots(renderer, shape, lives, bright, dim, x, center_y, scale, spacing);
|
drawSlots(renderer, shape, lives, bright, dim, x, center_y, scale, spacing);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Pinta el nivell centrat: etiqueta "NIVELL" en verd atenuat i el número
|
// Pinta el nivell centrat: etiqueta "NIVELL" encesa i el número com els
|
||||||
// en verd brillant.
|
// punts (zeros de farciment atenuats, dígit significatiu en endavant encès).
|
||||||
void drawLevel(const Graphics::VectorText& text,
|
void drawLevel(const Graphics::VectorText& text,
|
||||||
const std::string& label,
|
const std::string& label,
|
||||||
const std::string& value,
|
const std::string& value,
|
||||||
@@ -242,9 +242,9 @@ namespace Systems::InitHud {
|
|||||||
const float W_VALUE = Graphics::VectorText::getTextWidth(value, scale, spacing);
|
const float W_VALUE = Graphics::VectorText::getTextWidth(value, scale, spacing);
|
||||||
const float CX = Defaults::Game::WIDTH / 2.0F;
|
const float CX = Defaults::Game::WIDTH / 2.0F;
|
||||||
float x = CX - ((W_LABEL + W_VALUE) / 2.0F);
|
float x = CX - ((W_LABEL + W_VALUE) / 2.0F);
|
||||||
text.render(label, {.x = x, .y = top_y}, scale, spacing, 1.0F, Defaults::Hud::Colors::LEVEL_DIM);
|
text.render(label, {.x = x, .y = top_y}, scale, spacing, 1.0F, Defaults::Hud::Colors::LEVEL_BRIGHT);
|
||||||
x += W_LABEL;
|
x += W_LABEL;
|
||||||
text.render(value, {.x = x, .y = top_y}, scale, spacing, 1.0F, Defaults::Hud::Colors::LEVEL_BRIGHT);
|
drawScore(text, value, Defaults::Hud::Colors::LEVEL_BRIGHT, Defaults::Hud::Colors::LEVEL_DIM, true, x, top_y, scale, spacing);
|
||||||
}
|
}
|
||||||
|
|
||||||
} // namespace
|
} // namespace
|
||||||
|
|||||||
Reference in New Issue
Block a user