Removing and/or disabling Static/Rigidy Body2D?

I used some similar code in my platform game to remove coins after the player collected them. I was originally using queue_free() but that was causing trouble with associated code.

The more complicated option:

$AnimatedSprite2D.visible = false
$CollisionShape2D.set_deferred("disabled",true)
1 Like