clamp<T extends num> static method
T
clamp<T extends num>(
- T value,
- T min,
- T max
Implementation
static T clamp<T extends num>(T value, T min, T max) {
return math.max(min, math.min(max, value));
}