FinnishEngineer

Veteran
Veteran
Joined
Oct 20, 2021
Messages
46
Reaction score
12
First Language
finnish
Primarily Uses
RMMV
I want a skill that does more damage on an enemy that has a status effect like stunned.
Is that possible to do?
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
36,686
Reaction score
9,861
First Language
German
Primarily Uses
RMMV
yes, with damage formula coding - but you need to specify which maker you want this for, because different makers use different coding languages.
your profile claims that you are using MV (javascript), but you posted in the forum for VXAce (RGSS3)
 

Shiro-chan

Friendly Neighbourhood Neppy Maid
Veteran
Joined
Aug 7, 2018
Messages
197
Reaction score
61
First Language
German
Primarily Uses
RMVXA
Code:
if b.state?([state x]);[damage formula from state];else;[other damage formula];end

[state x] is your state you want, like how 2 is by default Poisoned etc
[damage formula from state] is what you want if the target is under the state
[other damage formula] is what you want if they aren't

Note that the [] brackets are just for making it more clearly visible, these are NOT part of the formula; you have to use only alphanumerics, like so:
Code:
if b.state?(2);5000;else;100;end

This would, assuming state 2 is the default Poisoned, deal 5000 damage to the target if they're Poisoned, but if the target is not poisoned, it only deals 100 damage. You can use the usual things like
Code:
a.atk * 4 - b.def * 2

as well and you can even do combinations, like if the target is under a second status that would cancel the first one's effects, like so:
Code:
if b.state?([state x])&&!b.state?([state y]);

This would require state x but NOT work (Negative AND) if state y is in place, too.
 

Latest Threads

Latest Posts

Latest Profile Posts

Hello! Can anyone help me? I followed making cooking tutorial for RPG Maker MV. But for some reason buff state that food gives doesn't work in overworld. It disappears. What am I supposed to do?
A shotgun is not a rifle. Huh.
SIGH its so hard to convince my friend that making a game for fun and making one to sell takes different planning. I don't care about weird bothersome ways of doing things in a game made for fun, but when you are planning to market it, there is some stuff that you just have to streamline or cut out.
It might be a little bit boring and tedious, but building that database of armor, items, weapons and skills are super important.

Forum statistics

Threads
124,399
Messages
1,163,340
Members
163,195
Latest member
new88betscom
Top