display how many items are available on the planner panel

just like we display how many you'd need to make if you don't have
enough
develop
Myk Taylor 2023-10-26 09:19:09 -07:00
parent f0a0814553
commit 369ac7821c
No known key found for this signature in database
2 changed files with 2 additions and 1 deletions

@ -58,6 +58,7 @@ Template for new versions:
## Fixes ## Fixes
## Misc Improvements ## Misc Improvements
- `buildingplan`: display how many items are available on the planner panel
## Documentation ## Documentation

@ -294,7 +294,7 @@ function ItemLine:get_item_line_text()
uibs.building_type, uibs.building_subtype, uibs.custom_type, idx - 1) uibs.building_type, uibs.building_subtype, uibs.custom_type, idx - 1)
if self.available >= quantity then if self.available >= quantity then
self.note_pen = COLOR_GREEN self.note_pen = COLOR_GREEN
self.note = ' Available now' self.note = (' %d available now'):format(self.available)
elseif self.available >= 0 then elseif self.available >= 0 then
self.note_pen = COLOR_BROWN self.note_pen = COLOR_BROWN
self.note = (' Will link next (need to make %d)'):format(quantity - self.available) self.note = (' Will link next (need to make %d)'):format(quantity - self.available)