4.12: Player Controller loading late

Hey! I updated to 2.12 a few days ago and a show-stopping bug came up. In 4.10 and 4.11 (I have upgraded this project multiple times), the PlayerController has always loaded first, as I believe it should. I’ve found plenty of documentation to reaffirm this fact.

However, in 4.12 the HUD is actually being loaded BEFORE the PlayerController. This is a huge issue as the HUD uses info from the Player, which is gathered from a reference within the PlayerController. If the PlayerController loads after the HUD, no information is passed to the HUD and nothing works.

I have parred the code back to the bare essentials (maybe some operation was stalling the load process?) but with no luck. As you can see below, There is nothing stalling the load and the classes print themselves immediately after Play begins.

Any help on this would be much appreciated. Thanks!

104920-pcprint.jpg

104931-hudload.jpg

Hello ,

After looking into your issue, it appears that this is working as intended. We don’t do anything to guarantee the order that BeginPlays get called. This means that you would have to add a delay, add an is valid check with a while loop, or find a different way to do things, if you always want to insure that things are loaded in the order you would like. I hope that this information helps.

Make it a great day

Thanks Rudy, got it solved. I now check to make sure the PC is valid before the HUD is drawn and everything is peachy.
Is there something you could point me to that gives a more in-depth explanation of the underlying load order? I would love to understand it more.
Thanks for the help!