ENIGMA Development Environment
Home
About
Download
Wiki
Forums
EDC
Games
Tracker
Progress
Guest |
login
|
register
Commit to
enigma-dev
by
time-killer-games
: "
Add focus wait to Zenity/KDialog (#2198)"
(at 2021-03-28 22:54:56;
Click here to view
.)
ENIGMA Forums
>
Outsourcing saves money
>
Programming Help
>
Random number questions
Pages:
1
« previous
next »
Print
Author
Topic: Random number questions (Read 2639 times)
Darkstar2
Posted on:
May 11, 2014, 08:06:00 pm
Joined: Jan 2014
Posts: 1238
My question regards random numbers in ENIGMA. Back in the days I was reading the GMC I remember many complaints from people that numbers were not truly random and had a tendency of repeating in patterns. It was mentioned by YYG that this was by design to allow easy tracing and debugging and was suggested to people that they use randomize ();
Since ENIGMA is based off of C++, does it work the same ? Do I have to use random seed or just randomize for truly random sequences ?
Also does the randomize() also affect all random functions such as random range ?
Thanks.
Logged
Goombert
Reply #1 Posted on:
May 11, 2014, 10:35:40 pm
Location: Cappuccino, CA
Joined: Jan 2013
Posts: 2993
Yes I believe we wrap the actual c standard functions, that said, there is no such thing as a truly random number, which is up for philosophical debate.
Logged
I think it was Leonardo da Vinci who once said something along the lines of "If you build the robots, they will make games." or something to that effect.
TheExDeus
Reply #2 Posted on:
May 12, 2014, 04:44:31 am
Joined: Apr 2008
Posts: 1860
We actually use several implementations as far as I know. One is something from delphi which could work just like GM. But they are as random as they come. There shouldn't be any repeating patterns. We could use the C++11 random functions which would even use hardware if possible (like some intel CPU's have a instruction that returns random value based on some quantum effects).
Logged
Pages:
1
Print
« previous
next »
0