Search Results for

    Show / Hide Table of Contents

    Class RelativeVelocityRigidbodyTracking

    Component to track an object's displacement and rotation during an update. Also have a scaling factor based on player's relative velocity. This will fully attach for relative speeds below the minimum relative velocity and fully detach players for velocities over the maximum velocity threshold.

    Inheritance
    Object
    MovementTracking
    RigidbodyMovingGround
    RelativeVelocityRigidbodyTracking
    Implements
    IMovingGround
    Inherited Members
    RigidbodyMovingGround.Start()
    RigidbodyMovingGround.GetVelocityAtPoint(Vector3)
    MovementTracking.AvoidTransferMomentum()
    MovementTracking.ShouldAttach()
    MovementTracking.PreviousPosition
    MovementTracking.PreviousAttitude
    MovementTracking.ChangeAttitude
    MovementTracking.Displacement
    MovementTracking.FixedUpdate()
    MovementTracking.GetDisplacementAtPoint(Vector3)
    MovementTracking.GetTransferMomentumWeight(Vector3, Vector3)
    Namespace: nickmaltbie.OpenKCC.Environment.MovingGround
    Assembly: cs.temp.dll.dll
    Syntax
    public class RelativeVelocityRigidbodyTracking : RigidbodyMovingGround, IMovingGround

    Methods

    GetMovementWeight(Vector3, Vector3)

    Get the weight of movement for a given player's velocity at a given point.

    Declaration
    public override float GetMovementWeight(Vector3 point, Vector3 playerVelocity)
    Parameters
    Type Name Description
    Vector3 point

    Point where player is standing on the object.

    Vector3 playerVelocity

    Velocity of the player.

    Returns
    Type Description
    Single

    Weight of player's attachment to the object given these parameters. Will be between 0 (not attached at all) and 1 (fully attached).

    Overrides
    MovementTracking.GetMovementWeight(Vector3, Vector3)

    Implements

    IMovingGround
    In This Article
    Back to top OpenKCC Documentation