fix: fix numberToString
This commit is contained in:
parent
8c871d3444
commit
d64868d54c
1 changed files with 1 additions and 2 deletions
|
@ -112,8 +112,7 @@ function Math.numberToString(x, length)
|
||||||
local length = length or 1
|
local length = length or 1
|
||||||
local string = ""
|
local string = ""
|
||||||
local x = x
|
local x = x
|
||||||
if (x >= math.pow(10, length)) then
|
if (x < math.pow(10, length)) then
|
||||||
x = length*10 - 1
|
|
||||||
string = string .. x
|
string = string .. x
|
||||||
else
|
else
|
||||||
for i=1, (length-1) do
|
for i=1, (length-1) do
|
||||||
|
|
Loading…
Reference in a new issue