1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-06-27 16:36:03 +00:00

Cleanup: drop Server::hudGetHotbarItemcount()

Call directly accessible RemotePlayer::getHotbarItemcount() from server api
This commit is contained in:
Loic Blot 2018-03-08 22:03:45 +01:00 committed by Loïc Blot
parent f35236afea
commit 373f1bfb4a
3 changed files with 2 additions and 10 deletions

View file

@ -1462,9 +1462,7 @@ int ObjectRef::l_hud_get_hotbar_itemcount(lua_State *L)
if (player == NULL)
return 0;
s32 hotbar_itemcount = getServer(L)->hudGetHotbarItemcount(player);
lua_pushnumber(L, hotbar_itemcount);
lua_pushnumber(L, player->getHotbarItemcount());
return 1;
}