How xenira/space3 works
Main Components
a) Client Layer:
• Bevy Game Engine (Main Client)
• UI Components
• Game States
• Networking Module
• Asset Management
• Input Handling
b) Server Layer:
• Game Logic Server
• PostgreSQL Database
• Game Instance Management
• Combat System
• Shop System
• Lobby System
c) Protocol Layer:
• Shared Data Types
• Communication Protocol
• Game Data (Gods/Characters)
[Client Tier]
• ↕
[Protocol Layer]
• ↕
[Server Tier]
Component Details
Client Tier (Blue Components):
• Sub-components:
• State Management (menu_login, game_combat, etc.)
• UI Components (prefabs, components)
• Asset Management (textures, fonts, vox models)
• Networking Module (polling, events)
Protocol Layer (Green Components):
• Protocol_types and protocol_data_types
• Data models for:
• Characters
• Gods
• Game States
• Communication Messages
Server Tier (Orange Components):
• Main Server Application
• Database (PostgreSQL)
• Service Modules:
• Game Service
• Combat Service
• Shop Service
• Lobby Service
• Game Instance Management
• Scheduler
Connection Flows
• Client-Server communication through the protocol layer
• Database interactions
• State transitions
• Service interactions
Additional Elements
Specialized sections for:
• Authentication flow
• Game state transitions
• Combat system interaction
• Shop system flow
• Lobby management
Technical Details
• Rust/Bevy for client
• PostgreSQL for persistence
• Docker for deployment
• WebAssembly support
• Diesel ORM
• Fairings for server middleware