mirror of
https://github.com/kepler155c/opus
synced 2025-12-19 14:48:07 +00:00
network sniffer
This commit is contained in:
@@ -119,14 +119,8 @@ function Util.signum(num)
|
||||
end
|
||||
end
|
||||
|
||||
function Util.clamp(lo, num, hi)
|
||||
if num <= lo then
|
||||
return lo
|
||||
elseif num >= hi then
|
||||
return hi
|
||||
else
|
||||
return num
|
||||
end
|
||||
function Util.clamp(num, low, high)
|
||||
return num < low and low or num > high and high or num
|
||||
end
|
||||
|
||||
-- http://lua-users.org/wiki/SimpleRound
|
||||
|
||||
Reference in New Issue
Block a user