(Hello the images are from Gyazo because i have seen that the page got too long if i upload)
So my problem is exactly the same as :
So, I’ve been Googling this for almost a month, and still haven’t found anything. At first, I was trying to use the “Spawn Actor from Class node,” and that didn’t work, despite spawning a default controller with it. Next, I used the “Spawn AI from...
Reading time: 1 mins 🕑
Likes: 2 ❤
The answer was to set “Auto Posses Ai” to “Placed in World or Spawned” and so i did
I spawn the Ai with the “My_GameMode” at beginplay
I have no Behaviour Tree so i leave it empty i dont know if that is the problem?
But then it spawns the correct AIController but it doesn’t get the “controlled pawn”
why does my own AiController “Wave_AIController” not link with the AICharacter “Wave_AI”??
if i place the enemy in the world it works just fine?!?!!
The controller gets spawned before the pawn so the begin play triggers before possessing the pawn which means GetControlledPawn is Null, you should handle the OnPossess instead like the imag below, or do handle everything in the begin play of the pawn by getting the controller and executing some function on it from the pawn.
This was the answer I needed. After 4 hours of tearing my hair out. Thank you!
Big_R-07
(Big_R-07)
July 19, 2019, 2:00am
6
Awesome been racking my head with this problem until I found this thread. Solved the whole thing.