How to prevent multiple sprites from overlapping each other

I have a player and 4 enemy sprites. The enemy sprites are going to follow the player using the path following extension, and right now, the enemies are overlapping each other. Is there any way to prevent the enemy sprites from overlapping each other?

3 Likes

You could try making them pathfind somewhere random if they are overlapping, so whenever they overlap they would spread out until they weren’t anymore, and then they could keep following you. That would probably make them much slower, and it’s not a very good solution, just the one I came up with off the top of my head.

2 Likes

Ok. I’ll try this.

if you were able to set tiles to be “occupied” that might help with the pathfinding

Thank you!

1 Like