mirror of
https://github.com/luanti-org/luanti.git
synced 2025-07-02 16:38:41 +00:00
Allow texture modifiers in hotbar textures. (#9271)
This commit is contained in:
parent
8ddb6718e3
commit
244121b964
2 changed files with 2 additions and 20 deletions
|
@ -1224,21 +1224,9 @@ void Client::handleCommand_HudSetParam(NetworkPacket* pkt)
|
|||
player->hud_hotbar_itemcount = hotbar_itemcount;
|
||||
}
|
||||
else if (param == HUD_PARAM_HOTBAR_IMAGE) {
|
||||
// If value not empty verify image exists in texture source
|
||||
if (!value.empty() && !getTextureSource()->isKnownSourceImage(value)) {
|
||||
errorstream << "Server sent wrong Hud hotbar image (sent value: '"
|
||||
<< value << "')" << std::endl;
|
||||
return;
|
||||
}
|
||||
player->hotbar_image = value;
|
||||
}
|
||||
else if (param == HUD_PARAM_HOTBAR_SELECTED_IMAGE) {
|
||||
// If value not empty verify image exists in texture source
|
||||
if (!value.empty() && !getTextureSource()->isKnownSourceImage(value)) {
|
||||
errorstream << "Server sent wrong Hud hotbar selected image (sent value: '"
|
||||
<< value << "')" << std::endl;
|
||||
return;
|
||||
}
|
||||
player->hotbar_selected_image = value;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue