fix: missing Random:seed method

This commit is contained in:
MihailRis
2025-09-26 00:25:00 +03:00
parent 1f3b7f828d
commit 1350910d28
3 changed files with 21 additions and 6 deletions
+2 -2
View File
@@ -22,7 +22,7 @@ static int l_random(lua::State* L) {
}
}
static int l_generate(lua::State* L) {
static int l_bytes(lua::State* L) {
size_t size = lua::tointeger(L, 1);
auto randomEngine = util::seeded_random_engine(random_device);
@@ -40,7 +40,7 @@ static int l_uuid(lua::State* L) {
const luaL_Reg randomlib[] = {
{"random", lua::wrap<l_random>},
{"bytes", lua::wrap<l_generate>},
{"bytes", lua::wrap<l_bytes>},
{"uuid", lua::wrap<l_uuid>},
{NULL, NULL}
};