top of page
RTS controller full screenshow.png

RTS Controller

Game Design, Programming, 3D Art, UI Design

Real-Time Strategy Player Controller Prototype

  • Icon-Unreal
  • Unreal blueprints icon
  • Icon-Blender
  • Icon-AfDesigner
  • Adobe illustrator icon

Overview

For over a decade now I’ve wanted to make a real-time strategy (RTS) game, but that type of project is a massive undertaking for anyone, let alone a solo developer. Despite this, I’ve still spent a disordinate amount of time designing one, which I call Project: Element, or Element for short. So, I thought, why not take a crack at just a part of it. See what sticks. This RTS controller project is the result.

Now let’s establish a few things before we get into it. This is not a game. When I say controller, I mean player controller. As in how the camera moves, and how you interact with the game. There are units and buildings and other RTS elements, but they are all just a facade. The units are basic, there is no sound, all art is just quick mockups. Nothing here is meant to show polish. This is, unabashedly, a rough prototype, and that is all.

I gave myself a hard deadline of a month to put together what I could in Unreal Engine 5.3 using just blueprints, and while I’m personally quite proud of the results, this is not remotely done. I just wanted to practice my programming skills, and take a crack at building some data driven game systems.

Finally, since this was always destined to be a prototype and nothing more at this point, I have unapologetically stolen icons from the canned Command & Conquer (C&C) Generals 2 [EA Games] from 2013, for no other reason than I think they’re cool.

Units

As mentioned, units are only barely implemented, since they weren’t the focus of this project. Units in Element are meant to be versatile, since there is a unit cap of 20, each has to do a number of things. I wanted to make a single unit to represent a significant investment of resources, and a significant shift in strategy.

You can select them with the LMB, using SHIFT to add or remove them from selection, or click and drag LMB to marquee select multiple units. You can command with the RMB, which at this point just moves them using a modified Unreal crowd controller and formation system.

They can also perform a number of actions, which are shown in the bottom right on the Action Bar. This shows a portrait of the unit, with its health and veterancy, as well as a row of icons counting the different units in the selection, and a bunch of buttons to issue commands. 

Element is designed in such a way that all available actions you can do, depending on your selected units, are shown at the same time. Where in a game like Starcraft, you might have 2 different spellcasting units in your group, but only one is shown in the command card. The action bar is designed to show all the available actions, from all the units in your group, at once. Smartly commanding only the units that can perform those actions when the command is issued.

There are common commands like attack move, split, stop, deploy and return to base, taking up the Z X C B and H keys respectively, which exist on several units and do what you think they’d do. There is also the recycle move, which sends a unit back to its production structure to be deleted and returns a portion of its resources to you. Below them are special actions, like Rocket pods or deploy mines, which are specific to a single unit, and fit into one of 5 action slots, shown in order on the bar and taking up the R F V G and T keys respectively. 

Below the portrait are stances, which changes the aggression of the unit, with Aggressive pursuing spotted enemies, Defensive holding ground, and Passive holding fire. While missing, it was also intended that any upgrades a unit has would show up in the bottom of the action bar as well. Units can take damage, heal and gain veterancy, represented by a small chevron on their health bar and portrait.

Unit control groups are also implemented and working, where pressing CTRL and any number key will make a group, and simply pressing the number key will select that group. Double tapping the number will also jump the camera to that group’s location.

A final note on units, there are also air units. These navigate overtop other units and buildings, up and down cliffs, and smoothly animate - most of the time. While units were out of scope for this project overall, this was a particular bugbear of mine for years. So… I maybe got a little vengeful with it - but I think overall came out pretty smooth!

Workers & Buildings

Workers operate like units, but have their own population cap of 3, and they are avoided in mass selection so they don’t charge into battle. Element is designed with a C&C generals style worker philosophy, where you only have a few and their only job is to build and repair. Resources in this game are harvested automatically by harvesting structures built on specific locations.


Workers have the unique action BUILD, which opens the building menu, showing all the buildings you can construct. This is the first example of a menu system I’ve used in a number of places. One major element missing here is that items you can’t build yet, would be greyed out. However, there is no prerequisite, or tech tree implemented in this prototype.


