refactor(defaults): centralitza constants de bullet, ship, enemy, hud i notifier

This commit is contained in:
JailDesigner committed 2026-05-21 09:39:36 +02:00
1 parent 61ae211dab
commit 08100f60e8
12 files changed
+197 -150

No files matched your search

+31
View File
@@ -0,0 +1,31 @@
// notifier.hpp - Configuració del cuadre de notificacions toast (System::Notifier)
// © 2026 JailDesigner
#pragma once
#include <SDL3/SDL.h>
namespace Defaults::Notifier {
// Geometria del cuadre en coordenades lògiques (1280×720).
constexpr float CANVAS_WIDTH = 1280.0F;
constexpr float MARGIN_TOP = 40.0F;
constexpr float PADDING_H = 16.0F;
constexpr float PADDING_V = 10.0F;
constexpr float BORDER_THICKNESS = 2.0F;
constexpr float TEXT_SCALE = 0.55F;
constexpr float TEXT_SPACING = 2.0F;
constexpr float BORDER_BRIGHTNESS = 1.0F;
// Cinemàtica del slide.
constexpr float SLIDE_DURATION_S = 0.30F;
// Presets per als atajos semàntics.
constexpr SDL_Color COLOR_INFO{.r = 80, .g = 230, .b = 255, .a = 255};
constexpr SDL_Color COLOR_WARN{.r = 255, .g = 180, .b = 40, .a = 255};
constexpr SDL_Color COLOR_EXIT{.r = 255, .g = 80, .b = 80, .a = 255};
constexpr float DURATION_INFO = 2.0F;
constexpr float DURATION_WARN = 3.0F;
constexpr float DURATION_EXIT = 3.0F;
} // namespace Defaults::Notifier