forked from NotAShelf/rogged
render: extract color palette; convert floating labels to enum
Signed-off-by: NotAShelf <raf@notashelf.dev> Change-Id: I29c5feb6099fe321e227e0313282f1546a6a6964
This commit is contained in:
parent
3998fb5259
commit
eed5c3aff3
4 changed files with 151 additions and 53 deletions
70
src/render.h
70
src/render.h
|
|
@ -3,6 +3,76 @@
|
|||
|
||||
#include "common.h"
|
||||
|
||||
// HUD colors
|
||||
#define HUD_BG (Color){25, 20, 15, 255}
|
||||
#define HUD_BORDER (Color){139, 119, 89, 255}
|
||||
#define HUD_LIGHT_LINE (Color){60, 55, 50, 255}
|
||||
#define HUD_DARK_LINE (Color){15, 12, 10, 255}
|
||||
#define TEXT_DIM (Color){160, 150, 140, 255}
|
||||
#define TEXT_BRIGHT (Color){240, 230, 220, 255}
|
||||
|
||||
// HP bar colors
|
||||
#define HP_HIGH (Color){60, 180, 60, 255}
|
||||
#define HP_MED (Color){200, 180, 40, 255}
|
||||
#define HP_LOW (Color){200, 60, 60, 255}
|
||||
#define HP_BAR_BG (Color){20, 15, 15, 255}
|
||||
#define HP_BAR_BORDER (Color){80, 70, 60, 255}
|
||||
|
||||
// Enemy type colors
|
||||
#define COLOR_ENEMY_GOBLIN (Color){150, 50, 50, 255}
|
||||
#define COLOR_ENEMY_SKELETON (Color){200, 200, 200, 255}
|
||||
#define COLOR_ENEMY_ORC (Color){50, 150, 50, 255}
|
||||
|
||||
// Item type colors
|
||||
#define COLOR_ITEM_POTION (Color){255, 100, 100, 255}
|
||||
#define COLOR_ITEM_WEAPON (Color){255, 255, 100, 255}
|
||||
#define COLOR_ITEM_ARMOR (Color){100, 100, 255, 255}
|
||||
|
||||
// Action log colors
|
||||
#define LOG_BG (Color){15, 12, 10, 230}
|
||||
#define LOG_BORDER (Color){100, 85, 65, 255}
|
||||
#define LOG_DARK (Color){60, 50, 40, 255}
|
||||
#define LOG_TITLE_BG (Color){30, 25, 20, 255}
|
||||
#define LOG_TEXT (Color){180, 160, 130, 255}
|
||||
#define LOG_NEWEST (Color){220, 210, 200, 255}
|
||||
#define LOG_RECENT (Color){180, 170, 160, 255}
|
||||
#define LOG_OLDER (Color){150, 140, 130, 230}
|
||||
#define LOG_OLDEST (Color){120, 110, 100, 200}
|
||||
|
||||
// Inventory overlay colors
|
||||
#define INV_OVERLAY_BG (Color){12, 12, 12, 252}
|
||||
#define INV_BORDER (Color){70, 70, 70, 255}
|
||||
#define INV_SLOT_BG (Color){45, 45, 45, 255}
|
||||
#define INV_SELECTED (Color){180, 160, 80, 255}
|
||||
#define INV_EMPTY (Color){40, 40, 40, 255}
|
||||
#define INV_HINT (Color){65, 65, 65, 255}
|
||||
|
||||
// Floating text colors
|
||||
#define FLOAT_DAMAGE (Color){255, 100, 100, 255}
|
||||
#define FLOAT_CRIT (Color){255, 200, 50, 255}
|
||||
#define FLOAT_DODGE (Color){160, 160, 160, 255}
|
||||
#define FLOAT_BLOCK (Color){80, 130, 220, 255}
|
||||
#define FLOAT_SLAIN (Color){220, 50, 50, 255}
|
||||
#define FLOAT_DEFAULT (Color){200, 200, 200, 255}
|
||||
|
||||
// Floating label font sizes
|
||||
#define FONT_SIZE_FLOAT_LABEL 14
|
||||
#define FONT_SIZE_FLOAT_CRIT 16
|
||||
#define FONT_SIZE_FLOAT_DMG 18
|
||||
|
||||
// Message box colors
|
||||
#define MSG_BG (Color){45, 45, 45, 235}
|
||||
#define MSG_BORDER (Color){180, 180, 180, 255}
|
||||
|
||||
// End screen colors
|
||||
#define END_OVERLAY (Color){0, 0, 0, 210}
|
||||
#define END_BOX_BG (Color){20, 20, 20, 240}
|
||||
#define END_BOX_BORDER (Color){100, 100, 100, 255}
|
||||
|
||||
// Portrait placeholder
|
||||
// FIXME: remove when player sprites are available
|
||||
#define PORTRAIT_BG (Color){30, 30, 45, 255}
|
||||
|
||||
// Render the map tiles
|
||||
void render_map(const Map *map);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue