Attack/Defense Balancer

So I had an idea for one of my characters: passive that increases attack the same rate their defense is lowered.

This character is a defensive character but I don't know how to go about this.

Would this require Plugins (I have Yanfly's Passive States) or could I make this state using the Notebox?

Thanks!
Noteboxes don't do anything by themselves: they're just that, boxes for you to put in notes. All notetags are added by plugins.
Noteboxes don't do anything by themselves: they're just that, boxes for you to put in notes. All notetags are added by plugins.

Forgot to add I have Yanfly's Buff and States Core....
I could see it being perfectly doable with just events.
I could see it being perfectly doable with just events.

I guess that's correct, tho I haven't at first thought of it..
set v to the actor's defense.
increase atk of the actor via common event by that variable;

I haven't ever tried this, so.. would that work?
Yes that should work.
I could see it being perfectly doable with just events.

I guess that's correct, tho I haven't at first thought of it..
set v to the actor's defense.
increase atk of the actor via common event by that variable;

I haven't ever tried this, so.. would that work?

Yes that should work.

Soooooo....

Something like this?:

[IMG]https://i.ibb.co/W5DzpJf/11-49-05.png[/IMG]

I don't know if i'm on the right track because i'm already thinking if it decreases by -2 or more at one time, it will only increase atk by +1. I want atk to increase at the same rate as def decrease. So -2 def would be +2 Atk, -1090 Def would be +1090 Atk. And it would revert going the other way too up to normal stats but wont decrease atk as Def goes up.
basically yes, although your example code won't work that way. you would need two commands for the changes (adding to ATK and substracting from DEF), and you would make sure that the CE is only called when needed (constantly calling it would cause constant changes and lag) and you might want to use some more mathematics and conditional branches to make sure the values do not go to -1 by themselves etc.
basically yes, although your example code won't work that way. you would need two commands for the changes (adding to ATK and substracting from DEF), and you would make sure that the CE is only called when needed (constantly calling it would cause constant changes and lag) and you might want to use some more mathematics and conditional branches to make sure the values do not go to -1 by themselves etc.

Hmmmmm. Seems very complicated. Not exactly the best at math. I will take a look into this. Thanks!
How much the defense shall be lowered? What will it depend on?
Actually giving up on this. Idea was great, execution was impossible, for me.

Thank you everyone that helped! 🙂
Are you talking about something like stances? In my current project, the "warrior" character has 3 stances which unlock a bunch of abilities based on which is active, and also modifies atk/def by varying amounts. This can be accomplished with Yanfly's buffs and states categories plugin:

First, create the state(s) for your stances, including any stat modifications

Second, set them to have no expiration time and set their categories to be unaffected by either death or recover all, then add in any stat modifications. (the note tags/category names for these special categories are in the file's help section)

And that should do it. Since my warrior learns multiple stances as the player progresses, she can switch between them for balanced stats, heavy defense light offense, or light defense heavy offense.

If you want it to be a skill that's passive and always applies those stat modifications once learned, Yanfly's auto passive states is what you're looking for.
Are you talking about something like stances? In my current project, the "warrior" character has 3 stances which unlock a bunch of abilities based on which is active, and also modifies atk/def by varying amounts. This can be accomplished with Yanfly's buffs and states categories plugin:

First, create the state(s) for your stances, including any stat modifications

Second, set them to have no expiration time and set their categories to be unaffected by either death or recover all, then add in any stat modifications. (the note tags/category names for these special categories are in the file's help section)

And that should do it. Since my warrior learns multiple stances as the player progresses, she can switch between them for balanced stats, heavy defense light offense, or light defense heavy offense.

If you want it to be a skill that's passive and always applies those stat modifications once learned, Yanfly's auto passive states is what you're looking for.

This wasn't what I was looking for. Thank you anyway.

Original thread: https://forums.rpgmakerweb.com/threads/attack-defense-balancer.107616/