Started by
Magmagenix
on
Wed, 02/10/2021 - 09:44
Topic category: Help with modding (Java Edition)
I want to create an enchantment similar to smite, but instead of doing extra damage to undead enemies it will do extra damage to Illagers, how do I create an enchantment like this?
I think I have solution for you, as I am just making similar enchantment. With illagers it's a bit easier, because they have separate entity type ^^
I think it should look like this:
It's global trigger launching when entity is hurt. It's really important that you have source entity and target/event entity put correctly.
Didn't test it, but I think it should work. I will try similar enchantment with iron golems and we will see if I encounter any bugs ^^
I've tried that procedure but it doesn't do anything, but for some reason it adds the level at the end of the swords name when I enchant it
That's weird. Since that comment from May, I already did that feature and it's working correctly in my mod (it's Dismantle enchantment here).
The only difference is that I used NBT tag, Entity tag and "iron golem" as attack's goal (NBT tag and Entity tag for other mods to use, they do not need to be used), but I don't think it is the case. Can you please show me the procedure itself?