Пример #1
0
        public IUniverse GetUniverse(int id)
        {
            if (universeCache == null)
            {
                universeCache = mapGenerator.GenerateUniverse(id);
            }

            return(universeCache);
        }
Пример #2
0
 private void LoadGenerator(IMapGenerator generator)
 {
     Generator = generator;
     generatorName = generator.GetType().Name;
     Universe = generator.GenerateUniverse(0);
     Planet = generator.GeneratePlanet(0, seed);
 }