How to make only certian objects Collid with each other (Make a walk-through shield)

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By lavaduder
:warning: Old Version Published before Godot 3 was released.

Okay I got three objects,
staticbody2D = floor
rigidbody2D = shield/ technically it’s a tail for the character, but…
kinematicbody2D = character

all have a colisionshape2D node
I want the character to go through the shield &
I want the shield to touch the ground (bounce off it, and cool stuff like that)

However the shield-like tail gets caught on the character, when ever it swings around.

I can’t set the collision as trigger, or it will go through the floor.
Is there a way to set a objects collision to allow pass-through for a certain object. Like collision layers or something?

:bust_in_silhouette: Reply From: kidscancode

Collision layers are exactly what you’re looking for.

You can read about them here:

Oh it’s in the body, not the collision itself. THANK YOU!

lavaduder | 2018-01-21 19:58

:bust_in_silhouette: Reply From: backendcoder

You should ID each object that you are concerned about in some way. I am new here, just adding some ideas about how to do stuff.