mirror of
https://github.com/godotengine/godot.git
synced 2025-01-19 08:22:01 +00:00
Fix build after c2a9cb34
`return` statements were missing, and those warnings do not need to be behind #ifdefs, they do not expose any deprecated API.
This commit is contained in:
parent
3c0ea513de
commit
ddfef86836
@ -82,11 +82,10 @@ void ConeTwistJointBullet::set_param(PhysicsServer::ConeTwistJointParam p_param,
|
||||
case PhysicsServer::CONE_TWIST_JOINT_RELAXATION:
|
||||
coneConstraint->setLimit(coneConstraint->getSwingSpan1(), coneConstraint->getSwingSpan2(), coneConstraint->getTwistSpan(), coneConstraint->getLimitSoftness(), coneConstraint->getBiasFactor(), p_value);
|
||||
break;
|
||||
#ifndef DISABLE_DEPRECATED
|
||||
default:
|
||||
ERR_EXPLAIN("This parameter " + itos(p_param) + " is deprecated");
|
||||
WARN_DEPRECATED
|
||||
#endif // DISABLE_DEPRECATED
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@ -102,11 +101,9 @@ real_t ConeTwistJointBullet::get_param(PhysicsServer::ConeTwistJointParam p_para
|
||||
return coneConstraint->getLimitSoftness();
|
||||
case PhysicsServer::CONE_TWIST_JOINT_RELAXATION:
|
||||
return coneConstraint->getRelaxationFactor();
|
||||
#ifndef DISABLE_DEPRECATED
|
||||
default:
|
||||
ERR_EXPLAIN("This parameter " + itos(p_param) + " is deprecated");
|
||||
WARN_DEPRECATED;
|
||||
return 0;
|
||||
#endif // DISABLE_DEPRECATED
|
||||
}
|
||||
}
|
||||
|
@ -152,11 +152,10 @@ void Generic6DOFJointBullet::set_param(Vector3::Axis p_axis, PhysicsServer::G6DO
|
||||
case PhysicsServer::G6DOF_JOINT_ANGULAR_MOTOR_FORCE_LIMIT:
|
||||
sixDOFConstraint->getRotationalLimitMotor(p_axis)->m_maxMotorForce = p_value;
|
||||
break;
|
||||
#ifndef DISABLE_DEPRECATED
|
||||
default:
|
||||
ERR_EXPLAIN("This parameter " + itos(p_param) + " is deprecated");
|
||||
WARN_DEPRECATED
|
||||
#endif // DISABLE_DEPRECATED
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@ -183,12 +182,10 @@ real_t Generic6DOFJointBullet::get_param(Vector3::Axis p_axis, PhysicsServer::G6
|
||||
return sixDOFConstraint->getRotationalLimitMotor(p_axis)->m_targetVelocity;
|
||||
case PhysicsServer::G6DOF_JOINT_ANGULAR_MOTOR_FORCE_LIMIT:
|
||||
return sixDOFConstraint->getRotationalLimitMotor(p_axis)->m_maxMotorForce;
|
||||
#ifndef DISABLE_DEPRECATED
|
||||
default:
|
||||
ERR_EXPLAIN("This parameter " + itos(p_param) + " is deprecated");
|
||||
WARN_DEPRECATED;
|
||||
return 0;
|
||||
#endif // DISABLE_DEPRECATED
|
||||
}
|
||||
}
|
||||
|
||||
@ -218,11 +215,10 @@ void Generic6DOFJointBullet::set_flag(Vector3::Axis p_axis, PhysicsServer::G6DOF
|
||||
case PhysicsServer::G6DOF_JOINT_FLAG_ENABLE_LINEAR_MOTOR:
|
||||
sixDOFConstraint->getTranslationalLimitMotor()->m_enableMotor[p_axis] = flags[p_axis][p_flag];
|
||||
break;
|
||||
#ifndef DISABLE_DEPRECATED
|
||||
default:
|
||||
ERR_EXPLAIN("This flag " + itos(p_flag) + " is deprecated");
|
||||
WARN_DEPRECATED
|
||||
#endif // DISABLE_DEPRECATED
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -116,11 +116,10 @@ void HingeJointBullet::set_param(PhysicsServer::HingeJointParam p_param, real_t
|
||||
case PhysicsServer::HINGE_JOINT_MOTOR_MAX_IMPULSE:
|
||||
hingeConstraint->setMaxMotorImpulse(p_value);
|
||||
break;
|
||||
#ifndef DISABLE_DEPRECATED
|
||||
default:
|
||||
ERR_EXPLAIN("This parameter " + itos(p_param) + " is deprecated");
|
||||
WARN_DEPRECATED
|
||||
#endif // DISABLE_DEPRECATED
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@ -143,12 +142,10 @@ real_t HingeJointBullet::get_param(PhysicsServer::HingeJointParam p_param) const
|
||||
return hingeConstraint->getMotorTargetVelocity();
|
||||
case PhysicsServer::HINGE_JOINT_MOTOR_MAX_IMPULSE:
|
||||
return hingeConstraint->getMaxMotorImpulse();
|
||||
#ifndef DISABLE_DEPRECATED
|
||||
default:
|
||||
ERR_EXPLAIN("This parameter " + itos(p_param) + " is deprecated");
|
||||
WARN_DEPRECATED;
|
||||
return 0;
|
||||
#endif // DISABLE_DEPRECATED
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -84,11 +84,10 @@ real_t PinJointBullet::get_param(PhysicsServer::PinJointParam p_param) const {
|
||||
return p2pConstraint->m_setting.m_damping;
|
||||
case PhysicsServer::PIN_JOINT_IMPULSE_CLAMP:
|
||||
return p2pConstraint->m_setting.m_impulseClamp;
|
||||
#ifndef DISABLE_DEPRECATED
|
||||
default:
|
||||
ERR_EXPLAIN("This parameter " + itos(p_param) + " is deprecated");
|
||||
WARN_DEPRECATED
|
||||
#endif // DISABLE_DEPRECATED
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user