示例#1
0
        public GodModeData(DefData defData)
        {
            _defData = defData;

            // get alerted when RimWorld has loaded its definition (Defs) files
            _defData.DefParsed += InitDefs;

            // get alerted when a new world is generated
            PrepareLanding.Instance.EventHandler.WorldGeneratedOrLoaded += ExecuteOnWorldGeneratedOrLoaded;
        }
示例#2
0
        public GameData(FilterOptions filterOptions)
        {
            // Definitions (Def) from game. Won't change on a single game; might change between games by using other mods.
            DefData = new DefData(filterOptions);

            // holds user choices from the "god mode" tab.
            GodModeData = new GodModeData(DefData);

            // holds user filter choices on the GUI.
            UserData = new UserData(filterOptions);

            // data specific to a single generated world.
            WorldData = new WorldData(DefData);
        }
示例#3
0
        protected WorldCharacteristicData(DefData defData)
        {
            DefData = defData;

            PrepareLanding.Instance.EventHandler.WorldGeneratedOrLoaded += ExecuteOnWorldGeneratedOrLoaded;

#if TAB_OVERLAYS
            // Cocorico!
            GradientColors = new List <Color> {
                Color.blue, Color.white, Color.red
            };

            _colorGradient = ColorUtils.CreateSolidGradient(GradientColors);
#endif
        }
示例#4
0
        public WorldData(DefData defData)
        {
            _defData = defData;

            PrepareLanding.Instance.EventHandler.WorldGeneratedOrLoaded += ExecuteOnWorldGeneratedOrLoaded;

            // note: each of the xxxData below will take care of reloading its data on a new world. No need to do it here.
#if TEMPERATURE_DATA || WORLD_DATA
            TemperatureData = new TemperatureData(_defData);
            WorldCharacteristics.Add(TemperatureData);
#endif

#if RAINFALL_DATA || WORLD_DATA
            RainfallData = new RainfallData(_defData);
            WorldCharacteristics.Add(RainfallData);
#endif

#if ELEVATION_DATA || WORLD_DATA
            ElevationData = new ElevationData(_defData);
            WorldCharacteristics.Add(ElevationData);
#endif
        }
示例#5
0
 public ElevationData(DefData defData) : base(defData)
 {
 }
 public TemperatureData(DefData defData) : base(defData)
 {
 }
示例#7
0
 public RainfallData(DefData defData) : base(defData)
 {
 }