Explicit casting is required at the beginning of the valueChanged() function. **T change = widget.statValue.number - _lastStatValue as T;**
Explicit casting is required at the beginning of the valueChanged() function.
T change = widget.statValue.number - _lastStatValue as T;