randomSeed | |||||||
Type | property | ||||||
Dictionary | LCS | ||||||
Library | LiveCode Script | ||||||
Syntax |
| ||||||
Summary | |||||||
Introduced | 1.0 | ||||||
OS | mac, windows, linux, ios, android | ||||||
Platforms | desktop, server, mobile | ||||||
Example |
| ||||||
Values |
| ||||||
Related | Keyword: any, integer Command: call Function: random, value Glossary: property, keyword, application, value, call | ||||||
Description | Use the randomSeed property to ensure greater randomness when generating random numbers. Changing the randomSeed property changes the pseudorandom numbers generated by the random function and used by the any keyword. Using the same seed creates the same sequence of pseudorandom values. For example, if you call the random function five times to generate a list of five numbers, then change the randomSeed to another value, the next five calls to the random function will produce a different list of five numbers. However, if you set the randomSeed back to its original value and call the random function five more times, the list of five numbers is the same as the first list you generated. LiveCode uses a new randomSeed every time the application is started up. | ||||||
Tags | math |