Open TangentFoxy opened 8 years ago
function lume.uuid() local fn = function(x) local r = math_random(16) - 1 r = (x == "x") and (r + 1) or (r % 4) + 9 return ("0123456789abcdef"):sub(r, r) end return (("xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx"):gsub("[xy]", fn)) end
from lume
from lume