A cute little game, with cute little sprites. However, I noticed a bug that made the game quite unwieldy.
If I guessed correctly you are using colliders for both the bamboos and the panda and you have an OnCollisionEnter2D script to detect the "eating", which is a fine method.
Meanwhile, instead of spawning bamboo clones, the bamboos is the same gameobject that teleports around every time it gets eaten, which is fine on its own too.
However, with these two features togther, and no method of preventing the bamboo from teleporting to a place too close to the panda caused a bug that prevents me from eating the bamboo if the bamboo teleports right next to me. And on top of that, you seem to have no restriction on panda's rb rotation which combined with the bug above, would make my panda (and the camera attached to it) rotate if I run into the corner of the bamboo.
Use OnCollisionStay2D, or simply putting a code that checks the distance in x axis right after the teleporting method and re-teleport until the is enough would do.
← Return to game
Comments
Log in with itch.io to leave a comment.
A cute little game, with cute little sprites. However, I noticed a bug that made the game quite unwieldy.
If I guessed correctly you are using colliders for both the bamboos and the panda and you have an OnCollisionEnter2D script to detect the "eating", which is a fine method.
Meanwhile, instead of spawning bamboo clones, the bamboos is the same gameobject that teleports around every time it gets eaten, which is fine on its own too.
However, with these two features togther, and no method of preventing the bamboo from teleporting to a place too close to the panda caused a bug that prevents me from eating the bamboo if the bamboo teleports right next to me. And on top of that, you seem to have no restriction on panda's rb rotation which combined with the bug above, would make my panda (and the camera attached to it) rotate if I run into the corner of the bamboo.
Use OnCollisionStay2D, or simply putting a code that checks the distance in x axis right after the teleporting method and re-teleport until the is enough would do.