Auto smelt enchantment (heating)

Started by tigerjam on

Topic category: User side tutorials

Joined Aug 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Auto smelt enchantment (heating)

Is there any way I could make an auto smelt (heating) enchantment? Side note: this is the first enchantment so please be clear

Joined May 2014
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
It's actually not too…
Mon, 08/10/2020 - 00:08

It's actually not too difficult, luckily.

First set up your procedure so that it fires on "A block is broken" global trigger (defined by the dropdown menu on the first green block in your procedure).

Now, essentially, you need to test if the item version of that block has a smelting recipe. If it does, then cancel the event (so the actual block doesn't drop) and drop the smelted version of the item on the ground.

Here is a little sample procedure I whipped up that'll do just that: https://imgur.com/a/igyr8J1 (Of course, replace LOOTING with the name of your custom enchantment). 

The reason these things are not definable inside the enchantment is because enchantments, by their nature, are basically just a sort of "tag" that you can apply to an item via an enchantment table. The enchantment in itself is powerless (with a couple exceptions). Thus, it needs to be used in an external procedure that tells the game what to do if the enchantment is on an item.

Joined Aug 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Thank you so much for the…
Mon, 08/10/2020 - 22:16

Thank you so much for the help! There was a few glitches with the code 1. You could not break blocks 2. When I fixed it you couldn’t break blocks with heating. I have fixed both these issues and here is the code:     https://docs.google.com/document/d/1vPiCqFVdVIDfAf4Bo73LAZmIDXAi9kMsJfHpuyq_ztE/edit?usp=sharing