Hello Guest

Author Topic: sprite collider not working  (Read 6112 times)

tortelini66

  • 2D Toolkit
  • Newbie
  • *
  • Posts: 15
    • View Profile
sprite collider not working
« on: May 03, 2013, 09:14:08 pm »
Hey Guys,
I ran into antother problem with the 2dtoolkit although I think I just forgot something really simple I'm not able to find myself a solution.
I got a few sprites in a scene, some are animated, and some are not (but thats not important, because the problem is always there, animated or not), and they have polygon colliders on it. And if I ad a rigidbody to one of them, I expect it to collide with the the other sprites, when it fell down. But it didnt. The sprite just fell down, through the other sprite. The z Position should be the same.

Hope you can help me again.
Regards,
Tobi

unikronsoftware

  • Administrator
  • Hero Member
  • *****
  • Posts: 9709
    • View Profile
Re: sprite collider not working
« Reply #1 on: May 03, 2013, 10:57:34 pm »
2 mesh colliders cant collide in Unity unless one of them is tagged convex. Is that what is happening?

tortelini66

  • 2D Toolkit
  • Newbie
  • *
  • Posts: 15
    • View Profile
Re: sprite collider not working
« Reply #2 on: May 03, 2013, 11:03:06 pm »
I did not knew that, but its not the solution, even if I tag one of them convex, my sprite just fell through it.

unikronsoftware

  • Administrator
  • Hero Member
  • *****
  • Posts: 9709
    • View Profile
Re: sprite collider not working
« Reply #3 on: May 03, 2013, 11:09:20 pm »
Are the sprites too small? Does a normal unity box collide with these? Does the sprite collider with a Unity box?

tortelini66

  • 2D Toolkit
  • Newbie
  • *
  • Posts: 15
    • View Profile
Re: sprite collider not working
« Reply #4 on: May 04, 2013, 12:14:41 pm »
It did not work until I restarted Unity O.o, everything works with Unity Box Colliders, or the generated ones from 2Dtoolkit, and when I make my Sprite Convex it works too, BUT the convex option unticks itself when I start the game. Its only activated when I start the game ,then pause it, and then tick the convex option. So why is it disabling itself?

unikronsoftware

  • Administrator
  • Hero Member
  • *****
  • Posts: 9709
    • View Profile
Re: sprite collider not working
« Reply #5 on: May 04, 2013, 12:57:30 pm »
Tick convex in the sprite collection editor. it overrides the setting in the game view.

tortelini66

  • 2D Toolkit
  • Newbie
  • *
  • Posts: 15
    • View Profile
Re: sprite collider not working
« Reply #6 on: May 04, 2013, 04:15:48 pm »
I could hav guessed that. Seems like I have to learn a lot about this plugin. Anyways, that helped, thanks alot.