示例#1
0
        private Map loadBuiltinMap(MapInfo info)
        {
            Map map = null;

            if (info is RandomMap.RandomMapInfo)
            {
                map = new RandomMap(info.Level);
            }
            else if (info is EmptyMap.EmptyMapInfo)
            {
                map = new EmptyMap();
            }
            else if (info is EmptyFixedMap.EmptyFixedMapInfo)
            {
                map = new EmptyFixedMap();
            }
            else if (info is RandomEndlessMap.RandomEndlessMapInfo)
            {
                map = new RandomEndlessMap(info.Level);
            }
            return(map);
        }
示例#2
0
 private Map loadBuiltinMap(MapInfo info)
 {
     Map map = null;
     if (info is RandomMap.RandomMapInfo)
     {
         map = new RandomMap(info.Level);
     }
     else if (info is EmptyMap.EmptyMapInfo)
     {
         map = new EmptyMap();
     }
     else if (info is EmptyFixedMap.EmptyFixedMapInfo)
     {
         map = new EmptyFixedMap();
     }
     else if (info is RandomEndlessMap.RandomEndlessMapInfo)
     {
         map = new RandomEndlessMap(info.Level);
     }
     return map;
 }