|Topic was automatically imported from the old Question2Answer platform.
I am changing scenes when the player loses to go to the game over screen then back to the into screen. However, I’ve noticed that going from an Singleton/Autoload has no issues but going from a regular scene will sometimes give me the error in the screenshot attached… This error will never occur on the FIRST time we go to the game over screen but it can occur anytime after that. I’ve asked a few people and it seems like the game is trying to do something while the scene is not in the current tree. Is there a way of finding out what node is being called or what function/logic is still being worked on while the scene is NOT in the tree? I’m seriously at a loss as to how to fix this bug. The game itself doesn’t crash but if you play again, it will crash at some point due to the amount of error messages or whatever is it trying to do.
Turn Manager where the game over is called
Rest of the code if required
I will be eternal grateful if someone can help me out
remove_child to hide the node instead of
current_node.free() #this looses current_node's reference
current_node = loader.instance() #current_node doesn't exist
Edit: Completely read that wrong, there’s no issue here. It might be because you used
free instead of
queue_free but I can’t see any reference to
current_node whilst it’s freed.
Magso | 2020-01-04 13:54
I feel like a node is trying to process something when it’s time for the scene to change but I can’t seem to find what is trying to process.
ja-brouil | 2020-01-05 18:01