Call directly accessible RemotePlayer::getHotbarSelectedImage() from server api
if (player == NULL)
return 0;
- const std::string &name = getServer(L)->hudGetHotbarSelectedImage(player);
+ const std::string &name = player->getHotbarSelectedImage();
lua_pushlstring(L, name.c_str(), name.size());
return 1;
}
SendHUDSetParam(player->getPeerId(), HUD_PARAM_HOTBAR_SELECTED_IMAGE, name);
}
-const std::string& Server::hudGetHotbarSelectedImage(RemotePlayer *player) const
-{
- return player->getHotbarSelectedImage();
-}
-
Address Server::getPeerAddress(session_t peer_id)
{
return m_con->GetPeerAddress(peer_id);
bool hudSetHotbarItemcount(RemotePlayer *player, s32 hotbar_itemcount);
void hudSetHotbarImage(RemotePlayer *player, std::string name);
void hudSetHotbarSelectedImage(RemotePlayer *player, std::string name);
- const std::string &hudGetHotbarSelectedImage(RemotePlayer *player) const;
Address getPeerAddress(session_t peer_id);