What order are Controllers and Pawns/Characters instantiated?

CodingRook
Sun, 29 Dec 2019 12:54:28 +0000
Editor Scripting

During recent work on creating custom derived classes from PlayerController and Character, I ran into some nullpointer problems. Can anyone explain in clear manner, or point to clarifying documentation or other resource, that explains what is the sequence of events (a diagram/simple schematic would help) when we create a new controller and a new pawn/character. Who gets instantiated first, when possession takes place etc. As I just explained, several times when creating subobjects or trying to access each class so that the two objects can communicate with each other, I ran into exceptions, where the pawn/character reference wasn’t there yet and ready to be read etc.

Thanks!

6 posts - 1 participant