menu
Roblox Forum Archive
Home
User Search
Forums
Donate
search
settings
Home
User Search
Forums
Donate
launch
Go to User Dashboard
Forums
Scripters
Choose randomely from table?
chevron_left
chevron_left
chevron_left
of
1
chevron_right
chevron_right
chevron_right
Choose randomely from table?
Cshef
Join Date: 2010-04-11
Post Count: 7539
#184802338
Saturday, March 05, 2016 6:22 PM GMT
How would you choose something random from a table?
Go to point in time
arrow_right
10 minutes before
5 minutes before
At time of posting
5 minutes after
10 minutes after
more_horiz
LegendaryAccount
Join Date: 2010-06-02
Post Count: 13193
#184802556
Saturday, March 05, 2016 6:25 PM GMT
Table = {1,3,5,7,8} RandomElement = Table[math.random(#Table)]
Go to point in time
arrow_right
10 minutes before
5 minutes before
At time of posting
5 minutes after
10 minutes after
more_horiz
darthpyro
Join Date: 2009-08-18
Post Count: 3569
#184802609
Saturday, March 05, 2016 6:25 PM GMT
yourTable = {...} randomElement = yourTable[math.random(1, #yourTable)]
Go to point in time
arrow_right
10 minutes before
5 minutes before
At time of posting
5 minutes after
10 minutes after
more_horiz
chevron_left
chevron_left
chevron_left
of
1
chevron_right
chevron_right
chevron_right