Game Crashes when trying to access entity inventory via procedure

Started by kwii on

Topic category: Troubleshooting, bugs, and solutions

Joined Apr 2026
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Game Crashes when trying to access entity inventory via procedure

Whenever I try to access my custom entity's inventory with a procedure (by use of the "get a copy of item from slot [item] of [entity] if it has inventory" block), the game just crashes with this error: 

java.lang.RuntimeException: Slot 0 not in valid range - [0,0)

does anyone know why this might be happening?

Joined Apr 2026
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Looking at this, there…
Mon, 04/06/2026 - 16:09

Looking at this, there appears to be no discrepancies. I have 17 slots in my gui, IDs from 0-16, and I am trying to access the 16th slot. The entity also has its inventory size set to 17 slots.

Joined Apr 2026
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
I am trying to access a…
Sun, 04/12/2026 - 23:04

I am trying to access a custom entity's inventory, not a block's inventory

Joined Apr 2026
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
i checked, and i made sure…
Fri, 04/17/2026 - 04:12

i checked, and i made sure it was definitely larger.