Bug #13109
ModuleDeployablePart not picking correct animation
0%
Description
If a part has multiple models with animations, the ModuleDeployablePart module picks the first one instead of respecting the animationName field.
Apparently this is due to a typo in the code; a line that reads "GetComponentInChildren" should read "GetComponentsInChildren" (note the S). Further developer details are in this forum post:
To reproduce, put the attached two parts in your GameData directory and place them in the Editor. You'll see only one works; the Extend button is missing in the broken one and the animation actually starts as soon as you pick it up from the toolbox.
Examining the CFG's, you'll note the only substantive difference between them is the ordering of the meshes. There are two meshes with animations: the spotlight, and the antenna. In the working CFG, the antenna mesh precedes the spotlight one; in the broken CFG, the spotlight mesh comes first.
The broken one fails because the typo is preventing ModuleDeployablePart from grabbing the correct animation.
Correct behavior would be for the animations to work in both, regardless of the ordering of the meshes.