You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Generate new FloatVariable or IntVariable over
right click -> Create -> Variables -> Float/Int
and then it is not possible to set a other Float/IntVariable as Min/Max Clamped Value, just numbers.
I was re-implementing this feature, unfortunately it's not possible with the current codebase.
When the screenshot in the wiki was taken, clamped variables were completely separate classes. When it was merged into the current class structure, the reference type was dropped - at the time probably by accident. The problem is that in order to serialize the clamped values as a reference, they have to be passed as a generic argument. The reference, in turn, needs to know what type of variable it has to serialize. This creates a cyclic serialization, which prevents me from re-implementing the feature.
I'm keeping this open as it would be possible if we were to switch to a custom serialization scheme #100 , that doesn't rely on Unity's restriction. In this particular case, being able to serialize generics should solve it, as we only need to pass the base type (float instead of FloatUnityEvent, FloatReference, etc.) as a generic argument.
Generate new FloatVariable or IntVariable over
right click -> Create -> Variables -> Float/Int
and then it is not possible to set a other Float/IntVariable as Min/Max Clamped Value, just numbers.
System:
Windows 10 64 bit, 16 GB RAM, SSD,
Unity 2020.1.0a17, 2D project template
The text was updated successfully, but these errors were encountered: