Пример #1
0
        public override void ExposeData()
        {
            base.ExposeData();
            Scribe_Collections.Look(ref this.autoMachineToolSetting, "autoMachineToolSetting");
            Scribe_Collections.Look(ref this.planterSetting, "planterSetting");
            Scribe_Collections.Look(ref this.harvesterSetting, "harvesterSetting");

            Scribe_Deep.Look(ref this.beltConveyorSetting, "beltConveyorSetting");
            Scribe_Deep.Look(ref this.pullerSetting, "pullerSetting");
            Scribe_Deep.Look(ref this.gathererSetting, "gathererSetting");
            Scribe_Deep.Look(ref this.slaughterSetting, "slaughterSetting");
            Scribe_Deep.Look(ref this.minerSetting, "minerSetting");
            Scribe_Deep.Look(ref this.cleanerSetting, "cleanerSetting");
            Scribe_Deep.Look(ref this.repairerSetting, "repairerSetting");
            Scribe_Deep.Look(ref this.stunnerSetting, "stunnerSetting");
            Scribe_Deep.Look(ref this.shieldSetting, "shieldSetting");

            this.autoMachineToolSetting = this.autoMachineToolSetting ?? CreateAutoMachineToolDefault();
            this.planterSetting         = this.planterSetting ?? CreatePlanterDefault();
            this.harvesterSetting       = this.harvesterSetting ?? CreateHarvesterDefault();

            this.beltConveyorSetting = this.beltConveyorSetting ?? BeltConveyorDefault();
            this.pullerSetting       = this.pullerSetting ?? PullerDefault();
            this.gathererSetting     = this.gathererSetting ?? GathererDefault();
            this.slaughterSetting    = this.slaughterSetting ?? SlaughterDefault();
            this.minerSetting        = this.minerSetting ?? MinerDefault();
            this.cleanerSetting      = this.cleanerSetting ?? CleanerDefault();
            this.repairerSetting     = this.repairerSetting ?? RepairerDefault();
            this.stunnerSetting      = this.stunnerSetting ?? StunnerDefault();
            this.shieldSetting       = this.shieldSetting ?? ShieldDefault();

            Option(this.DataExposed).ForEach(e => e(this, new EventArgs()));
        }
Пример #2
0
        public void RestoreDefault()
        {
            this.autoMachineToolSetting = CreateAutoMachineToolDefault();
            this.planterSetting         = CreatePlanterDefault();
            this.harvesterSetting       = CreateHarvesterDefault();

            this.beltConveyorSetting = BeltConveyorDefault();
            this.pullerSetting       = PullerDefault();
            this.gathererSetting     = GathererDefault();
            this.slaughterSetting    = SlaughterDefault();
            this.minerSetting        = MinerDefault();
            this.cleanerSetting      = CleanerDefault();
            this.repairerSetting     = RepairerDefault();
            this.stunnerSetting      = StunnerDefault();
            this.shieldSetting       = ShieldDefault();
        }