Cumulative Power Up Help

Frankster300

Programmer/Game Designer
Member
Joined
Mar 29, 2018
Messages
24
Reaction score
12
First Language
English
Primarily Uses
RMMV
Hey guys! Im trying to figure out how to create a spell that powers your character up until the end of the battle. Something like this:

Power Up Move: When used, it gives 10% physical and magical attack, stacking up to 50% until the end of the battle.

Now i know i can make something like: Temp dmg = (max dmg + (max dmg * 0.powerup #)), but idk how to go into the games coding to force this to happen.

I want to try to see if i can do this without plugins, since ive never installed one before lol. If im forced to use a plugin to solve this problem, can someone show me how to install the plugin needed as well?

Thanks, Frank
 

Doktor_Q

I'm not a real doktor, but I am a real Q
Veteran
Joined
Aug 1, 2016
Messages
811
Reaction score
494
First Language
English
Primarily Uses
RMMV
Well, you can do a little bit with regular buffs with whatever max duration is, since RPGMaker's built-in stat buffs support stacking. By default it's 25% per level, maximum of 50%, though, and could be negated by enemy attack debuffs.

You'd need a plugin to do much beyond that, I'd suggest something from Yanfly's set- Buffs and States Core is a decent place to start. There's even a link at the top of the page explaining how to install plugins, which is pretty effortless in MV.
 

Jesse - PVGames

Game and Graphics Developer
Veteran
Joined
Jun 23, 2012
Messages
1,782
Reaction score
2,775
First Language
English
Primarily Uses
You could do it without a plugin. You can use variables as part of your damage formula, so the trick would be to manipulate the variable in question.

So for example, you have a skill that you want to use and it should increase your attack power by 10% each time you use it up to a maximum of 50%. For the skill, under the "effects" part, have it run a common event. In that common event, have it add +10 to a variable of your choice each time its run, and have a conditional branch at the end that basically says if the variable is >50 then set it to 50.

Then as part of your damage formula, you would incorporate the aforementioned variable. Something like a.atk + (a.atk * v[variablenumberhere]) - hopefully someone can correct me if I am wrong about that, but I did some similar things in Unsung Heroes.
 

Frankster300

Programmer/Game Designer
Member
Joined
Mar 29, 2018
Messages
24
Reaction score
12
First Language
English
Primarily Uses
RMMV
@Jesse - PVGames
For the skill, under the "effects" part, have it run a common event. In that common event, have it add +10 to a variable of your choice each time its run, and have a conditional branch at the end that basically says if the variable is >50 then set it to 50.

Then as part of your damage formula, you would incorporate the aforementioned variable. Something like a.atk + (a.atk * v[variablenumberhere]) - hopefully someone can correct me if I am wrong about that, but I did some similar things in Unsung Heroes.
Is there a way to reset the variable when the battle is over? When you say v[variablenumber here], do you mean the ID number of the variable, or what im calling the variable, like "SkillCount1"?

If you want to post it on here, or message me privately to show me step by step, then i would appreciate it

Also thank you to @Doktor_Q, thats useful to know!
 

BigWhoop

Whoop Big
Member
Joined
Feb 7, 2018
Messages
15
Reaction score
15
First Language
English
Primarily Uses
RMMV
Is there a way to reset the variable when the battle is over? When you say v[variablenumber here], do you mean the ID number of the variable, or what im calling the variable, like "SkillCount1"?
Not that guy, or an expert, but I have a solution, though it could be better. You can put an invisible event on each map (or at least each map that will have battles in it) that activates in Parallel that simply says "If SkillCount1 (to use your example) doesn't equal 0 (using the fancy symbol for doesn't not equal), then set SkillCount1 to 0". Very simple. I tested it out and it seems to work. Like I said, you need event on every map with encounters, if I understand Parallel events correctly. A better way would be to have it set to 0 at the end of each battle, but I can't find an easy way to do that, surprisingly.

I have another suggestion. Assuming you want it to be a buff to the physical and magical attack, not a straight addition to the damage formula like described above, you can make a series of states instead that increase the stats by 10%, 20%, etc and remove the previous one. I have an idea as to how this would work, but I would need to test it out in code. I, or someone else, can give it a shot if you want. The advantage to this over a straight buff is that, if I'm correct, this can't be dispelled by normal debuffs. I could be mistaken though, not an expert like I said.
 

Jesse - PVGames

Game and Graphics Developer
Veteran
Joined
Jun 23, 2012
Messages
1,782
Reaction score
2,775
First Language
English
Primarily Uses
What BigWhoop suggested, having a parallel process on the map that just resets the variable would work, and you can also reset the variable at the beginning or end of each battle through the battle events.
 

Frankster300

Programmer/Game Designer
Member
Joined
Mar 29, 2018
Messages
24
Reaction score
12
First Language
English
Primarily Uses
RMMV
This all looks good! Im probably going to use the plugin way, but i really appreciate everyone's input!
 

BigWhoop

Whoop Big
Member
Joined
Feb 7, 2018
Messages
15
Reaction score
15
First Language
English
Primarily Uses
RMMV
What BigWhoop suggested, having a parallel process on the map that just resets the variable would work, and you can also reset the variable at the beginning or end of each battle through the battle events.
I know he said he'll use a plugin, but I just wanted to point out that resetting it at the start of each battle is rather clever! That didn't occur to me. It's nice because like I said, I can't find a way to activate an event at the end of battle. I think it may be possible using the Immortal state, if I understand it correctly, but that's a much easier solution, IMO.
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Posts

Latest Profile Posts

In other news, my new computer is now ordered, and I'll have it in my hot little hands by the end of the week! CAN'T WAIT!!!
I've said my cat's names in such a baby-talk manner over the years, Biggs is now Biggoro, Bella is now Bellllyyaah, and somehow.....somehow Tessa is Sessashan
Did a massive ****up in my code that would have caused the game to crash on most computers and almost released an update without noticing it.
I keep thinking today is Thursday.
And I look forward to the next preview thread coming this afternoon.
And then I realise it's not Thursday at all.
And then I get sad :(

Forum statistics

Threads
100,449
Messages
976,080
Members
132,082
Latest member
nwr
Top