diff options
Diffstat (limited to 'modules/bullet/hinge_joint_bullet.cpp')
-rw-r--r-- | modules/bullet/hinge_joint_bullet.cpp | 58 |
1 files changed, 29 insertions, 29 deletions
diff --git a/modules/bullet/hinge_joint_bullet.cpp b/modules/bullet/hinge_joint_bullet.cpp index 970732688a..4bea9f87c0 100644 --- a/modules/bullet/hinge_joint_bullet.cpp +++ b/modules/bullet/hinge_joint_bullet.cpp @@ -93,58 +93,58 @@ real_t HingeJointBullet::get_hinge_angle() { return hingeConstraint->getHingeAngle(); } -void HingeJointBullet::set_param(PhysicsServer::HingeJointParam p_param, real_t p_value) { +void HingeJointBullet::set_param(PhysicsServer3D::HingeJointParam p_param, real_t p_value) { switch (p_param) { - case PhysicsServer::HINGE_JOINT_BIAS: - WARN_DEPRECATED_MSG("The HingeJoint parameter \"bias\" is deprecated."); + case PhysicsServer3D::HINGE_JOINT_BIAS: + WARN_DEPRECATED_MSG("The HingeJoint3D parameter \"bias\" is deprecated."); break; - case PhysicsServer::HINGE_JOINT_LIMIT_UPPER: + case PhysicsServer3D::HINGE_JOINT_LIMIT_UPPER: hingeConstraint->setLimit(hingeConstraint->getLowerLimit(), p_value, hingeConstraint->getLimitSoftness(), hingeConstraint->getLimitBiasFactor(), hingeConstraint->getLimitRelaxationFactor()); break; - case PhysicsServer::HINGE_JOINT_LIMIT_LOWER: + case PhysicsServer3D::HINGE_JOINT_LIMIT_LOWER: hingeConstraint->setLimit(p_value, hingeConstraint->getUpperLimit(), hingeConstraint->getLimitSoftness(), hingeConstraint->getLimitBiasFactor(), hingeConstraint->getLimitRelaxationFactor()); break; - case PhysicsServer::HINGE_JOINT_LIMIT_BIAS: + case PhysicsServer3D::HINGE_JOINT_LIMIT_BIAS: hingeConstraint->setLimit(hingeConstraint->getLowerLimit(), hingeConstraint->getUpperLimit(), hingeConstraint->getLimitSoftness(), p_value, hingeConstraint->getLimitRelaxationFactor()); break; - case PhysicsServer::HINGE_JOINT_LIMIT_SOFTNESS: + case PhysicsServer3D::HINGE_JOINT_LIMIT_SOFTNESS: hingeConstraint->setLimit(hingeConstraint->getLowerLimit(), hingeConstraint->getUpperLimit(), p_value, hingeConstraint->getLimitBiasFactor(), hingeConstraint->getLimitRelaxationFactor()); break; - case PhysicsServer::HINGE_JOINT_LIMIT_RELAXATION: + case PhysicsServer3D::HINGE_JOINT_LIMIT_RELAXATION: hingeConstraint->setLimit(hingeConstraint->getLowerLimit(), hingeConstraint->getUpperLimit(), hingeConstraint->getLimitSoftness(), hingeConstraint->getLimitBiasFactor(), p_value); break; - case PhysicsServer::HINGE_JOINT_MOTOR_TARGET_VELOCITY: + case PhysicsServer3D::HINGE_JOINT_MOTOR_TARGET_VELOCITY: hingeConstraint->setMotorTargetVelocity(p_value); break; - case PhysicsServer::HINGE_JOINT_MOTOR_MAX_IMPULSE: + case PhysicsServer3D::HINGE_JOINT_MOTOR_MAX_IMPULSE: hingeConstraint->setMaxMotorImpulse(p_value); break; - case PhysicsServer::HINGE_JOINT_MAX: + case PhysicsServer3D::HINGE_JOINT_MAX: // Internal size value, nothing to do. break; } } -real_t HingeJointBullet::get_param(PhysicsServer::HingeJointParam p_param) const { +real_t HingeJointBullet::get_param(PhysicsServer3D::HingeJointParam p_param) const { switch (p_param) { - case PhysicsServer::HINGE_JOINT_BIAS: - WARN_DEPRECATED_MSG("The HingeJoint parameter \"bias\" is deprecated."); + case PhysicsServer3D::HINGE_JOINT_BIAS: + WARN_DEPRECATED_MSG("The HingeJoint3D parameter \"bias\" is deprecated."); return 0; - case PhysicsServer::HINGE_JOINT_LIMIT_UPPER: + case PhysicsServer3D::HINGE_JOINT_LIMIT_UPPER: return hingeConstraint->getUpperLimit(); - case PhysicsServer::HINGE_JOINT_LIMIT_LOWER: + case PhysicsServer3D::HINGE_JOINT_LIMIT_LOWER: return hingeConstraint->getLowerLimit(); - case PhysicsServer::HINGE_JOINT_LIMIT_BIAS: + case PhysicsServer3D::HINGE_JOINT_LIMIT_BIAS: return hingeConstraint->getLimitBiasFactor(); - case PhysicsServer::HINGE_JOINT_LIMIT_SOFTNESS: + case PhysicsServer3D::HINGE_JOINT_LIMIT_SOFTNESS: return hingeConstraint->getLimitSoftness(); - case PhysicsServer::HINGE_JOINT_LIMIT_RELAXATION: + case PhysicsServer3D::HINGE_JOINT_LIMIT_RELAXATION: return hingeConstraint->getLimitRelaxationFactor(); - case PhysicsServer::HINGE_JOINT_MOTOR_TARGET_VELOCITY: + case PhysicsServer3D::HINGE_JOINT_MOTOR_TARGET_VELOCITY: return hingeConstraint->getMotorTargetVelocity(); - case PhysicsServer::HINGE_JOINT_MOTOR_MAX_IMPULSE: + case PhysicsServer3D::HINGE_JOINT_MOTOR_MAX_IMPULSE: return hingeConstraint->getMaxMotorImpulse(); - case PhysicsServer::HINGE_JOINT_MAX: + case PhysicsServer3D::HINGE_JOINT_MAX: // Internal size value, nothing to do. return 0; } @@ -152,25 +152,25 @@ real_t HingeJointBullet::get_param(PhysicsServer::HingeJointParam p_param) const return 0; } -void HingeJointBullet::set_flag(PhysicsServer::HingeJointFlag p_flag, bool p_value) { +void HingeJointBullet::set_flag(PhysicsServer3D::HingeJointFlag p_flag, bool p_value) { switch (p_flag) { - case PhysicsServer::HINGE_JOINT_FLAG_USE_LIMIT: + case PhysicsServer3D::HINGE_JOINT_FLAG_USE_LIMIT: if (!p_value) { hingeConstraint->setLimit(-Math_PI, Math_PI); } break; - case PhysicsServer::HINGE_JOINT_FLAG_ENABLE_MOTOR: + case PhysicsServer3D::HINGE_JOINT_FLAG_ENABLE_MOTOR: hingeConstraint->enableMotor(p_value); break; - case PhysicsServer::HINGE_JOINT_FLAG_MAX: break; // Can't happen, but silences warning + case PhysicsServer3D::HINGE_JOINT_FLAG_MAX: break; // Can't happen, but silences warning } } -bool HingeJointBullet::get_flag(PhysicsServer::HingeJointFlag p_flag) const { +bool HingeJointBullet::get_flag(PhysicsServer3D::HingeJointFlag p_flag) const { switch (p_flag) { - case PhysicsServer::HINGE_JOINT_FLAG_USE_LIMIT: + case PhysicsServer3D::HINGE_JOINT_FLAG_USE_LIMIT: return true; - case PhysicsServer::HINGE_JOINT_FLAG_ENABLE_MOTOR: + case PhysicsServer3D::HINGE_JOINT_FLAG_ENABLE_MOTOR: return hingeConstraint->getEnableAngularMotor(); default: return false; |