This week we will implement the UI components from the previous lesson in a Conversation UI element which would appear as part of a cut-scene before and/or after battles. The panels will hold a little bit of text along with a sprite showing who is speaking. A bouncing arrow will indicate when there is more to read and using the input “Fire” event will cause the conversation to move on to the next message or the next character who will speak, etc. These panels can appear in any corner of the screen (which could indicate the direction of a speaking character relative to the player), and will animate in and out of the screen as needed.
Projects
Tactics RPG Anchored UI
The user interface (UI) is one of those areas you always end up spending a lot of time implementing, and every game needs one in some form or fashion. I have built up a variety of reusable libraries in the past, but with Unity’s new UI tools I find myself starting over again. If you’re like me, the anchor and pivot system provided by a RectTransform may have been a bit confusing. I like working with it pretty well in the inspector, because I can modify the anchors and pivot to any corner for easy placement. In code, it wasn’t quite as easy, so this lesson is dedicated to the creation of a few reusable components which will, hopefully, make all our lives easier for awhile.
Tactics RPG Path Finding
Pathfinding can be a relatively advanced task, mostly because the logic takes a moment to grasp. We will be using a form of pathfinding to highlight all of the tiles that a unit can reach. When one of those tiles is selected the unit will follow the best path to the target. To make it more interesting, I will add three different movement types: a walking unit which must go around enemy units and tiles with too large a jump delta, a flying unit, and a teleporting unit.
Tactics RPG State Machine
This week we are going to create a State Machine which, over time, will handle all of the states which ultimately control our game’s logic. Initially I will create a state which is responsible for initialization (creating the game board, etc.) and then we will add another state which allows us to move the tile selection indicator around the board using events from our Input Controller. We will also add a simple Camera Rig to make sure that the game camera is always looking at something relevant.
Tactics RPG User Input Controller
In this lesson we will be writing a component to manage user input. We will work with Unity’s Input Manager so that your game should work across a variety of input devices (keyboard, controller, etc). The component we write will be reusable so that any script requiring input can receive and act on these events.
Tactics RPG Board Generator
In this lesson we will focus on creating one of our pre-production tools. We will create a scene from which we can generate boards to fight on. Along the way we will create an editor script for enhancing the inspector which will allow us to both randomly generate and hand modify the end result. Finally we will use scriptable objects to persist our data.
Tactics RPG Project Setup
In this project we will create and configure a new project to hold our Tactics RPG game engine. We will add folders for organization, import some existing assets, and create a few more assets which we will begin implementing in future lessons.
Tactics RPG Series Intro
I’ve decided to start a new section of my blog where I create working game samples and then blog about them. I have been working on a Tactics RPG game for awhile now and you can see the results so far in this sample video:
or download the and try out the project yourself.