MCPcopy Create free account
hub / github.com/DanielChappuis/reactphysics3d / enableLimit

Method enableLimit

src/constraint/SliderJoint.cpp:98–109  ·  view source on GitHub ↗

Enable/Disable the limits of the joint * @param isLimitEnabled True if you want to enable the joint limits and false * otherwise */

Source from the content-addressed store, hash-verified

96 * otherwise
97 */
98void SliderJoint::enableLimit(bool isLimitEnabled) {
99
100 bool isEnabled = mWorld.mSliderJointsComponents.getIsLimitEnabled(mEntity);
101
102 if (isLimitEnabled != isEnabled) {
103
104 mWorld.mSliderJointsComponents.setIsLimitEnabled(mEntity, isLimitEnabled);
105
106 // Reset the limits
107 resetLimits();
108 }
109}
110
111// Enable/Disable the motor of the joint
112/**

Callers

nothing calls this directly

Calls 2

getIsLimitEnabledMethod · 0.45
setIsLimitEnabledMethod · 0.45

Tested by

no test coverage detected