My Problem is some very wierd behaviour from Unity.
I have a Player Object with 3 Children each with their own Collider. Im trying to acces them from a script with :
ghb = GameObject.Find(“GroundHitbox”).GetComponent();
This produces a MissingComponentException, but only from time to time.
I could not find anything similar on Google, execpt [this Thread] ("There is no box collider attached..." yes, there is! - Questions & Answers - Unity Discussions), which advised to restart Unity.
This helped indeed but only temporary and after a time, without script changes, the Problem starts again.
Is there a better way to implement this, as the collider also seem to not call “OnCollisionEnter2D()” and “OnCollisionExit2D()” correctly.