Hi, I’m a beginner with UE4 and I don’t know how to handle Controllers.
In my simple game I omitted PlayerControllers by handling everything in my only Player class, but now I need to create enemies. My idea was to create an AIController function with really basic logic that would then interact with its possessed Pawns. To set an example, let’s say my AIController has a function named Shoot(). It is called every once in a while, based on a timer, and all it does is call the respective Shoot() function in its possessed Pawn, which in turn has a more specific logic. And that is where the Controllers role ends. My question is, is it the right way to set this up, or is there a better, preffered way to do it?
And by the way, I’d like to know how can I cast an AActor* returned for example by GetControlledPawn() to its actual class. Let’s say AIController is controlling an AMyEnemyType instance. How do I GetControlledPawn() as AMyEnemyType* instead of AActor* ?