Răsfoiți Sursa

added to2D()

Nicolas Cannasse 3 luni în urmă
părinte
comite
088333928f
1 a modificat fișierele cu 4 adăugiri și 0 ștergeri
  1. 4 0
      h3d/Vector.hx

+ 4 - 0
h3d/Vector.hx

@@ -159,6 +159,10 @@ class VectorImpl #if apicheck implements h2d.impl.PointApi<Vector,Matrix> #end {
 		return new h3d.Vector4(x,y,z);
 		return new h3d.Vector4(x,y,z);
 	}
 	}
 
 
+	public inline function to2D() {
+		return new h2d.col.Point(x,y);
+	}
+
 	public function toString() {
 	public function toString() {
 		return '{${x.fmt()},${y.fmt()},${z.fmt()}}';
 		return '{${x.fmt()},${y.fmt()},${z.fmt()}}';
 	}
 	}