Inventory Gauge


A mod that shows a moveable gauge of your inventory capacity on the screen.

Utilities
17 days ago
2.0
186

i Per-player Colour Configuration

23 days ago

Have you tried using "progressbar" elements instead of "empty-widget"? You can change their colour at runtime using element.style.color.

22 days ago
(updated 22 days ago)

Thank you very much for the suggestion, Shemp! When I first started trying to make this mod I had tried using the progressbar and wasn't getting it to look how I liked, so I had switched to empty-widget.

I have converted back to progressbar and the color settings are now per-player and refresh on the new window update. The colors are even more accurate to the color picker settings now.

Changed in v1.2.0.

Thanks again!

22 days ago

I made some adjustments to the progress-bar style (in data.lua):

styles.inv_bar_segment = {
  type = "progressbar_style",
  padding = 0,
  bar_width = 20,
  bar = {
    base = {
        draw_type = "outer",
        type = "composition",
        position = {200, 80},
        corner_size = 1,
    }
  }
}

This will cause the bar to look a bit flatter without the gaps like you had it before.

Also, you can make your overlay text non-interactable like this (control.lua, line 342):

local overlay = container.add{ type = "label", name = "inventory_segments_label", caption = overlay_caption, style = "inv_bar_text", ignored_by_interaction = true }

This will cause your segment tooltips to show.

Obviously test all of this first, don't just take my word for it!

21 days ago

Wow, I really like how this looks with your changes that you suggested. Thank you so very much for all your help with this, Shemp!

I have released 1.2.1 which incorporates these suggested changes.

New response