コード例 #1
0
ファイル: Vector2d.cs プロジェクト: manaorb/GodotExtraMath
 /// <summary>
 /// Returns this vector with all components rounded to the nearest integer,
 /// with halfway cases rounded towards the nearest multiple of two.
 /// </summary>
 /// <returns>The rounded vector.</returns>
 public Vector2d Round()
 {
     return(new Vector2d(Mathd.Round(x), Mathd.Round(y)));
 }
コード例 #2
0
ファイル: Vector4d.cs プロジェクト: manaorb/GodotExtraMath
 public Vector4d Round()
 {
     return(new Vector4d(Mathd.Round(x), Mathd.Round(y), Mathd.Round(z), Mathd.Round(w)));
 }
コード例 #3
0
ファイル: Vector3d.cs プロジェクト: manaorb/GodotExtraMath
 /// <summary>
 /// Returns this vector with all components rounded to the nearest integer,
 /// with halfway cases rounded towards the nearest multiple of two.
 /// </summary>
 /// <returns>The rounded vector.</returns>
 public Vector3d Round()
 {
     return(new Vector3d(Mathd.Round(x), Mathd.Round(y), Mathd.Round(z)));
 }