예제 #1
0
        public PlanetData(CelestialBody planet, SolarData system, int id)
        {
            this.planetID    = id;
            this.solarSystem = system;
            this.planet      = planet;

            // From here we add our randomizers
            orbitRandomizer      = new OrbitRandomizer(planet, this);
            geologicalRandomizer = new GeologicalRandomizer(planet, this);
            generalRandomizer    = new GeneralRandomizer(planet, this);
            atmosphereRandomizer = new AtmosphereRandomizer(planet, this);

            foreach (PlanetRandomizer randomizer in allRandomizers)
            {
                randomizer.Cache();
            }
        }
        public PlanetData(CelestialBody planet, string seed, int id)
        {
            this.planetID = id;
            this.seed     = seed;
            this.planet   = planet;

            // From here we add our randomizers
            orbitRandomizer      = new OrbitRandomizer(planet, this);
            geologicalRandomizer = new GeologicalRandomizer(planet, this);
            if (IsSun())
            {
                generalRandomizer = new GeneralRandomizer(planet, this);
            }
            atmosphereRandomizer = new AtmosphereRandomizer(planet, this);

            foreach (PlanetRandomizer randomizer in allRandomizers)
            {
                randomizer.Cache();
            }
        }