VectorToCell() public static method

public static VectorToCell ( Vector2 position ) : Point
position Microsoft.Xna.Framework.Vector2
return Microsoft.Xna.Framework.Point
示例#1
0
        public override void Update()
        {
            PreviousCellPosition = CellPosition;
            CellPosition         = Engine.VectorToCell(Position, Dimension);

            base.Update();
        }
示例#2
0
 public void ChangePosition(float x, float y)
 {
     _position.X   = x;
     _position.Y   = y;
     _cellPosition = Engine.VectorToCell(Position);
 }