unity-atoms/Packages/Core/Runtime/Variables
Adam Ramberg 9b027e2308
Added pre change transformers to Variables + Clamp Int / Float (#93)
* Added pre change transformers to Variable + Clamp Value Function (first pre change transformer implementation)
- Added a list of pre change transformers to AtomVariable
- Added docs
- Added two AtomFunctions - ClampInt and ClampFloat
- Added custom editors for ClampInt and ClampFloat
- AtomFunction<T, T> is not part of the generator
- Regenerated all the Atoms

* - Created a base class for the editor for ClampFloat and ClampInt. Apparently it is not allowed to have multiple CustomEditor attributes defined for the same class. To implement this I also created an interface called `IIsValid` (for casting purposes in the editor).
- Initialize `PreChangeTransformers ` at declaration and removed initialization `OnEnable`
- Moved call to `RunPreChangeTransformers ` from `OnEnable` to `OnValidate`. Running it 2 times, once for initialValue and once for value since value can be changed at runtime via editor.
- Made the variable PreChangeTransformers private and created a property instead in order to make it impossible to overwrite the list with `null` from the outside.
- Moved `ClampInt` and `ClampFloat` in the `CreateAssetMenu` for `Unity Atoms/Functions/Transformers`
2020-02-16 12:44:46 +01:00
..
AtomBaseVariable.cs Remove all FormerlySerializedAs attributes 2019-10-18 17:36:10 +02:00
AtomBaseVariable.cs.meta Update the last missing atoms with new icon system 2019-10-02 17:49:38 +02:00
AtomVariable.cs Added pre change transformers to Variables + Clamp Int / Float (#93) 2020-02-16 12:44:46 +01:00
AtomVariable.cs.meta Update the last missing atoms with new icon system 2019-10-02 17:49:38 +02:00
BoolVariable.cs Added pre change transformers to Variables + Clamp Int / Float (#93) 2020-02-16 12:44:46 +01:00
BoolVariable.cs.meta Regenerate core atoms with new icon system 2019-10-02 17:36:20 +02:00
Collider2DVariable.cs Added pre change transformers to Variables + Clamp Int / Float (#93) 2020-02-16 12:44:46 +01:00
Collider2DVariable.cs.meta Regenerate core atoms with new icon system 2019-10-02 17:36:20 +02:00
ColliderVariable.cs Added pre change transformers to Variables + Clamp Int / Float (#93) 2020-02-16 12:44:46 +01:00
ColliderVariable.cs.meta Regenerate core atoms with new icon system 2019-10-02 17:36:20 +02:00
ColorVariable.cs Added pre change transformers to Variables + Clamp Int / Float (#93) 2020-02-16 12:44:46 +01:00
ColorVariable.cs.meta Regenerate core atoms with new icon system 2019-10-02 17:36:20 +02:00
EquatableAtomVariable.cs Added pre change transformers to Variables + Clamp Int / Float (#93) 2020-02-16 12:44:46 +01:00
EquatableAtomVariable.cs.meta New repo structure 2019-10-01 17:27:22 +02:00
FloatVariable.cs Added pre change transformers to Variables + Clamp Int / Float (#93) 2020-02-16 12:44:46 +01:00
FloatVariable.cs.meta Regenerate core atoms with new icon system 2019-10-02 17:36:20 +02:00
GameObjectVariable.cs Added pre change transformers to Variables + Clamp Int / Float (#93) 2020-02-16 12:44:46 +01:00
GameObjectVariable.cs.meta Regenerate core atoms with new icon system 2019-10-02 17:36:20 +02:00
IntVariable.cs Added pre change transformers to Variables + Clamp Int / Float (#93) 2020-02-16 12:44:46 +01:00
IntVariable.cs.meta Regenerate core atoms with new icon system 2019-10-02 17:36:20 +02:00
IWithApplyChange.cs Added pre change transformers to Variables + Clamp Int / Float (#93) 2020-02-16 12:44:46 +01:00
IWithApplyChange.cs.meta New repo structure 2019-10-01 17:27:22 +02:00
StringVariable.cs Added pre change transformers to Variables + Clamp Int / Float (#93) 2020-02-16 12:44:46 +01:00
StringVariable.cs.meta Regenerate core atoms with new icon system 2019-10-02 17:36:20 +02:00
Vector2Variable.cs Added pre change transformers to Variables + Clamp Int / Float (#93) 2020-02-16 12:44:46 +01:00
Vector2Variable.cs.meta Regenerate core atoms with new icon system 2019-10-02 17:36:20 +02:00
Vector3Variable.cs Added pre change transformers to Variables + Clamp Int / Float (#93) 2020-02-16 12:44:46 +01:00
Vector3Variable.cs.meta Regenerate core atoms with new icon system 2019-10-02 17:36:20 +02:00