Hide labels option

This commit is contained in:
oz-tal 2023-08-30 15:26:36 -04:00
parent 495ba23a7a
commit e6ede85c9c
3 changed files with 8 additions and 0 deletions

View File

@ -33,6 +33,7 @@ hb.settings.forceload_default_hudbars = hb.load_setting("hudbars_forceload_defau
-- Misc. settings
hb.settings.alignment_pattern = hb.load_setting("hudbars_alignment_pattern", "string", "zigzag", {"zigzag", "stack_up", "stack_down"})
hb.settings.autohide_breath = hb.load_setting("hudbars_autohide_breath", "bool", true)
hb.settings.hide_labels = hb.load_setting("hudbars_hide_labels", "bool", false)
local sorting = minetest.settings:get("hudbars_sorting")
if sorting ~= nil then

View File

@ -52,6 +52,10 @@ local function player_exists(player)
end
local function make_label(format_string, format_string_config, label, start_value, max_value)
if hb.settings.hide_labels then
return ""
end
local params = {}
local order = format_string_config.order
for o=1, #order do

View File

@ -57,6 +57,9 @@ hudbars_alignment_pattern (HUD bars alignment pattern) enum zigzag zigzag,stack_
# of the default one.
hudbars_sorting (HUD bars order) string
# If enabled, hide the labels over the bars
hudbars_hide_labels (Hide bar labels) bool false
[Positions and offsets]
# Horizontal (x) main position of the HUD bars over the entire screen.
# 0.0 is left-most, 1.0 is right-most.