Exemplo n.º 1
0
        public void Generate(int x, int y, string type)
        {
            for (int i = 0; i < x; i++)
            {
                mapArray.Add(new List <MapCase>());
                for (int j = 0; j < y; j++)
                {
                    MapCase newCase = null;
                    switch (type)
                    {
                    case "grass":
                        newCase = new MapCase(GlobalsVar.MeshModels["grassGround"], i * 5, j * 5, 0, 5, 5, 0.098f);
                        break;

                    case "dalles":
                        break;

                    default:
                        newCase = new MapCase(GlobalsVar.MeshModels["grassGround"], i * 5, j * 5, 0, 5, 5, 0.098f);
                        break;
                    }
                    mapArray[i].Add(newCase);
                }
            }
        }
Exemplo n.º 2
0
 public void Generate(int x, int y, string type)
 {
     for (int i = 0; i < x; i++)
     {
         mapArray.Add(new List<MapCase>());
         for (int j = 0; j < y; j++)
         {
             MapCase newCase = null;
             switch (type)
             {
                 case "grass":
                     newCase = new MapCase(GlobalsVar.MeshModels["grassGround"], i * 5, j * 5, 0, 5, 5, 0.098f);
                     break;
                 case "dalles":
                     break;
                 default:
                     newCase = new MapCase(GlobalsVar.MeshModels["grassGround"], i * 5, j * 5, 0, 5, 5, 0.098f);
                     break;
             }
             mapArray[i].Add(newCase);
         }
     }
 }