🎮

Creating an Action RPG in Unity

Sep 17, 2024

Action RPG Tutorial Overview

Introduction

  • Action RPGs have a rich history:
    • Pioneers: Adventure for Atari.
    • Golden Era: Super Nintendo.
    • Modern Scene: Thriving indie games today.
  • Objective of the tutorial: Create an action RPG using Unity.
  • Placeholder art will be used during development for prototyping.

Getting Started with Unity's Tile Map System

  1. Create a Tile Map:

    • Navigate to the hierarchy, right-click, select 2D Object > Tile Map (rectangular).
    • A grid appears on the screen to start building the world.
    • Rename the Tile Map to Ground.
  2. Creating a Tile Palette:

    • If a tile palette isn’t created automatically:
      • Go to Window > 2D > Tile Palette.
      • Dock the palette window at the bottom.
      • Create a new palette called RPG Palette and save it in assets.
  3. Creating Tiles:

    • Right-click in the assets folder, go to Create > 2D Sprites > Square.
    • Drag the square into the palette and save it in assets.
    • Click on the ground layer and change its color (preferably to green) using the paint tool.
    • Use the paint bucket tool to fill in the area.
  4. Using a Color Palette:

    • Import a color palette and enlarge it for better visibility.
    • Use the dropper tool to select desirable colors for your game.

Adding Layers to the Map

  1. Add Water Layer:

    • Create a new tile map for water (similar process as ground).
    • Change the color for the water layer using the dropper tool to select a nice blue color.
    • Paint in features like rivers and oceans.
  2. Adding More Layers:

    • Repeat for other features (trees, mountains, etc.).
    • Make sure to set the order in layer for trees to be above ground to appear correctly.
    • Create layers for beaches, mountains, snow, etc., to develop the world.

Implementing Colliders

  1. Making Areas Unwalkable:
    • Click on the layer you want to make unwalkable (e.g., water).
    • In the inspector, add a component called Tilemap Collider 2D.
    • This will create colliders for all tiles in that layer, making them impassable.
    • Repeat this for trees, mountains, and snowy mountains.

Conclusion

  • A preliminary world has been created.
  • Next tutorial: Creating a character that can walk around the world.
  • Encouragement to like and subscribe if the tutorial was helpful.