RepairableObjectComparisonCondition
A class in Root.Township, Features.Gameplay.GameConditions.
IGameCondition met when each listed modifiable static object is in its required built or not-built state, read from ModifiableStaticManager. Not met until its save data has loaded.
Constructors
| Member | What it is |
|---|
RepairableObjectComparisonCondition() | Unity makes components itself; use AddComponent or spawn a prefab instead of new. |
Fields
2 private and internal fields
| Member | What it is |
|---|
private bool isLoaded | Set once save data has loaded. |
private List<RepairableObject> repairableObjects | Object hashes with their required state. Loading appends the saved entries to this list rather than replacing it. |
Properties
| Member | What it is |
|---|
Action OnConditionChanged { get; set; } | Change callback, run on any static object change and after loading. |
Methods
| Member | What it is |
|---|
bool IsConditionMet() | False before load; otherwise true only if every object's modified state matches its requirement. |
3 private and internal methods