mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2026-02-17 19:11:30 +00:00
Merge branch 'lua-server-variables' into 'next'
Expose "server" and "dedicated" to Lua scripts See merge request STJr/SRB2!1022
This commit is contained in:
commit
71f5b7fd0d
1 changed files with 6 additions and 0 deletions
|
|
@ -326,6 +326,12 @@ int LUA_PushGlobals(lua_State *L, const char *word)
|
|||
return 0;
|
||||
LUA_PushUserdata(L, &players[secondarydisplayplayer], META_PLAYER);
|
||||
return 1;
|
||||
} else if (fastcmp(word,"isserver")) {
|
||||
lua_pushboolean(L, server);
|
||||
return 1;
|
||||
} else if (fastcmp(word,"isdedicatedserver")) {
|
||||
lua_pushboolean(L, dedicated);
|
||||
return 1;
|
||||
// end local player variables
|
||||
} else if (fastcmp(word,"server")) {
|
||||
if ((!multiplayer || !netgame) && !playeringame[serverplayer])
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue