med-material / Whack_A_Mole_VR

Whack-A-Mole in VR
MIT License
3 stars 15 forks source link

Location Mole.cs : Moles not spawning when launching a game #229

Closed lucasmnt closed 1 year ago

lucasmnt commented 1 year ago

While working on animation feedback for the moles, I encountered a new bug where moles don't spawn anymore when launching a game.

It happened because a new line of code have been added in mole.cs, looking for renderer in child objects of the moles. If no renderer is found, it loops infinitely.

I've only added a if statement, verifying that there is indeed a renderer in the object and it fixed the bug.

See the function in question :

image