Jump to content

Esto tiene Algun Error ???


Atouk

Recommended Posts

Hola tengo un problema que me da un error:

WARNING: Loading script failed: ')' expected near':'

Script:

function math.round(number, decimals, method) 
  decimals = decimals  or 0 
  local factor = 10 ^ decimals 
  if method == "ceil" or method == "floor" then 
    return math[method](number * factor) / factor 
  else 
    return tonumber("%." .. decimals .. "f":format(number)) 
  end 
end 

Link to comment
function math.round(number, decimals, method) 
    decimals = decimals or 0 
    local factor = 10 ^ decimals 
    if (method == "ceil" or method == "floor") then return math[method](number * factor) / factor 
    else return tonumber(("%."..decimals.."f"):format(number)) end 
end 

Link to comment
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...