I don't know what's different in this case, as I've got a decent understanding of godots signals and physics layers/masks, but this one isn't working. I'll try to illustrate what I have
-
I have a player. The players attack produces a thrown weapon that has a
StaticBody2D. The weapon becomes active for the duration of the attack. The weapon is in thePlayerWeaponphysics layer. It has theEnemyphysics mask -
I have an enemy. The enemy has an
Area2D. The enemy has a script with the_on_body_enteredsignal that should print the body that entered. The enemy is in theEnemylayer, and has thePlayerWeaponmask
The signal does not get fired when the weapon hits the enemy. If I mess around with the layers/masks, I can get the enemy Area2D to interact with the player and environment layers. It's just these 2 layers in particular that won't interact with each other
The layers are
1 - environment
2 - player
3 - enemy
4 - playerWeapon