Re: Freeze Physics

#12
character should have a capsule encapsule character colliding with terrain preventing from fallthrough. capsule should have movement constrains like not rolling and pitch should have slope angle min and max. as move character , you can use physics with force or transform with raycast (trigger).

Re: Freeze Physics

#15
You could try setting the Velocity to Vector3.Zero. This should cancel all movement received from physics.
Example:

Code: Select all

Entity.Physics.Velocity = Vector3.Zero;
This is what I used in the update for Sydewinder that's coming with 5.4 to make it ignore gravity. This doesn't set the AngularVelocity though, and since that's not exposed in 5.3 yet you will have to do it using this:

Code: Select all

Entity.Physics.Action ((Common.pe_action_set_velocity action) => { action.v = Vector3.Zero; action.w = Vector3.Zero; });
Does this do what you need?

Re: Freeze Physics

#17
That should be possible with the following code:

Code: Select all

var status = new pe_status_dynamics(); Entity.Physics.NativeHandle.GetStatus(status); Vector3 currentVelocity = status.v; Vector3 velocity = new Vector3 (0, 0, currentVelocity.Z); Entity.Physics.Action((Common.pe_action_set_velocity action) => { action.v = velocity; action.w = Vector3.Zero; });

Who is online

Users browsing this forum: No registered users and 1 guest