How to add impulse at location using AsyncPhysicsTick in C++?

When im trying to even simply get a body instance it throws out this:

LogOutputDevice: Error: Ensure condition failed: IsInGameThreadContext()

1 Like

Bump the post!!
I also want to know how to do it!!

Heres the solution, the only thing you need is a body instance. (you should save it into a variable from gamethread)

GrabbedObject.AsBodyInstance->AddImpulseAtPosition(ForceToAdd * DeltaTime, CurrentTransform.GetLocation(), PlayerController->GetPhysicsTimestamp(), PlayerController);

1 Like

Thank you so much!!

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.