generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripting Helpers
Home Search
 

Re: Is there a pattern here

Previous Thread :: Next Thread 
128GB is not online. 128GB
Joined: 17 Apr 2014
Total Posts: 8056
11 Oct 2014 08:03 PM
6, 5, 2, 1, 3, 4

3, 1, 6, 5, 2, 4

1, 4, 2, 3, 5, 6

3, 4, 2, 6, 5, 1

2, 1, 5, 3, 6, 4


5 results from my round randomizing, something seems off about it.
Report Abuse
Haggie125 is not online. Haggie125
Joined: 02 Apr 2008
Total Posts: 761
11 Oct 2014 08:05 PM
Looks pretty random to me
Report Abuse
maxomega3 is not online. maxomega3
Joined: 11 Jun 2010
Total Posts: 10668
11 Oct 2014 08:05 PM
you never get the same number twice in one set.
Report Abuse
maxomega3 is not online. maxomega3
Joined: 11 Jun 2010
Total Posts: 10668
11 Oct 2014 08:06 PM
you never get the same number twice in one set.
I guess it's good for a Sudoku puzzle generator
Report Abuse
Skemata is not online. Skemata
Joined: 10 Oct 2014
Total Posts: 4
11 Oct 2014 08:06 PM
If it makes you feel any better, all 6 rows of numbers contain the same digits.

I am a genius, huh?
Report Abuse
maxomega3 is not online. maxomega3
Joined: 11 Jun 2010
Total Posts: 10668
11 Oct 2014 08:06 PM
Dang, I even checked for a double post.
Curse you, old pages!!
Report Abuse
128GB is not online. 128GB
Joined: 17 Apr 2014
Total Posts: 8056
11 Oct 2014 08:06 PM
@Max
Its supposed to do that, sorry I should have mentioned it

I wish I had done it a sixth time
The fours seem to be in the same place twice in a row before changing
Report Abuse
maxomega3 is not online. maxomega3
Joined: 11 Jun 2010
Total Posts: 10668
11 Oct 2014 08:07 PM
I noticed something with the 3's

3----
-3---
3----
-3---
Report Abuse
128GB is not online. 128GB
Joined: 17 Apr 2014
Total Posts: 8056
11 Oct 2014 08:16 PM
2, 4, 5, 1, 6, 3

2, 6, 4, 5, 1, 3

4, 1, 5, 6, 2, 3

5, 6, 1, 2, 3, 4

2, 1, 4, 6, 3, 5

1, 2, 5, 6, 4, 3

6, 2, 5, 3, 4, 1

5, 2, 3, 6, 4, 1


This is the method I'm using for making them random

local tab = {"1", "2", "3", "4", "5", "6"}
function random()
for x = 1, #tab, 1 do
local n = math.random(x)
tab[x], tab[n] = tab[n], tab[x]
end
end

for _ = 0, 9, 1 do
random()
print(table.concat(tab, ", "))
end
Report Abuse
AgentFirefox is not online. AgentFirefox
Top 100 Poster
Joined: 20 Jun 2008
Total Posts: 22404
11 Oct 2014 08:21 PM
There will always be a pattern.
Because you're using RNG.


Just FYI.
Report Abuse
128GB is not online. 128GB
Joined: 17 Apr 2014
Total Posts: 8056
11 Oct 2014 08:24 PM
What do you suggest doing?
I've already seeded math.randomseed with tick()
Should I just not worry about it?
If I have more than 10 rounds I doubt anyone would notice or care
Report Abuse
AgentFirefox is not online. AgentFirefox
Top 100 Poster
Joined: 20 Jun 2008
Total Posts: 22404
11 Oct 2014 08:26 PM
Don't worry about it.

Lua's RNG is a C-based call, and C uses a formula that generates numbers in a way that over a long period of time, all numbers will be selected the same number of times.

Law of large numbers FTW.
Report Abuse
128GB is not online. 128GB
Joined: 17 Apr 2014
Total Posts: 8056
11 Oct 2014 08:28 PM
Okay, thank you
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image