diff options
author | Rémi Verschelde <rverschelde@gmail.com> | 2018-04-18 12:43:21 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-04-18 12:43:21 +0200 |
commit | 3aaa5514d055ee4ad465b130109b351d0f05dd23 (patch) | |
tree | 6fb6f2821aed3322cedb5f564efb26dda50c5d1c /modules/mono/glue/cs_files/Transform.cs | |
parent | 1a3688d0cc13d1734977a36773666eb8e2f004ad (diff) | |
parent | 6b611e64316ed91b89822a3b660cdedc087a1da9 (diff) |
Merge pull request #18053 from mysticfall/master
#18051: Clean up and reformat C# source files
Diffstat (limited to 'modules/mono/glue/cs_files/Transform.cs')
-rw-r--r-- | modules/mono/glue/cs_files/Transform.cs | 21 |
1 files changed, 10 insertions, 11 deletions
diff --git a/modules/mono/glue/cs_files/Transform.cs b/modules/mono/glue/cs_files/Transform.cs index ce26c60706..d1b247a552 100644 --- a/modules/mono/glue/cs_files/Transform.cs +++ b/modules/mono/glue/cs_files/Transform.cs @@ -1,6 +1,5 @@ using System; using System.Runtime.InteropServices; - #if REAL_T_IS_DOUBLE using real_t = System.Double; #else @@ -29,7 +28,7 @@ namespace Godot public Transform LookingAt(Vector3 target, Vector3 up) { - Transform t = this; + var t = this; t.SetLookAt(origin, target, up); return t; } @@ -98,22 +97,22 @@ namespace Godot return new Vector3 ( - (basis[0, 0] * vInv.x) + (basis[1, 0] * vInv.y) + (basis[2, 0] * vInv.z), - (basis[0, 1] * vInv.x) + (basis[1, 1] * vInv.y) + (basis[2, 1] * vInv.z), - (basis[0, 2] * vInv.x) + (basis[1, 2] * vInv.y) + (basis[2, 2] * vInv.z) + basis[0, 0] * vInv.x + basis[1, 0] * vInv.y + basis[2, 0] * vInv.z, + basis[0, 1] * vInv.x + basis[1, 1] * vInv.y + basis[2, 1] * vInv.z, + basis[0, 2] * vInv.x + basis[1, 2] * vInv.y + basis[2, 2] * vInv.z ); } // Constructors public Transform(Vector3 xAxis, Vector3 yAxis, Vector3 zAxis, Vector3 origin) { - this.basis = Basis.CreateFromAxes(xAxis, yAxis, zAxis); + basis = Basis.CreateFromAxes(xAxis, yAxis, zAxis); this.origin = origin; } public Transform(Quat quat, Vector3 origin) { - this.basis = new Basis(quat); + basis = new Basis(quat); this.origin = origin; } @@ -164,8 +163,8 @@ namespace Godot { return String.Format("{0} - {1}", new object[] { - this.basis.ToString(), - this.origin.ToString() + basis.ToString(), + origin.ToString() }); } @@ -173,8 +172,8 @@ namespace Godot { return String.Format("{0} - {1}", new object[] { - this.basis.ToString(format), - this.origin.ToString(format) + basis.ToString(format), + origin.ToString(format) }); } } |