GenericConstraint

An all-in-one constraint capable to replace all other types of constraints. It is always recommended to use the optimized version of the constraint for the type of task you want to do. However, in the case you want to combine multiple types of constraints nto one; or if a more specific but optimized constraint version does not give you the amount of flexibility you require it is then recommended to use a generic constraint.

Generic constraints provide six degrees of freedom with or without spring capabilities; they are more CPU intensive compared to the other (more specific) type of constraints since these are built to achieve one specific task only.

See Also

Static Variables


Name Description
rigidconstraint Parent RigidConstraint the active GenericConstraint is associated to.
linear_lower_limit Minimum limit of the box that defines the constraint linear movements.
linear_upper_limit Maximum limit of the box that defines the constraint linear movements.
angular_lower_limit Lower angular limits of the constraint specified for each rotational axis.
angular_upper_limit Upper angular limits of the constraint specified for each rotational axis.
motor_linear_target_velocity The targeted linear velocity the motor will try to reach on each linear axis.
motor_linear_max_force Maximum amount of linear force to apply on each linear axis.
motor_linear_softness Percentage of limits where the linear movement is free, beyond this value limits will gradually be reinforced until the hard limit of 1.0 is reached.
motor_linear_damping Improve the stability of linear low pass jitter.
motor_linear_restitution Bounciness factor of the constraint on each linear axis.
motor_spring_linear_equilibrium_point The linear spring motor equilibrium point.
motor_spring_linear_stiffness Defines the amount of linear stiffness the spring motor will apply on each linear axis.
motor_spring_linear_damping Spring damping value to use for each axis to stabilize low pass jittering.
motor_angular_target_velocity Targeted angular velocity the motor will try to reach for each rotational axis.
motor_angular_max_force Maximum amount of angular force that the motor will apply on each rotational axis.
motor_angular_max_force_limits The constraint force limit for each rotational axis.
motor_angular_softness Percentage of limits where the rotational movement is free, beyond this percentage, the angular limit will gradually be reinforced until the hard limit of 1.0 (100%) is reached.
motor_angular_damping Value to improve the constraint's stability of angular low pass jitter.
motor_angular_restitution Bounciness factor of the constraint for each angular axis.
motor_spring_angular_equilibrium_point The angular spring motor equilibrium point.
motor_spring_angular_stiffness Amount of angular stiffness the spring motor will apply on each axis.
motor_spring_angular_damping Spring damping value to use for each rotational axis to stabilize low pass jittering.
cfm_linear Linear constant force mix factor.
cfm_stop_linear Linear constant force mix factor when the constraint`s linear limits are reached.
cfm_angular Angular constant force mix factor.
cfm_stop_angular Angular constant force mix factor when the constraint`s linear limits are reached.
erp_stop_linear Linear error reduction parameters when the constraint reached a linear limit.
erp_stop_angular The angular error reduction parameters when the constraint reached an angular limit.
motor_linear_x Current linear MotorType used by the linear X axis.
motor_linear_y Current linear MotorType used by the linear Y axis.
motor_linear_z Current linear MotorType used by the linear Z axis.
motor_angular_x Current linear MotorType used by the angular X axis.
motor_angular_y Current linear MotorType used by the angular Y axis.
motor_angular_z Current linear MotorType used by the angular Z axis.

Functions


Name Description
SetFrames Build the constraint frames between two rigid bodies.
Clear Setup the linear and angular limits of the GenericConstraint.
SetLinearMotor Controls the linear motor settings.
SetAngularMotor Controls the linear motor settings.
SetOverridesCFM Allows you to overrides the default CFM (constant force mixing) values.
SetOverridesERP Allows you to overrides the default ERP (error reduction parameters) values.
GetLocation Retrieve the GenericConstraint current location point.
GetLocation Get the current GenericConstraint rotational angles (in degrees).




NRG - API 2022.4.384543 - Fri Nov 4 2022
Copyright © 2022 nrgcore.com. All Rights Reserved. Terms of Service - Privacy Policy - EULA