forked from jaildesigner-jailgames/jaildoctors_dilemma
Cambio de color en el texto del marcador
This commit is contained in:
@@ -104,7 +104,7 @@ void ScoreBoard::render()
|
||||
// Muestra si suena la música
|
||||
if (board->music)
|
||||
{
|
||||
const color_t c = stringToColor("bright_blue");
|
||||
const color_t c = board->color;
|
||||
SDL_Rect clip = {0, 8, 8, 8};
|
||||
itemTexture->setColor(c.r, c.g, c.b);
|
||||
itemTexture->render(renderer, 20 * BLOCK, line2, &clip);
|
||||
@@ -113,14 +113,14 @@ void ScoreBoard::render()
|
||||
// Escribe los textos
|
||||
const std::string timeTxt = std::to_string((clock.minutes % 60) / 10) + std::to_string(clock.minutes % 10) + clock.separator + std::to_string((clock.seconds % 60) / 10) + std::to_string(clock.seconds % 10);
|
||||
const std::string itemsTxt = std::to_string(board->items / 100) + std::to_string((board->items % 100) / 10) + std::to_string(board->items % 10);
|
||||
this->text->writeColored(BLOCK, line1, "Items collected ", stringToColor("yellow"));
|
||||
this->text->writeColored(17 * BLOCK, line1, itemsTxt, stringToColor("bright_blue"));
|
||||
this->text->writeColored(20 * BLOCK, line1, " Time ", stringToColor("yellow"));
|
||||
this->text->writeColored(26 * BLOCK, line1, timeTxt, stringToColor("bright_blue"));
|
||||
this->text->writeColored(BLOCK, line1, "Items collected ", board->color);
|
||||
this->text->writeColored(17 * BLOCK, line1, itemsTxt, stringToColor("white"));
|
||||
this->text->writeColored(20 * BLOCK, line1, " Time ", board->color);
|
||||
this->text->writeColored(26 * BLOCK, line1, timeTxt, stringToColor("white"));
|
||||
|
||||
const std::string roomsTxt = std::to_string(board->rooms / 100) + std::to_string((board->rooms % 100) / 10) + std::to_string(board->rooms % 10);
|
||||
this->text->writeColored(22 * BLOCK, line2, "Rooms", stringToColor("yellow"));
|
||||
this->text->writeColored(28 * BLOCK, line2, roomsTxt, stringToColor("bright_blue"));
|
||||
this->text->writeColored(22 * BLOCK, line2, "Rooms", stringToColor("white"));
|
||||
this->text->writeColored(28 * BLOCK, line2, roomsTxt, stringToColor("white"));
|
||||
}
|
||||
|
||||
// Actualiza las variables del objeto
|
||||
|
||||
Reference in New Issue
Block a user