code: def find_slots(self, wanted, slots=None):
          
          if slots is None:
              slots = self.inv_slots_preferred + self.window.window_slots
          wanted = make_slot_check(wanted)
  
          for slot in slots:
              if wanted(slot):
                  yield slot
docs: Yields all slots containing the item.
          Searches the given slots or, if not given,
          active hotbar slot, hotbar, inventory, open window in this order.
  
          Args:
              wanted: function(Slot) or Slot or itemID or (itemID, metadata)