2D Toolkit Forum

2D Toolkit => Support => Topic started by: Bridgeman on August 12, 2014, 09:07:07 pm

Title: Colliders not working
Post by: Bridgeman on August 12, 2014, 09:07:07 pm
So I followed this tutorial: http://www.unikronsoftware.com/2dtoolkit/doc/2.4/tilemap/tutorial.html
Then I followed this tutorial: http://www.unikronsoftware.com/2dtoolkit/doc/2.4/tutorial/creating_polygon_colliders.html

I made colliders for every single tile I used in my level, but when I added the Unity 2D player prefab, it just fell through the ground. On top of that, I can't see any of the colliders like in Scene view like in the screenshots. Not in 2D view and not in normal view.
Title: Re: Colliders not working
Post by: Bridgeman on August 13, 2014, 10:59:40 am
Bump
Title: Re: Colliders not working
Post by: unikronsoftware on August 13, 2014, 11:24:29 am
Have you set your sprite collection to 2d physics? Also try creating a box with 2d rigid body and box collider 2d, see if that falls through.
Title: Re: Colliders not working
Post by: Bridgeman on August 13, 2014, 11:43:18 am
I hadn't actually. It seems to be working now. But I still can't see the actual colliders in Scene view, even though they're there. That's a bit weird.
Title: Re: Colliders not working
Post by: unikronsoftware on August 13, 2014, 12:14:33 pm
Is it a tilemap you're testing this on?
Title: Re: Colliders not working
Post by: Bridgeman on August 13, 2014, 12:22:45 pm
Yes
Title: Re: Colliders not working
Post by: unikronsoftware on August 13, 2014, 01:56:13 pm
Tilemap colliders only appear when it is committed, or when you press play. It isn't visible otherwise.
Title: Re: Colliders not working
Post by: Bridgeman on August 13, 2014, 03:02:29 pm
I did commit it, but it still doesn't show, even when I press play
Title: Re: Colliders not working
Post by: unikronsoftware on August 13, 2014, 03:10:04 pm
Please either post your project, or a few screenshots - I'm not sure what is going on.
Title: Re: Colliders not working
Post by: Bridgeman on August 13, 2014, 04:43:15 pm
Oh nevermind, I can see the colliders now. I missed it because my colliders are fitted tightly around my tiles, so it was difficult to see.