aboutsummaryrefslogtreecommitdiff
path: root/src/hud.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/hud.cpp')
-rw-r--r--src/hud.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/hud.cpp b/src/hud.cpp
index 65c78ca50..a3ae38bcb 100644
--- a/src/hud.cpp
+++ b/src/hud.cpp
@@ -43,7 +43,6 @@ Hud::Hud(video::IVideoDriver *driver, gui::IGUIEnvironment* guienv,
screensize = v2u32(0, 0);
displaycenter = v2s32(0, 0);
hotbar_imagesize = 48;
- hotbar_itemcount = 8;
tsrc = gamedef->getTextureSource();
@@ -286,6 +285,7 @@ void Hud::drawHotbar(v2s32 centerlowerpos, s32 halfheartcount, u16 playeritem) {
return;
}
+ s32 hotbar_itemcount = player->hud_hotbar_itemcount;
s32 padding = hotbar_imagesize / 12;
s32 width = hotbar_itemcount * (hotbar_imagesize + padding * 2);
v2s32 pos = centerlowerpos - v2s32(width / 2, hotbar_imagesize + padding * 2);