forked from mtcontrib/minetest_hbhunger
Fix displaying too many decimal places
This commit is contained in:
parent
957decb6ac
commit
96f05c4e73
2
init.lua
2
init.lua
@ -41,7 +41,7 @@ end
|
||||
dofile(minetest.get_modpath("hbhunger").."/hunger.lua")
|
||||
|
||||
-- register satiation hudbar
|
||||
hb.register_hudbar("satiation", 0xFFFFFF, S("Satiation"), { icon = "hbhunger_icon.png", bgicon = "hbhunger_bgicon.png", bar = "hbhunger_bar.png" }, 20, 30, false)
|
||||
hb.register_hudbar("satiation", 0xFFFFFF, S("Satiation"), { icon = "hbhunger_icon.png", bgicon = "hbhunger_bgicon.png", bar = "hbhunger_bar.png" }, 20, 30, false, nil, { format_value = "%.1f", format_max_value = "%d" })
|
||||
|
||||
-- update hud elemtens if value has changed
|
||||
local function update_hud(player)
|
||||
|
Loading…
Reference in New Issue
Block a user