Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 24 additions & 2 deletions LuaUI/Widgets/unit_healthbars.lua
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,10 @@ local function OptionsChanged()
drawBarPercentages = options.drawBarPercentages.value
barScale = options.barScale.value
debugMode = options.debugMode.value



barWidth = options.barWidth.value
barHeight = options.barHeight.value
healthbarDistSq = options.unitMaxHeight.value*options.unitMaxHeight.value
healthbarPercentSq = options.unitPercentHeight.value*options.unitPercentHeight.value
healthbarTitleSq = options.unitTitleHeight.value*options.unitTitleHeight.value
Expand All @@ -131,7 +134,7 @@ end

options_path = 'Settings/Interface/Healthbars'
options_order = { 'showhealthbars', 'drawFeatureHealth', 'drawBarPercentages', 'flashJump', 'showEnemyStatus',
'barScale', 'debugMode', 'minReloadTime',
'barScale','barWidth','barHeight','debugMode', 'minReloadTime',
'unitMaxHeight', 'unitPercentHeight', 'unitTitleHeight',
'featureMaxHeight', 'featurePercentHeight', 'featureTitleHeight',
'invert_shield', 'invert_health', 'invert_building', 'invert_morph',
Expand All @@ -141,6 +144,7 @@ options_order = { 'showhealthbars', 'drawFeatureHealth', 'drawBarPercentages', '
'invert_slow', 'invert_goo', 'invert_jump', 'invert_jump_charge', 'invert_reclaim', 'invert_resurrect',
}
options = {

showhealthbars = {
name = 'Show Healthbars',
type = 'bool',
Expand Down Expand Up @@ -185,6 +189,24 @@ options = {
step = 0.25,
OnChange = OptionsChanged,
},
barWidth = {
name = 'Bar width',
type = 'number',
value = 14,
min = 2.5,
step = 0.25,
max = 30,
OnChange = OptionsChanged,
},
barHeight = {
name = 'Bar Height',
type = 'number',
value= 3,
min = 1,
step = 0.1,
max = 5,
OnChange = OptionsChanged,
},
minReloadTime = {
name = 'Min reload time',
type = 'number',
Expand Down