Auto Collision Borders too loose

Hello all,

I’m looking at collisions being generated on sprites, and it appears if there are sharp corners they aren’t followed very closely, is there some way to improve this?

The Cross spite is an example, where the collision border hasn’t followed the edges of the sprite very closely? Any assistance in this is greatly appreciated.

Cheers,
Spen

Collision shapes have to be water tight and convex, not concave. That is why these auto-generated shapes do not go inward.

An option you have is to create collision shapes manually. You can build more complex collision setups by having multiple collision shapes attached to a collision object.

Of course the ideal would be for the auto-generated shapes to automatically generate multiple shapes to fill complex sprites. The code is available on github so anyone could add this.

2 Likes

Hello Pkeod,

That’s an awesome answer, thanks very much. I’ll have a look into it (although I doubt I have the skills to add anything meaningful).

Aside from that, I’ll have a look at manually creating collision shapes.