I’m encountering an issue where two player instances are being created when I run my project, even though I’ve tried removing one of them from the scene. For instance, when I attempt to remove one of the player instances programmatically, it results in no player instances being spawned at all.
I’ve made several attempts to resolve this:
- Code Refactoring: I tried rewiring my code and setting the generation scene as an autoload/global script to call it from anywhere.
- Inheritance: I explored using inheritance in my player and room scripts.
- Composition: I tried using composition as an alternative approach.
- Scene Attachment: I experimented with not attaching the player node to the scene generation.
Despite these efforts, I still face the issue of two player instances spawning, which is very frustrating. I apologize if my explanation isn’t entirely clear; this is my first time using Stack Overflow. Any help would be greatly appreciated.
Here are some references for context:
- Room Scene Script
- Generation of Room Script 1
- Generation of Room Script 2
- Generation of Room Script 3
- Generation of Room Script 4
- Generation of Room Script 5
This is my first time using StackOverflow so I’m sorry if my question is unclear or if there are any problems, thank you in advance for any assistance!
Seth Fuqua is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.