Fix some comments for random generator

This commit is contained in:
2022-03-31 17:16:17 -04:00
parent b791cdc606
commit 89365ea9ba

View File

@@ -426,15 +426,16 @@ LuaDefine(math_random, "(args...)",
return 1;
}
LuaDefine(math_randomstate, "(seed)",
LuaDefine(math_randomstate, "seed",
"|Create and return a randomstate table."
"|This is a lua table that stores the state for a random"
"|number generator. A randomstate table can be passed"
"|to math.random."
"|"
"|You can optionally omit the seed, in which case it will"
"|pick a seed randomly. Automatically-generated seeds are"
"|guaranteed never to be the same as user-specified seeds.") {
"|You can optionally omit the seed, in which case a"
"|seed will be chosen randomly. Automatically-generated"
"|seeds are guaranteed never to be the same as"
"|user-specified seeds.") {
double seed;
if (lua_gettop(L) == 0) {
World *w = World::fetch_global_pointer(L);