retrieve more client info on minetest 5.X or 5.2 for minetest5
* take from https://forum.minetest.net/viewtopic.php?p=354631#p354631 * usefull for give more info for idetification of clients cheaters
This commit is contained in:
parent
f65bba2e5c
commit
822ab80f30
@ -4073,14 +4073,13 @@ Utilities
|
|||||||
connection_uptime = 200, -- seconds since client connected
|
connection_uptime = 200, -- seconds since client connected
|
||||||
protocol_version = 32, -- protocol version used by client
|
protocol_version = 32, -- protocol version used by client
|
||||||
formspec_version = 2, -- supported formspec version
|
formspec_version = 2, -- supported formspec version
|
||||||
-- following information is available on debug build only!!!
|
-- following information is available on minenux only build. dont assume in mods
|
||||||
-- DO NOT USE IN MODS
|
serialization_version = 26, -- serialization version used by client
|
||||||
--ser_vers = 26, -- serialization version used by client
|
major = 5, -- major version number
|
||||||
--major = 0, -- major version number
|
minor = 2, -- minor version number
|
||||||
--minor = 4, -- minor version number
|
patch = 1, -- patch version number
|
||||||
--patch = 10, -- patch version number
|
vers_string = "5.2.1", -- full version string
|
||||||
--vers_string = "0.4.9-git", -- full version string
|
state = "Active" -- current client state
|
||||||
--state = "Active" -- current client state
|
|
||||||
}
|
}
|
||||||
|
|
||||||
* `minetest.mkdir(path)`: returns success.
|
* `minetest.mkdir(path)`: returns success.
|
||||||
|
@ -237,7 +237,6 @@ int ModApiServer::l_get_player_information(lua_State *L)
|
|||||||
lua_pushnumber(L, player->formspec_version);
|
lua_pushnumber(L, player->formspec_version);
|
||||||
lua_settable(L, table);
|
lua_settable(L, table);
|
||||||
|
|
||||||
#ifndef NDEBUG
|
|
||||||
lua_pushstring(L,"serialization_version");
|
lua_pushstring(L,"serialization_version");
|
||||||
lua_pushnumber(L, ser_vers);
|
lua_pushnumber(L, ser_vers);
|
||||||
lua_settable(L, table);
|
lua_settable(L, table);
|
||||||
@ -261,7 +260,6 @@ int ModApiServer::l_get_player_information(lua_State *L)
|
|||||||
lua_pushstring(L,"state");
|
lua_pushstring(L,"state");
|
||||||
lua_pushstring(L,ClientInterface::state2Name(state).c_str());
|
lua_pushstring(L,ClientInterface::state2Name(state).c_str());
|
||||||
lua_settable(L, table);
|
lua_settable(L, table);
|
||||||
#endif
|
|
||||||
|
|
||||||
#undef ERET
|
#undef ERET
|
||||||
return 1;
|
return 1;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user