mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2024-11-15 01:01:33 +00:00
Update src/lua_baselib.c
No need of counting bots.
This commit is contained in:
parent
de4a8a193b
commit
2865873e70
1 changed files with 2 additions and 4 deletions
|
@ -3544,7 +3544,7 @@ static int lib_gAddGametype(lua_State *L)
|
||||||
// Partly lifted from Got_AddPlayer
|
// Partly lifted from Got_AddPlayer
|
||||||
static int lib_gAddPlayer(lua_State *L)
|
static int lib_gAddPlayer(lua_State *L)
|
||||||
{
|
{
|
||||||
INT16 i, newplayernum, botcount = 1;
|
INT16 i, newplayernum;
|
||||||
player_t *newplayer;
|
player_t *newplayer;
|
||||||
SINT8 skinnum = 0, bot;
|
SINT8 skinnum = 0, bot;
|
||||||
|
|
||||||
|
@ -3552,10 +3552,8 @@ static int lib_gAddPlayer(lua_State *L)
|
||||||
{
|
{
|
||||||
if (!playeringame[i])
|
if (!playeringame[i])
|
||||||
break;
|
break;
|
||||||
|
|
||||||
if (players[i].bot)
|
|
||||||
botcount++; // How many of us are there already?
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (i >= MAXPLAYERS)
|
if (i >= MAXPLAYERS)
|
||||||
{
|
{
|
||||||
lua_pushnil(L);
|
lua_pushnil(L);
|
||||||
|
|
Loading…
Reference in a new issue