i have yanfly plugins so if there's a way to do it with said plugins then feel free to tell me
MV trying to make an attack where if the opponent is inflicted with a specific state the attack deals a gurranteed attack, does anyone know how to ?
Javascript/Plugin SupportBy guaranteed attack do you mean ignore accuracy checks? If so something like this should work if you're using Yanfly's Buff and States core plugin. Put this into the notetag of the state applied to the enemy.
Code:
<Custom Select Effect>
if(user.isActor() && this.isDamage()){
this._formerItemSuccessRate = this.item().successRate;
this.item().successRate = 100;
}
</Custom Select Effect>
<Custom Deselect Effect>
if (this._formerItemSuccessRate !== undefined) {
this.item().successRate = this._formerItemSuccessRate;
}
</Custom Deselect Effect>
i meant that gurranteed meaning that the attack will 100% deal a critical if the enemy is currently inflicted with a specific state problem is i only want it on a specific skill only not all attacks
If you're using his action effects plugin you can just follow this tips and tricks he made exactly.
www.yanfly.moe
Flare Gun (MV Plugin Tips & Tricks) - Yanfly.moe Wiki
The skill's Success Rate does not ignore accuracy checks - if you look at the default skills in a new project (or a new, blank skill entry) the default success rate is already 100%.
For Physical Hit skills, it serves as a multiplier for the attacker's hit parameter; for Magical Hit skills, it is actually the sole determinant of the original hit roll, but again it's typically already 100%.
That said, it doesn't appear to be capped anyplace, so what you describe might work correctly for Physical Hit skills if you made the value higher - like, 1000.
Your notetags also don't take into account any eva or mev on the target's part.
That is really different from what you actually asked in the first place.
P.S. Please, "guaranteed" 😛
Oop, it's been so long since I've used the default formula I forgot it doesn't just use hit and skill success. That's a my bad, though for what he's actually asking for the linked tip and trick will work.
kinda late but i have figured it out using yanfly's critical contorl,buff and states and skill core
you put this on the notetag of the skill
<Critical Rate Formula>
if (target.isStateAffected(stateidhere)){
rate = user.cri + 1;
}
else{
rate = user.cri;
rate = rate * (1 - target.cev);
}
</Critical Rate Formula>
you put this on the notetag of the skill
<Critical Rate Formula>
if (target.isStateAffected(stateidhere)){
rate = user.cri + 1;
}
else{
rate = user.cri;
rate = rate * (1 - target.cev);
}
</Critical Rate Formula>
Adding the user's critical doesn't do anything. Simply returning 1 is 100% chance for critically hitting.