Fix #295 handle invalid values in set_count

This commit is contained in:
Misode
2022-10-20 05:22:38 +02:00
parent 5fe7121ea9
commit f6b6a6bf7d
3 changed files with 8 additions and 6 deletions

View File

@@ -183,7 +183,7 @@ export function square(a: number) {
}
export function clamp(a: number, b: number, c: number) {
return Math.max(a, Math.min(b, c))
return Math.max(b, Math.min(a, c))
}
export function clampedLerp(a: number, b: number, c: number): number {