Browse Source

Ensuring nonexistent item can't be selected

pull/9/head
Ryan Reed 1 month ago
parent
commit
f499a45371
1 changed files with 2 additions and 0 deletions
  1. +2
    -0
      scenes/ui/quick_slots.gd

+ 2
- 0
scenes/ui/quick_slots.gd View File

@ -56,6 +56,8 @@ func get_selected_item() -> String:
return _items[_selected_item]
func select_item_index(slot_index: int) -> void:
if slot_index >= _items.size(): return
_selected_item = slot_index
update_highlighted_slot()
InventoryManager.quick_slot_item_changed.emit(get_selected_item())


Loading…
Cancel
Save