Closed docmop closed 7 years ago
2.) is already fixed in dev code; suspension will slowly lerp into position during animation.
1.) Is a bit more complex. The only way to do it properly would be to disable the ability to retract whenever the wheel is grounded. Currently the animation seeks to maintain wheel orientation during the initial retracting so that it at least looks plausible that the wheel could retract while on the ground; changing it as you propose would remove any credibility of the animation when used while the aircraft was on the ground. (But honestly, you shouldn't be retracting the gear while landed anyway.... so might not be that big of a deal...)
Preventing retraction while it has contact would be way to limiting in terms of gameplay. The sequence was just a suggestion to make things more clear. I guess the following would work too.
IMHO it is not that bad if the wheel is not perfectly aligned with the the ground in stage 2 of the animation. Logically you would build this so that it can actually enter it's bay and ignore some itchiness when used on the ground.
I've reworked the animation a bit to (during retracting) first move everything into the 'default extended' position, and from there into the retracted position. This removes all clipping due to custom alignment, but leaves them looking visually unusable until fully deployed. (Wheel angle has to be done with step 1 as otherwise some of the wheels will clip into the door if rotated during step 2; so step 2 consists only of rotating the main suspension strut from deployed to retracted positions)
It also leaves the temporary deploy/retract colliders not lining up properly with the wheel position except when in the fully deployed position. I'm honestly fine with that, as if you are deploying/retracting these things on the ground, you are already doing something wrong; the colliders are just there to make sure that it still works when deployed, without them things clip into the ground and the raycasts don't register.
New animation system will be available in an update later today. I will not be doing any further adjustments to it until the new ALG suspension rigging system is in place.
Actually I have noticed two separate issues but they seem so closely related I guess one issue might be sufficent.
1) Animation clipping This mainly occurs when the ALG as a high leg angle offset. While retracting, the ALG moves all axes at the same time, leading to the gear clipping through its bay.
Suggestion: Split Animation into consecutive steps Example for Retraction
Deployment would be the other way round.
2) Suspension instant animation While retracting / deploying the ALG, the suspension jumps instantaneously to its target position.