bad argument #2 to 'random' (interval is empty)
I don't know what that means, can someone tell me what it means?
bad argument #2 to 'random' (interval is empty)
I don't know what that means, can someone tell me what it means?
GoldenPhysics's answer:
You have a math.random statement and the second number is less than the first.
That is, something like
math.random( 5 , 0 )
When explicit numbers aren't typed, it will frequently be from code that looks like this:
math.random( 1, #tab )
Which will cause a problem if tab is empty (since 1 > 0).
This discussion is preserved as it was. New answers, comments, and votes are closed.
2 comments
You have a math.random statement and the second number is less than the first.
Thanks!