Check for number of items in the whole GUI not only one slot

Started by TDO on

Topic category: Help with modding (Java Edition)

Last seen on 11:31, 25. Jul 2024
Joined Dec 2022
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Check for number of items in the whole GUI not only one slot

I want to do a shop block, and everything is done, except the part that stores the collected items in the block GUI and takes items from it. Idk how to check for the whole GUI except  two slots.

I need first to check if in the whole GUI there is enough if the specified item; then substract them from the GUI, but I also need to check for slots with enough room for the coins collected from the clients.

If someone knows how to do this, tell me i would be so greateful 🙏