Add WVec.ToCVec() extension method.

This commit is contained in:
Paul Chote
2013-07-22 20:34:09 +12:00
parent bf9c737a11
commit f198d7f204

View File

@@ -72,8 +72,9 @@ namespace OpenRA
public static CPos BottomRightAsCPos(this Rectangle r) { return new CPos(r.Right, r.Bottom); }
}
public static class WPosExtensions
public static class WorldCoordinateExtensions
{
public static CPos ToCPos(this WPos a) { return new CPos(a.X / 1024, a.Y / 1024); }
public static CVec ToCVec(this WVec a) { return new CVec(a.X / 1024, a.Y / 1024); }
}
}