#pragma once #include #include struct Entity; /** * Shared execution context that flows through every entity and component so * they can read/write the global scroll, known entity handles, and reset state. */ struct GameContext { /** * Pointer to the global entity list stored in `main.cpp`, allowing systems * or components to inspect/create entities. */ std::vector> *entities = nullptr; /** * Entity that owns the static world geometry (terrain, background, etc.). */ Entity *worldEntity = nullptr; /** * Entity representing the gravity well that drags collectibles/probe. */ Entity *wellEntity = nullptr; /** * Entity for the player's probe input/state representation. */ Entity *probeEntity = nullptr; /** * HUD entity that draws meter/score/probe status overlays. */ Entity *hudEntity = nullptr; /** * Global horizontal scroll offset that components read to position * themselves on screen. */ float scrollX = 0.0f; /** * Flag that a component (usually reset button) can toggle to request the * gameplay systems reset the probe/meter/collectibles. */ bool resetRequested = false; };