MV Multi-Attack nerf

Hello, I've been working on a game for about 5 years now and have decided to drastically nerf multi-attacks if possible. I've tried asking some AIs to help me code this, since I'm not a coder at all and really struggle with intricate things like this, and would like to ask for some help from real life humans if possible (AI's all failed 😛)

Basically when an actor uses the "attack" option in battles, that calls on any extra +1 attacks they have. This is proving to be way too strong, and would like a plugin that nerfs subsequent attacks on that turn. Say an Actor has 2 actions, and 2 attacks per action. If he mashes "attack" for both of them, that would be 4 Attacks dealing full damage. This has proven to be too strong and invalidates a lot of other options.

Instead, I would like the first successful hit of these 4 combined attacks to deal full damage, while the rest are nerfed by let's say 50%. So instead of this Actor attacking 4 times and dealing 100, 100, 100, 100, he instead deals 100, 50, 50, 50. This should reset each turn so that the first raw Attack each turn does full damage again.
Say he misses the first Attack in an action, but the second hits, I would prefer if that first direct Hit still dealt full damage, even though it is technically the second "attack" of the turn.


This has frustrated me for a few days, and any help would be very much appreciated.
Why don't you just reduce the number of multiattacks?
Hello, I've been working on a game for about 5 years now and have decided to drastically nerf multi-attacks if possible. I've tried asking some AIs to help me code this, since I'm not a coder at all and really struggle with intricate things like this, and would like to ask for some help from real life humans if possible (AI's all failed 😛)

Basically when an actor uses the "attack" option in battles, that calls on any extra +1 attacks they have. This is proving to be way too strong, and would like a plugin that nerfs subsequent attacks on that turn. Say an Actor has 2 actions, and 2 attacks per action. If he mashes "attack" for both of them, that would be 4 Attacks dealing full damage. This has proven to be too strong and invalidates a lot of other options.

Instead, I would like the first successful hit of these 4 combined attacks to deal full damage, while the rest are nerfed by let's say 50%. So instead of this Actor attacking 4 times and dealing 100, 100, 100, 100, he instead deals 100, 50, 50, 50. This should reset each turn so that the first raw Attack each turn does full damage again.
Say he misses the first Attack in an action, but the second hits, I would prefer if that first direct Hit still dealt full damage, even though it is technically the second "attack" of the turn.


This has frustrated me for a few days, and any help would be very much appreciated.
So basically what you want is a plugin that for any actor actions in a given turn for which the player has chosen the Attack command, the first successful hit deals 100% damage and any subsequent ones deal half?
you could use yanfly's skill core and make the attack skill apply a 1 turn state to the user after use and then either have the formula halve its own result or use a pre-damage eval and directly cut the damage in half if the user has the state
you could use yanfly's skill core and make the attack skill apply a 1 turn state to the user after use and then either have the formula halve its own result or use a pre-damage eval and directly cut the damage in half if the user has the state
This is actually a really clever idea.

Not really sure how to do this using yanfly's skillcore though. I know about adding states through the damage formula, but the way I know how to do it doesn't seem to work with the new 1-turn state.
So basically what you want is a plugin that for any actor actions in a given turn for which the player has chosen the Attack command, the first successful hit deals 100% damage and any subsequent ones deal half?
Yes, but just for that turn. The AIs I've tried to help write this have actually figured out the first part, but always keep the nerf beyond the turn they receive it. I need the first attack each actor hits per turn to be full-strength, just any subsequent multi-attacks to be nerfed.
I know about adding states through the damage formula, but the way I know how to do it doesn't seem to work with the new 1-turn state.
you could do that. you would just need to calculate the damage first and save it into a variable, add the state, and then use the variable at the end
Code:
var dmg = a.isStateAffected(22) ? a.atk/2 : a.atk; a.addState(22); dmg
but if you use auto battlers, the formula will be ran before they act even if they never used the skill and theyll end up always having the state
you could do that. you would just need to calculate the damage first and save it into a variable, add the state, and then use the variable at the end
Code:
var dmg = a.isStateAffected(22) ? a.atk/2 : a.atk; a.addState(22); dmg
but if you use auto battlers, the formula will be ran before they act even if they never used the skill and theyll end up always having the state
What exactly do you mean by auto battlers? I use the 2d side view system, everything is manual and there's nothing automated, but I'm pretty sure they always had the state yeah. This formula is close to how I did it, but will try yours since it's very different in a specific way. Thank you again for the help.

Edit: Okay this actually worked perfectly, but I still need to fit in the actual damage formula of a regular attack. (which is a.atk * 3.8 - b.def * 2). Again I'm not a coder, so I have no idea where to put it or how to format it properly, it's incredibly precise.
What exactly do you mean by auto battlers?
i meant battlers with the auto battle flag on them, any of their states, or their gear. it makes them fight automatically, but a part of the considerations it makes involves running the damage formulas for each of their skills, which would give them the state without use. If you dont use it, it shouldnt be an issue. otherwise, Yanfly's plugin avoids it.
i meant battlers with the auto battle flag on them, any of their states, or their gear. it makes them fight automatically, but a part of the considerations it makes involves running the damage formulas for each of their skills, which would give them the state without use. If you dont use it, it shouldnt be an issue. otherwise, Yanfly's plugin avoids it.
Yeah everything is manual per turn, the only state that could make that an issue is the charm state which makes them auto attack randomly.

Thank you very much by the way, the formula you entered was perfect and completely accomplishes what I was hoping. The only issue is that it erases the base damage formula of the skill, so my test battlers were hitting for 30 instead of 130.
the only state that could make that an issue is the charm state which makes them auto attack randomly.
mind you, i mean the auto battle flag trait. not state restrictions

Spoiler
1755247764155.png
1755247783316.png

The only issue is that it erases the base damage formula of the skill, so my test battlers were hitting for 30 instead of 130.
i used a.atk, but the point was to show how what i said would be done. replace both of the "a.atk"s with your entire formula. you only need to halve the one before the colon. thats the one that gets used if the state is active
mind you, i mean the auto battle flag trait. not state restrictions



i used a.atk, but the point was to show how what i said would be done. replace both of the "a.atk"s with your entire formula. you only need to halve the one before the colon. thats the one that gets used if the state is active
Appreciate this a lot, everything seems to be working exactly as I was hoping it would, you're the best. I'll keep my fingers crossed nothing breaks across the 150 hours the game already has down with this in place, but from what I can tell it's pretty smooth. Thanks again.

Original thread: https://forums.rpgmakerweb.com/threads/multi-attack-nerf.179574/