Hi,
I’m new to UE4 (but not to programming) and I want to build a small game similar to a RTS/City Builder.
For this I will need different input modes or tools:
- a ‘default mode’ where I can select buildings to get stats and select units to order them around
- a ‘build mode’ where I can place buildings, rotate them, etc.
- a ‘road tool’ to build roads
- a ‘sculpt mode’ where I can modify the terrain
- etc.
Now I’m basically lost where to put the logic for these modes. I could use an enum for all modes and use a switch in the player controller to get the different functionality, but that seems messy. It would be nicer to encapsulate the different functionalities in separate objects and then activate the one that’s needed.
What is a good way to handle this in UE4? Are there any examples for this available?
Help is greatly appreciated!