I have a question regarding the make-up of an RTS game. Any help would be massively appreciated!
I am thinking that the general workings of the game would be this:
- GameMode will define the PlayerController and the AI Controller used.
- The PlayerController will set the default Pawn which in a RTS game I imagine, is the camera essentially. I imagine the mouse commands go in here to including some sort of variable to store the name of any Actor clicked to be used as a “is selected” flag, which can then trigger a different action on the second click such as “Move to” or “Attack”
The bit I am most unsure about is if the commands for the units go in an Actor Component, or the AI Controller. Essentially the player will select them, and the player will select an action, but the player does not do anything directly to make the Actor actually move or fight. Having this in the Actor isn’t ideal as you would have to copy it into every other actor type. Does anyone know how this sort of thing is handled in an RTS?
Thanks in advanced!
PS I am working in C++ so it would be great if you could take that into account, but I would still appreciate answers to do with BPs rather than nothing.