I’m making a 2D game on Unity and I put colliders on both the Player and the Object I want it to collide with. All I want at the moment is for the player to not be able to walk through it, but it still does this. All the tutorials I watched seem to not have this issue. I have attached pictures of all relevant menus and happenings.
This is the Player character, you can see the collider. The Player character’s settings, you can see that I have a collider. These are the settings on the Nursery, which is the Object I want to not go through. However, as you can see, the Player goes through the Nursery despite the colliders I put. I’m completely at a loss for what to do about this, please advise.you need rigidBody component attached to the nursery for it to work
I just did so. It still does not work. You can view this in the image:
Change the body type on both to dynamic, and gravity scale to 0
I just tried this, and it worked! I also had to freeze the nursery in position, because my first test had it flying off the screen to who-knows-where, LOL. Thank you very much for your assistance.
1 Like