Started by
GotorFI
on
Topic category: Help with Minecraft modding (Java Edition)
Hey,
I want to make a block dispenser but the problem is that how I can check if item in a Gui slot is a block and it's placeable? Like for example when I place dirt block, it should check if dirt is a block and if it is a block then it places dirt block and removes one dirt block form the Gui slot. Just like a dispenser but instead of dropping items, it drops blocks. It should also allow only blocks inside this dispenser because items aren't placeable.
How can I do this? I don't want to do if checks for every block because there are hundreds of different blocks in the game.
I would like to get answers as soon as possible!
You can spawn item entity based on inventory contents
"Just like a dispenser but instead of dropping items, it drops blocks"
whoops... I meant just like a dispenser but instead of dropping items, it places blocks (not drop those).
Is this possible?
You can spawn block items too, basically items that represent blocks.
You can also spawn falling block afaik