How quilfort/gameoff-2024 works
Project type and purpose
• This is a Godot-based game project (“The 500 Numbers Throne”), written in GDScript. It’s a single‐player/turn‐based tournament game with guessing battles, power‐ups, and secret strategies. The project structure follows Godot conventions: Scenes (UI and gameplay), Scripts (game logic and Singletons), Assets (graphics, fonts), and a Godot project file.
File structure
• Top‐level:
• project.godot – main Godot project descriptor
• Assets/ – all art assets (backgrounds, characters, fonts)
• Scenes/ – .tscn scene files (Menu, Battle, UI overlays)
• Scripts/ – GDScript logic, subdivided into Menu, Singleton, and per‐scene scripts
• UI/ – .tres resources for Buttons, Dialogs, Input fields
• “Singleton” folder contains global managers (battle_data, game_data, player_data, strategy_data, computer_data) registered in Godot as AutoLoad.
• No external services: everything runs inside the Godot engine.
README for additional insights
• Confirms GDScript and Godot engine.
• Gameplay flow: Main Menu → Tutorial → Before Battle → Battle → After Battle → Tournament → Credits.
• Planned features (power‐ups, strategies) hint at components to add.
a. Main components:
1. Godot Engine Core (SceneTree & main loop)
2. Scenes Layer
– Menu Scenes (main menu, settings, restart)
– Gameplay Scenes (before_battle, battle, after_battle, tournament, tutorial, character_dialog, credits)
– UI Overlay Scene (ui.tscn)
3. Script Layer
– Scene Controllers (e.g., menu_background.gd, battle.gd, ui.gd)
– Singletons (AutoLoad scripts providing shared state: game_data, player_data, computer_data, battle_data, strategy_data)
4. Assets Layer
– Sprites (Characters, Backgrounds)
– Fonts
b. Relationships & interactions:
– At startup, Godot loads project.godot and initializes Singletons → then loads main menu Scene.
– Scene Controllers connect to Singletons to read/write game state.
– UI Scene emits signals (button_pressed, guess_submitted) to controllers.
– Controllers update Singletons, trigger SceneTree.change_scene() to navigate.
– Assets are fetched by Scenes at load‐time.
c. Architectural patterns/design principles:
– MVC‐like separation:
• Model = Singletons (global state)
• View = Scenes & Assets
• Controller = Scripts attached to Scenes
– Event‐driven via Godot signals for UI interactions.
– AutoLoad Singletons for shared data rather than passing state manually.
d. Key technologies/frameworks:
– Godot Engine 4.x (assumed)
– GDScript for application logic
– Godot’s SceneTree for scene management
– Godot signals for event dispatch
– .tscn (scenes) and .tres (resources) file formats
Capturing essential architectural elements
• AutoLoad Singleton as its own component.
• That Scenes reference Scripts and Assets.
• Game flow from menu to tournament.