Getting Started
Welcome to the 2D RPG Adventure Game System! This guide will help you get up and running quickly.
Installation
Requirements: Unity 2019.4 or later
Step 1: Import the Package
- Open your Unity project
- Go to
Assets > Import Package > Custom Package - Select the
2D_RPG_Adventure_System.unitypackagefile - Click Import to import all assets
Step 2: Verify Installation
After importing, you should see a new menu item: RPG Tools in the Unity menu bar.
Unity Menu Bar:
File Edit Assets GameObject Component Window Help RPG Tools
Setup Wizard
The Setup Wizard will guide you through the initial project configuration.
Running the Wizard
- Go to
RPG Tools > Setup Wizard - Follow the step-by-step instructions
- The wizard will create:
- Folder structure
- Game Manager
- Player character
- UI system
- Sample data
Important: Run the Setup Wizard in a new scene to avoid conflicts with existing GameObjects.
Creating Your First Scene
Scene Setup
1"comment">// After running the Setup Wizard, your scene should contain:
2"comment">// - GameManager (with all core systems)
3"comment">// - Player (with movement and stats)
4"comment">// - UI Canvas (with health bars and menus)
5"comment">// - Main Camera (configured "keyword">for 2D)
6
7"comment">// The GameManager automatically handles:
8GameManager.Instance.ChangeGameState(GameState.Playing);
Testing Movement
Press Play and use WASD or arrow keys to move the player character. The health and mana bars should be visible in the UI.
Player Setup
Configuring Player Stats
Select the Player GameObject and configure the PlayerStats component:
| Property | Description | Default |
|---|---|---|
| Max Health | Player's maximum health points | 100 |
| Max Mana | Player's maximum mana points | 50 |
| Strength | Affects attack damage | 10 |
| Defense | Reduces incoming damage | 5 |
Adding Player Sprites
- Select the Player GameObject
- In the SpriteRenderer component, assign your character sprite
- Use
RPG Tools > Player Animator Setupfor animation configuration
UI Configuration
Health and Mana Bars
The UI system automatically connects to the player stats. You can customize the appearance in the UIManager component.
1"comment">// UI updates are handled automatically through events
2playerStats.OnHealthChanged += UpdateHealthBar;
3playerStats.OnManaChanged += UpdateManaBar;
4
5"comment">// Manual UI updates
6UIManager.Instance.UpdateHealthBar(currentHealth, maxHealth);
Customizing UI Elements
Navigate to the UI Canvas in your scene hierarchy:
- Gameplay UI: Contains health bars, level display
- Inventory UI: Item management interface
- Dialogue UI: NPC conversation system
- Pause Menu: Game settings and controls