--- nNum 源数字
--- n 小数位数
function Tool. GetPreciseDecimal(nNum, n)
if type(nNum) ~= "number" then
return nNum;
end
n = n or 0;
n = math.floor(n)
if n < 0 then
n = 0;
end
local nDecimal = 10 ^ n
local nTemp = math.floor(nNum * nDecimal);
local nRet = nTemp / nDecimal;
return nRet;
end
function Mathf.CutTail(value,multiple,cut)
local n = math.pow(10,multiple)
if not cut then
return math.floor(value * n + 0.5)/n
else
return math.floor(value * n)/n
end
end