PerSaveOptions - Ellpeck/TinyLifeExampleMod Wiki

Tiny Life

TinyLife

PerSaveOptions Class

The game's per-save options, which are displayed in the TinyLife.Uis.OptionsMenu.Initialize(MLEM.Ui.UiSystem,System.Boolean,System.Boolean) menu and saved to disk.
Note that Instance is null if there is no Map loaded.

public class PerSaveOptions : MLEM.Misc.GenericDataHolder

Inheritance System.Object 🡒 MLEM.Misc.GenericDataHolder 🡒 PerSaveOptions

Fields

PerSaveOptions.AiImportantActions Field

Whether the AI should be able to execute important options, like paying the bills.
This option is intended to be used through CanDoImportantAction(ActionInfo, bool).

public bool AiImportantActions;

Field Value

System.Boolean

PerSaveOptions.AiSkillBuilding Field

Whether the AI should be able to execute skill building actions like painting and programming.
This option is intended to be used through GetSkillPriorityMod(Person, SkillType).

public bool AiSkillBuilding;

Field Value

System.Boolean

PerSaveOptions.DisableAiHousehold Field

Whether the AI of everyone in the CurrentHousehold should be disabled or not

public bool DisableAiHousehold;

Field Value

System.Boolean

PerSaveOptions.DisableAiSelected Field

Whether the AI of the SelectedPerson should be disabled or not

public bool DisableAiSelected;

Field Value

System.Boolean

Properties

PerSaveOptions.Instance Property

The static singleton instance of PerSaveOptions.
Note that this value is null if there is no Map loaded.

public static TinyLife.PerSaveOptions Instance { get; set; }

Property Value

PerSaveOptions

Methods

PerSaveOptions.Load(string) Method

Loads the options from the default options file path for the given save

public static TinyLife.PerSaveOptions Load(string save);

Parameters

save System.String

Returns

PerSaveOptions

PerSaveOptions.Save(string) Method

Saves the options to the default options file path for the given save

public void Save(string save);

Parameters

save System.String