tweak(playfield): rejilla violeta synthwave + brillos +5%; starfield unificat al color del títol
This commit is contained in:
@@ -290,7 +290,9 @@ namespace Graphics {
|
||||
static_cast<int>(START_Y),
|
||||
static_cast<int>(END_X),
|
||||
static_cast<int>(END_Y),
|
||||
line.brightness);
|
||||
line.brightness,
|
||||
0.0F,
|
||||
Defaults::Playfield::GRID_COLOR);
|
||||
// Cap brillant mentre creix.
|
||||
if (P < 1.0F) {
|
||||
const float LENGTH = std::sqrt((DX * DX) + (DY * DY));
|
||||
@@ -302,7 +304,9 @@ namespace Graphics {
|
||||
static_cast<int>(START_Y + (DY * HEAD_T)),
|
||||
static_cast<int>(END_X),
|
||||
static_cast<int>(END_Y),
|
||||
Defaults::Playfield::HEAD_BRIGHTNESS);
|
||||
Defaults::Playfield::HEAD_BRIGHTNESS,
|
||||
0.0F,
|
||||
Defaults::Playfield::GRID_COLOR);
|
||||
}
|
||||
}
|
||||
return;
|
||||
@@ -329,7 +333,9 @@ namespace Graphics {
|
||||
static_cast<int>(prev_y),
|
||||
static_cast<int>(NX),
|
||||
static_cast<int>(NY),
|
||||
line.brightness);
|
||||
line.brightness,
|
||||
0.0F,
|
||||
Defaults::Playfield::GRID_COLOR);
|
||||
prev_x = NX;
|
||||
prev_y = NY;
|
||||
}
|
||||
|
||||
@@ -31,20 +31,15 @@ namespace Graphics {
|
||||
const float MIN_Y = zona.y;
|
||||
const float MAX_Y = zona.y + zona.h;
|
||||
|
||||
// Tint aleatori entre blanc (255,255,255) i cyan (0,255,255) per estrella.
|
||||
// T ∈ [0,1]: 0 → blanc; 1 → cyan. R = 255·(1-T), G=B=255.
|
||||
// Color únic per a totes les estrelles: el mateix blanc-blau gel
|
||||
// del starfield del títol (Defaults::Title::Colors::STARFIELD).
|
||||
const auto FILL_LAYER = [&](int layer, int count, int& idx) {
|
||||
for (int i = 0; i < count; i++) {
|
||||
const float T = randUniform(0.0F, 1.0F);
|
||||
stars_[idx++] = Star{
|
||||
.x = randUniform(MIN_X, MAX_X),
|
||||
.y = randUniform(MIN_Y, MAX_Y),
|
||||
.layer = layer,
|
||||
.color = SDL_Color{
|
||||
.r = static_cast<Uint8>(255.0F * (1.0F - T)),
|
||||
.g = 255,
|
||||
.b = 255,
|
||||
.a = 255}};
|
||||
.color = Defaults::Title::Colors::STARFIELD};
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user