Skip to content

Commit

Permalink
fix RCS thrust transform position offset
Browse files Browse the repository at this point in the history
It needs to be moved in the frame of the thrust transform itself and not
relative to the parent transform...
  • Loading branch information
al2me6 committed May 13, 2023
1 parent acf1a0f commit 5085faf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Source/ROLib/ModelDef/ROLModelModule.cs
Original file line number Diff line number Diff line change
Expand Up @@ -958,7 +958,7 @@ private void ConstructSubModels(Transform parent)
{
foreach (var thrustTransform in clonedModel.transform.FindChildren(rcsData.thrustTransformName))
{
thrustTransform.localPosition += rcsData.thrustTransformPositionOffset;
thrustTransform.position += thrustTransform.rotation * rcsData.thrustTransformPositionOffset;
thrustTransform.localScale *= rcsData.thrustTransformScaleOffset;
}
}
Expand Down

0 comments on commit 5085faf

Please sign in to comment.