Example #1
0
        private MapShape GeneratePlayerShape()
        {
            Point position = new Point(Engine.Player.Tile.Position.X * Constants.TilePx / Scale.X, Engine.Player.Tile.Position.Y * Constants.TilePx / Scale.Y);
            Size  size     = new Size(3 * Constants.TilePx / Scale.X, 3 * Constants.TilePx / Scale.Y);
            //position = new Point(position.X + Engine.MapWindow.Canvas_MiniMap.Margin.Left,position.Y +Engine.MapWindow.Canvas_MiniMap.Margin.Top);

            Rect     rectangle = new Rect(position, size);
            MapShape t         = new MapShape((Vector)position, size, MapShape.TypeEnum.Player);

            return(t);
        }