예제 #1
0
        public void LoadMap(int DotCount)
        {
            var rnd = new Random();

            var points = new HashSet <BenTools.Mathematics.Vector>();

            points.Clear();
            for (int i = 0; i < DotCount; i++)
            {
                points.Add(new BenTools.Mathematics.Vector(rnd.NextDouble() * MapSize,
                                                           rnd.NextDouble() * MapSize));
            }

            AllOfThem.Clear();


            MapHandler.LoadMap(new LoadMapParams(points, true));

            AddThemAll();

            //ImageCapturer.SaveToPng(AnyControl, "Capture.png");

            var mw = new MapWindow();

            mw.Show();
        }
예제 #2
0
        public void LoadMap(int DotCount)
        {
            var rnd = new Random();

            var points = new HashSet<BenTools.Mathematics.Vector>();
            points.Clear();
            for (int i = 0; i < DotCount; i++)
            {
                points.Add(new BenTools.Mathematics.Vector(rnd.NextDouble() * MapSize,
                                                            rnd.NextDouble() * MapSize));
            }

            AllOfThem.Clear();

            MapHandler.LoadMap(new LoadMapParams(points, true));

            AddThemAll();

            //ImageCapturer.SaveToPng(AnyControl, "Capture.png");

            var mw = new MapWindow();
            mw.Show();
        }