Actor component removing itself from actors after engine restart?

Michael Kocha
Mon, 24 Jun 2019 00:40:51 +0000
Blueprint

I’m using a Blueprint actor component that handles spawning loot for my NPC’s in the game. This component is used in many other places as well, such as treasure chests which also use it to spawn loot.

For some reason, recently, each time I restart the engine, test the game and trigger an NPC to spawn any sort of loot, I get the error: “Accessed None trying to read property BPC_LootSpawn” even though the component is still there. The NPC blueprint still compiles like normal even while this issue is happening, and the only real indicator I have that there’s something wrong, is that the component can’t be duplicated by right clicking. After I restart the engine again, sometimes the component is entirely gone.

Replacing the component and replacing all references in the NPC blueprint fixes the issue… until I restart the engine again. I packaged a project for Steam recently and the component IS broken in the packaged build, but I don’t know if was fixed in the editor beforehand because I hadn’t had time to explore the issue.

I combed through my NPC and I know for a fact that it’s never being removed anywhere unintentionally. This has got to be some sort of bug, and I really need to find a fix for it. It’s about 5 to 10 minutes of work to get it up and running each time I start my project back up.

3 posts - 3 participants