Once you select a building, your cursor gets a ghost of the building, which you can place on any valid terrain, and the worker will go over to build it. When the worker arrives, it will begin constructing and must remain there while doing so. If the worker is pulled away, the construction will stop, but you can right click the mid-construction building to call the worker back to it.


Once the building is placed it will consume resources, and once constructed it will begin either giving or taking power from your power grid.

Buildings can be selected just the same as units, and have a number of actions themselves. They have their own version of recycling, which slowly deconstructs the building and returns half its cost back to you.


They also have the action Rally, which doesn’t fully work. You can right click on the terrain with a building selected to a rally point, which spawned units will move towards.
Many have production abilities; the barracks train infantry units, factories produce vehicles, and airfields produce aircraft. Selecting these actions opens the familiar production menu, where you can select the unit you want to produce and the building will start working on it. If you have more than 1 of the same selected, it will spread the production across all the buildings.


Science buildings have a similar menu which researches upgrades, a feature not fully implemented, and command buildings have the action to produce a worker.
 

User Interface & HUD

I wanted to try and make something that was compact and out of the players way, scalable for functionality, and useful for new players. All functions, and more, in the interface have hotkeys which will be mentioned when relevant.

Starting at the top are the menus. F10 or Game menu pauses the game, offers settings and quitting out of the game. Team menu does not work, but would show all the players in the game and offer things like resource sharing, muting, kicking and so on. The chats would open text chat in game, and callouts would offer a radial menu of character quotes and voice lines relevant to the game.

Down in the bottom left is the minimap corner. Here we have the minimap, which projects the level and units to it. Missing features here would be clicking on the minimap to go to that location on the map, and showing alerts. To the left of the map is a non-functional ping button which would prime you for a contextual ping, and a button for the overmap, which actually changes the player screen marker in the minimap.

Moving to the top right of the map, there is a button to cycle through your builders and 2 buttons for selecting local and global combat units. With “local” selecting combat units on screen, and “global” selecting all combat units on the map. These can also be activated with either pressing Q once for local, or double tapping Q to select all.

Below that are 3 macro menus that make producing units, buildings and upgrades much easier while doing multiple things. Macro units, or Ctrl+C, will open a menu that lets you select any unit you can produce in your army, and allocates that job to whatever buildings you have that can do it. Macro buildings, or Ctrl+Z, opens a menu to produce a building like for a worker, and once the building is placed it assigns the closest available builder to go there and construct it. And Macro upgrades would do the same for upgrades, letting you manage upgrades depending on what science buildings you have available, but it didn’t get in before the deadline.

On the bottom of the screen there are control group buttons, where CTRL clicking them makes a group, and clicking, or double clicking them, selects or jumps the camera to them. These were implemented late into the project so, are missing a lot of polish and features, like removing them when all the units within die.

In the top middle is where your Commander Abilities would come into play. Element’s design is built around class based commanders that have different active and passive abilities, which would have been represented there. Along with a portrait of the commander, and experience gain which would let you unlock or upgrade abilities. This feature was blocked out, but was not built into the backend within the 1 month window.

 

And finally, the humble settings menu. What can I say, it’s super weird, and I put it right next to designing the credits sequences for movies, but it's one of those design roles I enjoy more than you’d expect. I’m a massive advocate of giving the player a lot of control over their game preferences. I strongly believe in the idea of “when in doubt, make it an option”. So all the gameplay preferences there do work, and even all the video settings. The audio, while working, is hard to show off when your game has, uh, no sound. But they work! I promise.

Conclusions

So all in, this was a resounding success of a project in my books. Is it perfect? Not a chance. Could I have done more? Absolutely. Will I add to it? Not for now, but maybe someday.

I learned a lot about Unreal blueprint coding, shout out to math expressions. Further improved my knowledge of data driven game systems, got deeper into the advanced input system, and learned more about how Unreal works under the hood. Got deeper into detour crowd AI and AI navigation, and finally got my flying units working. Learned a lot about render targets and projection. And got the chance to validate my design feelings about a more inclusive action RTS controller.

bottom of page