-
Notifications
You must be signed in to change notification settings - Fork 0
Game States & Menus
The Game States & Menus system controls the overall flow of Adventure-Game. It determines what the player sees, how different parts of the game are accessed, and how navigation is handled throughout the application.
Since Adventure-Game is a console-based RPG, menus serve as the primary interface between the player and the game's systems. Every action—from creating a character to managing equipment—is accessed through a structured menu hierarchy.
The current implementation focuses on providing a simple, intuitive navigation system while keeping the architecture modular enough to support future gameplay expansion.
- Overview
- Game Flow
- Main Menu
- Character Creation
- Game Menu
- Inventory Menu
- Equipment Menu
- Settings Menu
- Help Menu
- State Transitions
- Menu Architecture
- Future Improvements
- Summary
A game state represents the current part of the application that the player is interacting with.
Only one game state is active at any given time.
Examples include:
- Main Menu
- Character Creation
- Gameplay
- Inventory
- Settings
- Help
Each state has its own responsibilities and available actions.
The game follows a structured navigation flow.
flowchart TD
Launch --> MainMenu
MainMenu --> NewGame
MainMenu --> LoadGame
MainMenu --> Settings
MainMenu --> Help
MainMenu --> Exit
NewGame --> CharacterCreation
CharacterCreation --> Gameplay
Gameplay --> Inventory
Gameplay --> CharacterStats
Gameplay --> SaveGame
Gameplay --> MainMenu
The player moves between states through menu selections.
The Main Menu is the first interface shown after launching the game.
Typical options include:
| Option | Description |
|---|---|
| Start Game | Begin a new adventure. |
| Load Game | Load a saved game (framework). |
| Save Game | Save current progress (framework). |
| Settings | Open configuration options. |
| Help | View gameplay instructions. |
| Exit | Close the application. |
The Main Menu acts as the central navigation hub.
When starting a new game, the player enters the Character Creation state.
During this stage the player:
- Enters a character name
- Selects a race
- Selects a profession
- Enters age
- Creates a character profile
After completion:
- Initial statistics are generated.
- Starting equipment is assigned.
- Inventory is initialized.
- Gameplay begins.
The Game Menu becomes available after character creation.
It provides access to the game's primary systems.
Typical options include:
| Option | Description |
|---|---|
| Character Statistics | View player information. |
| Inventory | Manage collected items. |
| Equipment | Equip or unequip gear. |
| Save Game | Save current progress. |
| Settings | Open game settings. |
| Help | View controls and information. |
| Return | Resume gameplay. |
This menu acts as the central gameplay interface.
The Inventory Menu allows the player to manage collected items.
Available actions include:
- View inventory
- Inspect items
- Equip weapons
- Equip armor
- Use potions
- Remove items
The Inventory Menu communicates directly with the Inventory System and Character System.
The Equipment Menu displays currently equipped items.
Information may include:
- Equipped weapon
- Equipped armor
- Total attack
- Total defense
Players can:
- Equip new items
- Replace equipment
- View equipment statistics
The Settings Menu provides access to configurable game options.
Current implementation focuses on the menu framework.
Future settings may include:
- Text speed
- Difficulty
- Audio options
- Display preferences
- Gameplay options
The Help Menu provides useful information for new players.
Typical content includes:
- Basic controls
- Gameplay tips
- Menu explanations
- Item descriptions
- Frequently asked questions
The Help Menu allows players to learn the game without leaving the application.
Each menu transitions to another state depending on the player's selection.
stateDiagram-v2
[*] --> MainMenu
MainMenu --> CharacterCreation : New Game
MainMenu --> LoadGame : Load
MainMenu --> Settings
MainMenu --> Help
CharacterCreation --> Gameplay
Gameplay --> Inventory
Gameplay --> Equipment
Gameplay --> CharacterStats
Gameplay --> SaveGame
Gameplay --> MainMenu
Settings --> MainMenu
Help --> MainMenu
Inventory --> Gameplay
Equipment --> Gameplay
The player can freely navigate between gameplay-related states without restarting the application.
The menu system follows a hierarchical structure.
Main Menu
│
├── Start Game
│ │
│ └── Character Creation
│ │
│ └── Gameplay
│ │
│ ├── Character Stats
│ ├── Inventory
│ ├── Equipment
│ ├── Save
│ ├── Settings
│ └── Help
│
├── Load Game
├── Settings
├── Help
└── Exit
This organization keeps navigation intuitive while separating gameplay systems into logical sections.
Several architectural choices shaped the menu system.
The project uses straightforward text-based menus to keep gameplay accessible and easy to understand.
Each menu represents an independent game state.
This makes it easier to introduce additional menus without affecting existing functionality.
The menu system handles only user interaction.
Gameplay logic remains inside dedicated systems such as:
- Character System
- Inventory System
- Equipment System
- Weapon System
- Armor System
- Potion System
- Chest System
The menu hierarchy has been designed to support future features without requiring major structural changes.
The Game States & Menus system can be expanded with many additional features.
Planned improvements include:
- Pause menu
- Confirmation dialogs
- Save slot selection
- Quest journal
- Crafting menu
- Trading interface
- Skill tree menu
- Character customization
- NPC dialogue menus
- Keyboard shortcuts
- Colorized console interface
- Mouse support (GUI version)
- Graphical user interface (future)
The modular architecture allows these features to be added while preserving the existing navigation flow.
The Game States & Menus system provides the navigational framework of Adventure-Game. By organizing the application into clearly defined states and menus, it enables players to interact with every major gameplay system in a consistent and intuitive manner.
As the project evolves, this architecture will support additional gameplay features, more advanced navigation, and eventually a graphical user interface, all while maintaining a clean and modular codebase.