better random bleeding

This commit is contained in:
ZioPao
2023-11-16 20:15:07 +01:00
parent 1b248d744e
commit 03093f77a7
2 changed files with 21 additions and 1 deletions

View File

@@ -1,5 +1,15 @@
local CommonMethods = {}
---comment
---@param val number
---@param min number
---@param max number
function CommonMethods.Normalize(val, min, max)
if (max - min) == 0 then return 1 end
return (val - min)/(max-min)
end
---Returns the side for a certain limb or prosthesis
---@param name string
---@return string "L" or "R"