Dear developers,
We are in the process of releasing a bug-fix in the constraint ecosystem that may cause issues in your games if you have been relying on the incorrect behavior. We would like to ask anyone who is employing the feature described below to reach out with a testing place number where we will activate the bug-fix for you to experiment and fix any possible breakdowns before the release.
The correction is concerned with Cylindrical constraints/Hinge constraints when AngularActuatorType/ActuatorType is set to Servo AND AngularLimitsEnabled/LimitsEnabled is ON.
If all of the above conditions are met anywhere in your game, you should continue reading.
Under such circumstances, the previous behavior of the servo may be incorrect in some scenarios depending on the currentAngle, TargetAngle, LowerAngle, and UpperAngle. For instance, if you set up LowerAngle=-120, UpperAngle=120,Target Angle=110, and currentAngle=-110, the servo will eventually get locked at the angle currentAngle=-120. In other words, it will never reach your target angle because it is taking the shortest path toward the target angle, and it reaches the lower limit before reaching the target.
Note that this is not correct, because if the servo chooses the other direction it should be able to get to UpperAngle=110 with no problems. The current bug-fix addresses such issues. See this post. More details about the corrected servo behavior is as follows:
- If the servo can reach the target angle from the shortest path without encountering either of the upper and lower limits, it will.
- If the servo cannot reach the target angle from the shortest path without encountering either of the upper and lower limits, it will take the longest path.
- If the target angle is not in the feasible region and cannot be achieved (for example if TargetAngle>UpperAngle or TargetAngle<LowerAngle) the servo will take the path which will be eventually closer to the target angle.
- If the servo’s currentAngle is not feasible, (for example if currentAngle>UpperAngle or currentAngle<LowerAngle) then the servo will snap the current angle to the closest limits from LowerAngle and UpperAngle and then tries to work out the motion. Note that you should already have received a warning indicating that this is an incorrect setup and is discouraged to use because it can cause instability.
See the following figures for more examples (top:previous/incorrect and bottom:future/correct)
Please reach out with a testing place number for experimenting with this bug-fix in your game.
Please reach out to us with a testing place number if you are currently employing the feature described above.
Thank you.