Replace hardcoded entity colors with D-033 relationship palette: Player=#e0e8ff, Npc=unknown teal #4a9ebb, Object=grey #8b8ba0. Phase 1 defaults by entity kind; Phase 2 (#361) will derive color from RelationshipState via knowledge graph. Entities in peripheral vision dimmed to 50% alpha (D-015). Player entity gets a Polygon2D triangle indicator showing facing direction, rotated from GameState.player_facing. 82 tests total, 0 failures. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
24 lines
1.1 KiB
GDScript
24 lines
1.1 KiB
GDScript
class_name Constants
|
|
|
|
# Shared constants used across rendering, game state, and protocol layers.
|
|
|
|
## Tile size in pixels — all renderers and coordinate conversions use this.
|
|
const TILE_SIZE: int = 32
|
|
|
|
# D-033: Entity relationship color palette
|
|
# Color represents the player's RELATIONSHIP to the entity, not an objective property.
|
|
# Phase 1: default colors by entity kind. Phase 2 (#361): driven by RelationshipState.
|
|
const ENTITY_COLOR_UNKNOWN: Color = Color("#4a9ebb") # Unknown/Neutral — cool teal
|
|
const ENTITY_COLOR_FRIENDLY: Color = Color("#6bc9a6") # Known/Friendly — soft green
|
|
const ENTITY_COLOR_POI: Color = Color("#e8c547") # Person of Interest — warm amber
|
|
const ENTITY_COLOR_HOSTILE: Color = Color("#d45d5d") # Hostile/Dangerous — muted red
|
|
const ENTITY_COLOR_OBJECT: Color = Color("#8b8ba0") # Static objects — muted grey
|
|
const ENTITY_COLOR_PLAYER: Color = Color("#e0e8ff") # Player character (detective)
|
|
|
|
# D-015: Peripheral vision dimming
|
|
const PERIPHERAL_ALPHA: float = 0.5
|
|
|
|
# Facing direction indicator
|
|
const FACING_INDICATOR_SIZE: float = 6.0
|
|
const FACING_INDICATOR_OFFSET: float = 14.0
|