MZ HP Absorb on a weapon.

Hopefully this is the right place to post this. I'm trying to add some sort of HP Absorb or life leech to a weapon so that regardless of the attack if the weapon hits the enemy the wielder gains HP.

If it makes a difference I'm wanting to put this on a sword. I'm open to plugins if need be but would prefer to not use them if it isn't too much trouble otherwise.
There are a number of ways you could do this. You could do something with a common event attached to the weapon, but it would be a little convoluted and to me it looks janky to have the effect happen after the attack is completed.

The most seamless way is to use VisuStella's Battle Core. Give the weapon the following notetag:
Code:
<JS Post-Damage as User>
user.gainHp(value);
</JS Post-Damage as User>
There are a number of ways you could do this. You could do something with a common event attached to the weapon, but it would be a little convoluted and to me it looks janky to have the effect happen after the attack is completed.

The most seamless way is to use VisuStella's Battle Core. Give the weapon the following notetag:
Code:
<JS Post-Damage as User>
user.gainHp(value);
</JS Post-Damage as User>
Awesome, works like a charm! Thank you!

This may be more complicated but when I was trying to find out how to do the HP Absorb I came across a video where they guy was doing that in MV with the added bonus of increasing the attack value for every enemy killed with that sword, would that be possible as well?
You could do something with a common event attached to the weapon
not in MZ default - common events can only be attached to items and skills

Moved to: Plugin Requests
not in MZ default - common events can only be attached to items and skills
You're right, I misspoke - my intent was you'd make a separate Attack skill with that common event, then attach that to the weapon via the Attack Skill trait.

But I maintain the plugin is the slicker method.

when I was trying to find out how to do the HP Absorb I came across a video where they guy was doing that in MV with the added bonus of increasing the attack value for every enemy killed with that sword, would that be possible as well?
Probably not in the same way that it was done in MV. That sounds like it would have relied on Yanfly's Item Core for the sword to be an independent item, and MZ doesn't have an equivalent to that.

You'd have to figure out a different way, like using notetags from the Battle Core plugin I referenced above to increment a variable and you modify the outgoing damage with that variable.

Original thread: https://forums.rpgmakerweb.com/threads/hp-absorb-on-a-weapon.157816/