How can i make enemies not collide with each other?

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By StevenRafft

So, i have a 2 enemy kinematicbody2d, they move in a specific path, but they both keep colliding into each other, blocking both of them’s way, my enemy does NOT have a area2d in it, I want to do this without using layers/masks

my enemy looks like this:
Enemy (node)
–|StartPosition (position2d)
–|EndPosition (position2d)
–|Body (kinematicbody2d)
—>|CollisionShape2D
—>|Sprite

Why do you not want to do with without using masks? It would be simple to just turn off the mask for the enemy layer to prevent collisions.

exuin | 2021-05-29 06:51

If i do so, my bullet does not collide with the enemies

StevenRafft | 2021-05-29 18:23

Nevermind, I just found a solution

I had figured out that my raycast2d was not on the same collision mask as the enemies, Thanks for helping me :smiley:

StevenRafft | 2021-05-29 18:27