forked from jaildesigner-jailgames/jaildoctors_dilemma
Transició a surface: barallantme amb tots els Color que hi ha pel codi
This commit is contained in:
@@ -43,7 +43,7 @@ Title::Title()
|
||||
createCheevosTexture();
|
||||
|
||||
// Cambia el color del borde
|
||||
Screen::get()->setBorderColor(stringToColor(options.video.palette, "black"));
|
||||
Screen::get()->setBorderColor(stringToColor("black"));
|
||||
|
||||
// Rellena la textura de fondo con todos los gráficos
|
||||
fillSurface();
|
||||
@@ -177,7 +177,7 @@ void Title::renderMarquee()
|
||||
{
|
||||
if (l.enabled)
|
||||
{
|
||||
TEXT->writeColored(l.x, 184, l.letter, stringToColor(options.video.palette, "white"));
|
||||
TEXT->writeColored(l.x, 184, l.letter, stringToColor("white"));
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -322,7 +322,7 @@ void Title::fillSurface()
|
||||
|
||||
// Escribe el texto en la textura
|
||||
auto text = Resource::get()->getText("smb2");
|
||||
const Color COLOR = stringToColor(options.video.palette, "green");
|
||||
const Uint8 COLOR = stringToColor("green");
|
||||
const int TEXT_SIZE = text->getCharacterSize();
|
||||
text->writeDX(TEXT_CENTER | TEXT_COLOR, PLAY_AREA_CENTER_X, 11 * TEXT_SIZE, "1.PLAY", 1, COLOR);
|
||||
text->writeDX(TEXT_CENTER | TEXT_COLOR, PLAY_AREA_CENTER_X, 13 * TEXT_SIZE, "2.ACHIEVEMENTS", 1, COLOR);
|
||||
@@ -351,7 +351,7 @@ void Title::createCheevosTexture()
|
||||
Screen::get()->setRenderSurfaceData(cheevos_surface_);
|
||||
|
||||
// Rellena la textura con color sólido
|
||||
const Color CHEEVOS_BG_COLOR = stringToColor(options.video.palette, "black");
|
||||
const Uint8 CHEEVOS_BG_COLOR = stringToColor("black");
|
||||
SDL_SetRenderDrawColor(Screen::get()->getRenderer(), CHEEVOS_BG_COLOR.r, CHEEVOS_BG_COLOR.g, CHEEVOS_BG_COLOR.b, 0xFF);
|
||||
SDL_RenderClear(Screen::get()->getRenderer());
|
||||
|
||||
@@ -361,9 +361,9 @@ void Title::createCheevosTexture()
|
||||
int pos = 2;
|
||||
TEXT->writeDX(TEXT_CENTER | TEXT_COLOR, cheevos_surface_->getWidth() / 2, pos, CHEEVOS_LIST_CAPTION, 1, stringToColor(options.video.palette, "bright_green"));
|
||||
pos += TEXT->getCharacterSize();
|
||||
const Color CHEEVO_LOCKED_COLOR = stringToColor(options.video.palette, "white");
|
||||
const Color CHEEVO_UNLOCKED_COLOR = stringToColor(options.video.palette, "bright_green");
|
||||
Color cheevoColor;
|
||||
const Uint8 CHEEVO_LOCKED_COLOR = stringToColor("white");
|
||||
const Uint8 CHEEVO_UNLOCKED_COLOR = stringToColor("bright_green");
|
||||
Uint8 cheevoColor;
|
||||
SDL_SetRenderDrawColor(Screen::get()->getRenderer(), CHEEVO_LOCKED_COLOR.r, CHEEVO_LOCKED_COLOR.g, CHEEVO_LOCKED_COLOR.b, 0xFF);
|
||||
constexpr int LINE_X1 = (CHEEVOS_TEXTURE_WIDTH / 7) * 3;
|
||||
constexpr int LINE_X2 = LINE_X1 + ((CHEEVOS_TEXTURE_WIDTH / 7) * 1);
|
||||
|
||||
Reference in New Issue
Block a user