HingeJoint
Category: Core
A hinge between two 3D bodies.
enum Param:
- PARAM_BIAS = 0 — The speed with which the two bodies get pulled together when they move in different directions.
- PARAM_LIMIT_UPPER = 1 — The maximum rotation. only active if is .
- PARAM_LIMIT_LOWER = 2 — The minimum rotation. only active if angular_limit/enable is
true
. - PARAM_LIMIT_SOFTNESS = 4
- PARAM_LIMIT_RELAXATION = 5 — The lower this value, the more the rotation gets slowed down.
- PARAM_MOTOR_TARGET_VELOCITY = 6 — Target speed for the motor.
- PARAM_MOTOR_MAX_IMPULSE = 7 — Maximum acceleration for the motor.
- PARAM_MAX = 8 — Represents the size of the enum.
enum Flag:
- FLAG_USE_LIMIT = 0 — If , the hinges maximum and minimum rotation, defined by angular_limit/lower and has effects.
- FLAG_ENABLE_MOTOR = 1 — When activated, a motor turns the hinge.
- FLAG_MAX = 2 — Represents the size of the Flag enum.
Setter | set_param(value) |
Getter | get_param() |
The speed with which the rotation across the axis perpendicular to the hinge gets corrected.
- angular_limit/enable
Setter | set_flag(value) |
Getter | get_flag() |
If true
, the hinges maximum and minimum rotation, defined by angular_limit/lower and has effects.
- float angular_limit/lower
The minimum rotation. only active if is .
- float angular_limit/relaxation
The lower this value, the more the rotation gets slowed down.
- angular_limit/softness
Setter | set_param(value) |
Getter | get_param() |
- float angular_limit/upper
- motor/enable
Setter | set_flag(value) |
Getter | get_flag() |
When activated, a motor turns the hinge.
- float motor/max_impulse
Maximum acceleration for the motor.
- motor/target_velocity
Setter | set_param(value) |
Getter | get_param() |
Target speed for the motor.
Setter | set_param(value) |
Getter | get_param() |
The speed with which the two bodies get pulled together when they move in different directions.