mathf.clamp*(valyex 0, 3000) code example Example: how to clamp a value let d=max-min; let c=((value-min)%d)+min;