You need to create an class that extends Enchantment and override the methods that make sense for your need.
Then you need to register the enchantment using the RegistryEvent.Register<Enchantment> method.
Then you need to handle an event that makes sense, like a living attack event, check if the player is wearing chest armor with that enchantment and if true set the attacker on fire.
i need make a custom enchantment
like , make a chestplate with molten 1 (name of the enchant)
and when someone hit me it's put him on fire
how to make things like this
please help
One thing that you could do is follow the thorns enchantment. If you change the type of damage caused to DamageSource.ON_FIRE it may work.
You need to create an class that extends Enchantment and override the methods that make sense for your need.
Then you need to register the enchantment using the RegistryEvent.Register<Enchantment> method.
Then you need to handle an event that makes sense, like a living attack event, check if the player is wearing chest armor with that enchantment and if true set the attacker on fire.
I have a tutorial on this here: http://jabelarminecraft.blogspot.com/p/minecraft-modding_6.html
TY guys for your help !!
Thanks guys, I was wondering this too.