Custom NPCs not being handled by garbage collection

Please select what you are reporting on:

Creative

What Type of Bug are you experiencing?

Assets

Summary

Custom NPCs that were spawned at runtime are not being disposed of. After ending the game and restarting a session, some custom NPCs persist despite the session ending. The NPCS are not visible in the editor between sessions. Not sure if it is related but there are many verse runtime errors on ending a game. Many times a game is ended, verse throws a runtime error and points to the OnBegin() or another piece of the custom npc script. These are errors new to my project since the release of update 30.00, no code was touched and this island was running very well for hundreds of tests in the weeks prior to yesterday’s update.

Steps to Reproduce

Create a custom npc. Set up a npc spawner device to spawn several of them. After spawning 5-10 NPCS, end the game and restart the session. The NPCs spawned in the previous session often persist still.

Expected Result

The NPCs spawned in the previous session should not persist in between game sessions.

Observed Result

The NPCs are re appearing unexpectedly.

Platform(s)

PC, UEFN, verse, 30.00

Island Code

6817-3246-5847

Additional Notes

Noticed a bit of wonky behavior since 30.00

Here is an example of what the log looks like for the NPC wildlife on game end. As you can see, all of them are disposed of correctly:

Then here is an example of the Cusom NPC on end. The error I was describing occurs in the log almost immediately when I press ‘end game’ from the test session:

And here is the log showing that some npcs still are following their movement scripts even after the game as ended. The green arrow is where all custom wildlife script is successfully cleaned up, and the red arrow is code that should never fire but does for new custom npcs:

2 Likes