Skip to content

Commit

Permalink
Merge pull request #63685 from aaronfranke/3.x-translated
Browse files Browse the repository at this point in the history
[3.x] Fix Translated method in C# affecting the original transform
  • Loading branch information
akien-mga authored Jul 30, 2022
2 parents 284dbef + 4d6c609 commit 82ed8a6
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions modules/mono/glue/GodotSharp/GodotSharp/Core/Transform.cs
Original file line number Diff line number Diff line change
Expand Up @@ -241,9 +241,9 @@ public Transform Translated(Vector3 offset)
{
return new Transform(basis, new Vector3
(
origin[0] += basis.Row0.Dot(offset),
origin[1] += basis.Row1.Dot(offset),
origin[2] += basis.Row2.Dot(offset)
origin[0] + basis.Row0.Dot(offset),
origin[1] + basis.Row1.Dot(offset),
origin[2] + basis.Row2.Dot(offset)
));
}

Expand Down

0 comments on commit 82ed8a6

Please sign in to comment.