Merge pull request #72325 from raulsntos/dotnet/fix-72321

C#: Fix `Rotated` and `RotatedLocal`
This commit is contained in:
Rémi Verschelde 2023-01-30 13:35:34 +01:00
commit ab70b6ca8a
No known key found for this signature in database
GPG key ID: C3336907360768E1

View file

@ -271,7 +271,7 @@ namespace Godot
/// <returns>The rotated transformation matrix.</returns> /// <returns>The rotated transformation matrix.</returns>
public readonly Transform2D Rotated(real_t angle) public readonly Transform2D Rotated(real_t angle)
{ {
return this * new Transform2D(angle, new Vector2()); return new Transform2D(angle, new Vector2()) * this;
} }
/// <summary> /// <summary>
@ -283,7 +283,7 @@ namespace Godot
/// <returns>The rotated transformation matrix.</returns> /// <returns>The rotated transformation matrix.</returns>
public readonly Transform2D RotatedLocal(real_t angle) public readonly Transform2D RotatedLocal(real_t angle)
{ {
return new Transform2D(angle, new Vector2()) * this; return this * new Transform2D(angle, new Vector2());
} }
/// <summary> /// <summary>