[Solved] Throwing objects not working in my platformer

Hi! I’m making a game where you can pick up civilians in your hands, carry them and then throw them around.

My ground tiles and objects contained in “civilians” family both have Physics2D Behaviour. When you pick them up your player state changes and they follow player position. Then, when you press the button, an impulse is applied to civilian sprite.

In theory everything should work, but instead player just drops them. Any idea what to do? I think i tried all the different variation sequences…
throwingbug

Try civilians.CenterX() civilians.CenterY()

1 Like

applied it, but nothing changed.

You’re applying the impulse force before turning on physics on the civilian objects.

Move the turn on physics action to the event in which the x key and return key checks are made. There’s no need to be almost constantly turning on physics as the current event is doing.

Thank you! Finally it works the way i want.