Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How do I make this work?

Asked by 9 years ago
function Begin()
local num = random.math(2)
print(num)
end

1 answer

Log in to vote
2
Answered by
Tigerism 220 Moderation Voter
9 years ago

First, it's math.random(2). Second, you need to call the function Begin().

Code:

function Begin()
local num = math.random(2)
print(num)
end

Begin()
1
OK thanks. CoolMalopus 50 — 9y
1
He also forgot to tab his code. :) TheeDeathCaster 2368 — 9y
Ad

Answer this question