I tring to make Skill called Counter that deals 75% of Damage dealed by Enemy. I don't know how to make it to work.
How to make Skill based on Damage dealed by Enemy?
RPG Maker MV SupportThere are several ways, but they all require some programming knowledge.
Please tell us exactly what the skill should do, and how good your programming skills are.
Please tell us exactly what the skill should do, and how good your programming skills are.
I do want to make it deal 75% of damage dealed to user. Damage should be dealed be skill type called Physical
Whatever you do, you're going to need a plugin to do this well.
Usually when a game has counterattacks, those are passive. That is, they happen automatically when you get attacked, without you selecting anything. If that's what you want, then you should look at Yanfly's Counter Control.
If you instead want it to be a skill that the user selects for their turn, you don't need the Counter Control plugin.
Either way, you're going to need Yanfly's Buffs and States Core, and Auto Passive States.
In the Counter skill, give it a passive state notetag.
In that passive state, give it the notetags:
Then, in your Counter skill's damage formula, you can put
Usually when a game has counterattacks, those are passive. That is, they happen automatically when you get attacked, without you selecting anything. If that's what you want, then you should look at Yanfly's Counter Control.
If you instead want it to be a skill that the user selects for their turn, you don't need the Counter Control plugin.
Either way, you're going to need Yanfly's Buffs and States Core, and Auto Passive States.
In the Counter skill, give it a passive state notetag.
In that passive state, give it the notetags:
Code:
<Custom Respond Effect>
target.damTracker = value;
</Custom Respond Effect>
<Custom Turn End Effect>
if (user.damTracker)
delete user.damTracker;
</Custom Turn End Effect>
<Custom Battle Effect>
if (user.damTracker)
delete user.damTracker;
</Custom Battle Effect>
Then, in your Counter skill's damage formula, you can put
a.damTrackerOriginal thread: https://forums.rpgmakerweb.com/threads/how-to-make-skill-based-on-damage-dealed-by-enemy.163202/