I want a passive state that amplifies healing for %1 for every %4 health its target is missing. Can some of you sent a lunatic state notetag for it?
I want all healing spells of that certain character be affected.
If you do not have such a notetag, just a skill notetag that I can copy paste should suffice.
Edit: forgot the 4% of missing health part, JamesRyan's tag will work.
So you mean the amplified healing effect is based on your based healing effect from damage formula, right?
Just change this:
var bonus = Math.ceil(missingHp * 0.01 * amptimes);
to
var bonus = Math.floor(-value * 0.01 * amptimes);
value is equal to your based healing amount defined by your skill damage formula. So 1% of it should be 0.01 and is multiplied to amptimes (amptimes = 12.5 in your example). So if your target has 50/100 HP and your skill heals 100 HP, the bonus HP recovered is 100 + (100 * 0.01 * 12.5) = 100 + 12.5 = 112.5 (113 due to Math.ceil), right?
This idea of yours is very interesting. May i take it to my project?
EDIT: Sorry i forgot. It should be -value and Math.floor
Of course you can. I am happy to help, and willing to share ideas.
The only problem is the heal now decreases the more HP is missing. 😀
Just another edit for better heal. It should be var bonus = Math.floor(-value * 0.01 * amptimes); ☺️
Ow thank you. It is so useful now, you are my hero. ^^
Is this ready to be closed as solved?
Not yet, it is solved but I also need its damage counterpart please.
I checked Yanfly's tips and tricks and found this.
<Custom Confirm Effect>
// Check if the damage dealt deals physical HP damage.
if (this.isPhysical() && this.isHpEffect() && value > 0) {
// Base the bonus damage off of the user's HP rate.
value *= 2.00 - user.hpRate();
// Add bonus damage equal to the user's missing HP.
value += (user.mhp - user.hp) * 0.50;
// Round up the calculations.
value = Math.ceil(value);
}
</Custom Confirm Effect>
My only problem is making it %1 for every %4 the attacker (and not the target) is missing.
I changed those numbers with weird things but I do not know what value* and value+ is (and the difference between) and how should I modify them.