Any way to limit physics forces?


is there a way to limit forces applied on a physics body by the physx engine? i am assuming its impulses.
rather like the wheeled vehicle suspension ping into space bug i am finding other instances where this happens.
for example using physics constraints sometimes makes the bodies ping into space. sometimes constrained meshes fight with each other resulting in tremendous spazzness (for want of a better description).
i could apply very high drag but this would affect how the body moves under normal conditions.

its kind of a game breaker so i either find a fix or change engines.



This behavior looks like incorrect collision settings. Have you disabled collision between physics constrained bodies (chassis and wheels)?

You can clamp vector size (Vector Length)

Get The Velocity and Clamp it, I use the same method for Physics based Character controller so it does not speed up.

how would i do that?

aha! nevermind i see it. its in constraint behaviour in the constraint properties.
edit: no it still pings into space

other edit:
clamping velocity temporarily after attaching simply delays the ping.
i made a new collision channel for the objects and set to ignore each other, still pings.

there must be something else going on as it only happens between certain objects

That is a good update. Check if the problem starts only with assets that have collision ‘block all’ or block all dynamics’.

it doesnt seem to make any difference what kind of collision.
i also made sure the attached object is well clear of the other object (not touching)

all objects are children of the same blueprint with the same settings. the only thing that changes is the static mesh. all static meshes have auto convex collision with no abnormalities.

a real head scratcher

So, is the chair just a static mesh actor or a blueprint with mesh? Check if the chair’s collision is ‘block all’. Typically, a vehicle collision profile should be ‘vehicle’, and try to enable ‘CCD’ and ‘multibody overlaps’ in vehicle collision settings. Then, you may want to check different settings for the collision between chair and vehicle. I hope that helps.

none of it is a vehicle.

all parts including the chair, chassis and wheels are basically a blueprint with a static mesh and a physics constraint.
i set the constraint properties in runtime, the attached bodies etc, and this is all working as it should.

most of the time everything works perfectly. the chair in the original post gif is an example of one that produces this behaviour. there is nothing special or different about it.
all the logic for driving the ‘vehicle’ is in a separate blueprint that only moves hinges or rotates ‘wheel’ joints. this control blueprint is not active when parts are attached.

the only solution it seems is to not use the problematic parts but it would be better to find the cause and fix it.
i have a suspicion its the same old bug with the physx engine. i did have a long chat with one of the nvidia developers way back and found the actual bug in the code but they refused to acknowledge it. its basically a line in the physics reaction code that allows infinity.

1 Like