Exemple #1
0
        private static void Test3()         //reminder that highspots are white and low spots are black
        {
            var table = new SandTable(2, 10);

            table.sands[new HexPoint(-1, 0, 1)].Height = 200;
            SandToImageExporter.SaveMatrixAsImage(table.ToMatrix(), outputFolder, "testJ.bmp", false);
        }
Exemple #2
0
        private static void Test4()
        {
            var table = new SandTable(100, 10);

            foreach (var key in table.sands.Keys)
            {
                var height = Math.Max(Math.Max(Math.Abs(key.Q), Math.Abs(key.R)), Math.Abs(key.S));
                table.sands[key].Height = height;
            }
            table.sands[new HexPoint(0, 0, 0)].Height = 1;
            SandToImageExporter.SaveMatrixAsImage(table.ToMatrix(), outputFolder, "testK.bmp");
        }
Exemple #3
0
        private static void Test2()         //Huge random table
        {
            var rand = new Random();

            var table = new SandTable(100, 10);

            foreach (var key in table.sands.Keys)
            {
                table.sands[key].Height = rand.Next(512);
            }

            SandToImageExporter.SaveMatrixAsImage(table.ToMatrix(), outputFolder, "testI.bmp");
        }
Exemple #4
0
        private static void Test1()
        {
            var table = new SandTable(2, 10);

            table.sands[new HexPoint(0, -1, 1)].Height = 1;
            table.sands[new HexPoint(1, -1, 0)].Height = 2;
            table.sands[new HexPoint(-1, 0, 1)].Height = 3;
            table.sands[new HexPoint(0, 0, 0)].Height  = 4;
            table.sands[new HexPoint(1, 0, -1)].Height = 5;
            table.sands[new HexPoint(-1, 1, 0)].Height = 6;
            table.sands[new HexPoint(0, 1, -1)].Height = 7;

            SandToImageExporter.SaveMatrixAsImage(table.ToMatrix(), outputFolder, "testH.bmp");
        }