itemstack iterator is a copy

Started by Catnip on

Topic category: Troubleshooting, bugs, and solutions

Last seen on 15:56, 26. Apr 2024
Joined Apr 2023
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
itemstack iterator is a copy

The "For each slot of inventory of (event/target) entity as itemstack iterator" block gets the itemstack as a copy.  I think it would be helpful if it also gave you a slot id iterator or something so you could modify the slot.  it would also be good if it was better indicated that it was a copy like the "get copy of item from slot (slot id) of (event/target entity) if it has inventory" block.

 

 

Also, for people who want a temporary workaround, you can use the repeat block paired with a local variable that increases to get slot ids and use the slot ids to check for items.