How ducanhdaniel/dungeongamever2 works
Project Type and Purpose
• This is a full-stack game application. The “client” directory contains the game’s front-end (with assets, game engine code, component-based entity management, gamestates, input handling, map management, etc.), while the “server” directory houses a Spring Boot backend service (with controllers for authentication, record saving, and game saves).
• The README explains it as an action-adventure game with roguelike elements where players explore dungeons and interact with a backend for authentication and record keeping.
Analysis of the File Structure
• Client Module:
• Contains several directories:
• Assets & Resources (res, res_tile, maps, sound and font assets) for graphics, animations, and audio.
• Game engine code under src which is organized into modules such as “main,” “gamestates,” “entities” (including separate folders for monsters, NPCs, projectiles), “components” (such as Animation, Render, Physics, Hitbox), “system” (managing game logic for authentication, collectible items, rendering, monster behavior, door interactions, etc.), and “data” for game settings, save-load operations, and record data.
• The “api” folder shows that the client uses classes like ApiClient and HttpClient to interact with external services (i.e. the backend).
• Server Module:
• A Spring Boot application with:
• Controllers (LoginController, RecordController, SaveController) for handling client API requests.
• Data Transfer Objects (e.g., LoginDTO), Model classes (User, Record) indicating an MVC pattern.
• Service classes for file processing.
• Resources that include JSON files for user authentication and game saves.
• It uses a typical RESTful approach to serve data to the game client.
Final Assembly
• Inside the Client section, subdivide into:
• Core Engine & Game Loop, Gamestates/UI, Entity-Component Systems, and API Communication.
• In the Server section, subdivide into:
• REST API Controllers, Business Logic Services, and Data Persistence/Configuration.