You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-12 13:20:55 +00:00
RigidBody2D: add and bind get_inertia() method.
You can't set this value very well, since it's automatically computed from the mass and the collision shapes. But since the values are higher than many people might suspect, so being able to read it helps estimate the amount of torque you might need to apply.
This commit is contained in:
@@ -677,6 +677,7 @@ void Physics2DServer::_bind_methods() {
|
||||
BIND_CONSTANT( BODY_PARAM_BOUNCE );
|
||||
BIND_CONSTANT( BODY_PARAM_FRICTION );
|
||||
BIND_CONSTANT( BODY_PARAM_MASS );
|
||||
BIND_CONSTANT( BODY_PARAM_INERTIA );
|
||||
BIND_CONSTANT( BODY_PARAM_GRAVITY_SCALE );
|
||||
BIND_CONSTANT( BODY_PARAM_LINEAR_DAMP);
|
||||
BIND_CONSTANT( BODY_PARAM_ANGULAR_DAMP);
|
||||
|
||||
Reference in New Issue
Block a user