Tutorial: Custom crafting machine block

Published by Matej on
MCreator Tutorial - Using procedures for a custom crafting block

As the answer to multiple requests, we made a tutorial on how to create a fully operational custom crafting block using the MCreator's new procedure system.

This kind of tutorial was the most requested one since the release of the procedure system that allowed doing such modifications. In this video, you will learn how to:

  • Create a block with its own inventory
  • Implement your own crafting procedure
  • Design a GUI for crafting-table-like blocks
  • Open a GUI using the procedures

The modification introduces a new crafting-table-like block which can be used for fusing Redstone Dust, Diamonds and Gold with Iron Blocks. You put 1 iron block in the top left slot and one of the 3 materials to create Red Iron, Diamond Blocks or Gold Blocks.

 

The mod and its workspace file can be downloaded on the modification's page.

 

 

 

You can find some more examples and help with procedures on our procedure system reference wiki page. If you have any questions or recommendations, leave a comment in the comment section below. Stay tuned!

Share this:

Comments

The random update event is meant to be used with display (client side) effects such as particles. If you check the source code of crops, they actually use normal update tick event, not the random update tick. Update tick is SMP compatible, random update tick event is not.

To make tick update random, you can use random and if condition in the procedure maker when making the procedure that will be bound to the tick update event.

Minecraft 1.13 is finally released! I hope that minecraft forge will be updated soon (this update was very big so I don't know how much time will it require)

Will you make recompilation faster in 1.8.0? Because 20 minutes for a build recompilation is a bit too much for me... :(

How much RAM does your computer have and how much did you dedicate to the MCreator? Unfortunately, the build process depends on the Minecraft Forge and this is what it makes it so slow. Slow internet connection can also be the cause as while recompiling, the dependencies are updated from the internet.

If you don't mind, could you send me the latest version of the workspace you are having such issues with? I can try to test it and profile the compile times.

You could also disable recompilation when the mod element is created or edited in the preferences.

Little suggestion: a procedure block for checking for player direction. This could be useful for rotatable blocks (using the event trigger "when block placed by") and a lot of stuff
Sorry for bad English

The procedure condition "is block at x, y, z air (I don't remember very well its name)" doesn't seem to work. Also, I don't get why is it there if you can simply use "get block at x, y, z = air" procedure block instead
Sorry for bad English

It should work as it uses integrated Minecraft method to do so. It is there because in the Minecraft code there is a separate method for this which is most likely more optimized and therefore more suitable. Are you sure you didn't just use wrong coordinates and were checking the wrong location?

I have a little bug.
I made some textures on the MCreator/forge/build/resources/main/assets/minecraft/blocks folder.
Then, after closing minecraft client test environment, all the new textures got removed. They were still in the history of the file manager, but opening them said they were broken files. I tried to copy them, same result. So I made a screenshot of the history and I copied the icons of the textures into paint.net. Fortunately, since they were 16x16 textures, I saved all of them. I saved them in the desktop then copied them in the folder of mcreator textures.
I did a client test environment again. After closing minecraft, I noticed that the new textures disappeared again. Fortunately, I had the backup on my desktop.
Why do they disappear? :(



Donate to MCreator

By donating to developers you can speed up development, as with more resources, we can dedicate more time to MCreator. It is a free project made by developers working on it in their free time.