Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions src/scriptInterface.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@ static int random(lua_State* L)
return 1;
}
/// random(min_value, max_value)
/// Generate a random floating point number between the min and max value. Includes min and max as possible values.
/// Generate a random floating point number uniformly distributed on the interval [min_value, max_value]. Meaning min_value and max_value included.
/// For further information see: https://en.cppreference.com/w/cpp/numeric/random/uniform_real_distribution.
/// (Floating point numbers are factional numbers, so 1.5, 2.333333, 3.141)
REGISTER_SCRIPT_FUNCTION(random);

Expand All @@ -26,7 +27,7 @@ static int irandom(lua_State* L)
return 1;
}
/// irandom(min_value, max_value)
/// Generate a random integer number between the min and max value. Includes min and max as possible values.
/// Generate a random integer number uniformly distributed on the interval [min_value, max_value]. Meaning min_value and max_value included.
/// (Integer numbers are whole numbers, so 1, 2, 3, 5, 1400)
REGISTER_SCRIPT_FUNCTION(irandom);

Expand Down