-
Notifications
You must be signed in to change notification settings - Fork 0
RangeVariable
Implements: ScriptableObject > SavableVariable > SharedVariable, ISerializationCallbackReceiver
Base abstract generic class for a range variable. Adds range limit utils
- type param: <T> Type of value for the range variable
Lowest possible value
Largest possible value
Inverts the percentage value of the range. MaxValue becomes 0% of the range
Value used to calculate percentage of range.
- Used to access RuntimeValue for percent calculations
Where the Runtime value is between the min and max values of the range.
- MinValue is 0% (0.0f) and Max Value is 100% (1.0f)
- If Descending is true MinValue is 100% and MaxValue is 0%
SharedVariable Properties
The default value for the variable
Run time value for the variable
SavableVariable Properties
Set to true if data has been loaded
Ensures that the float value is within the min and max of the range.
ISerializationCallbackReceiver Methods
Applies the default value to the run time value after deserialization.
- This should happen after changing the default values in the inspector. It will also apply the default value when the game starts.
- Required for ISerializationCallbackReceiver
Does nothing
- Required for ISerializationCallbackReceiver
SavableVariable Methods
Clear the saved data
Converts runtime data to a string to be saved
- Returns: String of runtime data
Parses string of data into runtime data
- Param: data - Data to be loaded
Home | SharedVariableSaveSystem
Extensions | ColorPalletSystem | InventoryItemsSystem | SoundProfileCaptions