RMMV YEP Buffs and States Core, Need help with state check then replace

chungusblastee

Villager
Member
Joined
Mar 21, 2021
Messages
12
Reaction score
2
First Language
English
Primarily Uses
RMMV
I'm trying to work on abilities that combo with one another. For example, a Water Bolt that applies a Wet state. Then a Freezing Breath that damages, but if the enemy is Wet, it also replaces the Wet state with a Frozen state that stuns. I have no idea how to go about achieving this so any suggestions or solutions are welcome.
 

coucassi

Veteran
Veteran
Joined
Sep 23, 2019
Messages
50
Reaction score
62
First Language
German
Primarily Uses
RMMV
You can try inserting something like this in your damage formular for Freezing Breath:
'if (b.isStateAffected(1)) b.addState(2)'
where 1 is the State ID of Wet and 2 the State ID of Frozen.
Then you can add an effect to your Freezing Breath that would remove the state Wet, just like you do with a Cure Skill/Item.

Another way would be giving everyone a 100% resistance against Frozen, but having the Wet state reduce this resistnace to 0.

Lastly, since you are using Yanfly Plugins, his Action Sequence Pack allows Skills to have an if-Condition, where you could make the Wet State a condition forapllying the Frozen State in your Freezing Breath notetag.

EDIT: If you use the first solution, to have Freezing Breath inflict damage add ; before typing your damage formular as usual:
'if (b.isStateAffected(1)) b.addState(2); a.mat * 6 - b.mdf * 2'
for example.
 
Last edited:

chungusblastee

Villager
Member
Joined
Mar 21, 2021
Messages
12
Reaction score
2
First Language
English
Primarily Uses
RMMV
You can try inserting something like this in your damage formular for Freezing Breath:
'if (b.isStateAffected(1)) b.addState(2)'
where 1 is the State ID of Wet and 2 the State ID of Frozen.
Then you can add an effect to your Freezing Breath that would remove the state Wet, just like you do with a Cure Skill/Item.

Another way would be giving everyone a 100% resistance against Frozen, but having the Wet state reduce this resistnace to 0.

Lastly, since you are using Yanfly Plugins, his Action Sequence Pack allows Skills to have an if-Condition, where you could make the Wet State a condition forapllying the Frozen State in your Freezing Breath notetag.

EDIT: If you use the first solution, to have Freezing Breath inflict damage add ; before typing your damage formular as usual:
'if (b.isStateAffected(1)) b.addState(2); a.mat * 6 - b.mdf * 2'
for example.
So far I have this, I'm very new to rpgmaker mv so I am not sure if I'm on the right track. Should I be adding anything to the notes, feel free to explain like I'm clueless (because I am). Currently my Wet state is 13 and the Frozen state is 47.
Here is what I added to the skill notes.
1617949680879.png
 

coucassi

Veteran
Veteran
Joined
Sep 23, 2019
Messages
50
Reaction score
62
First Language
German
Primarily Uses
RMMV
You have to add it to the formular right under HP Damage, where you 1 * a.mat. The Note can remain empty in this case.

Formular:
if (b.isStateAffected(13)) b.addState(47); a.mat

Also you'll want to add to Effects:
Remove State: Wet

So that the target won't be Frozen and Wet at the same time.
 

chungusblastee

Villager
Member
Joined
Mar 21, 2021
Messages
12
Reaction score
2
First Language
English
Primarily Uses
RMMV
You have to add it to the formular right under HP Damage, where you 1 * a.mat. The Note can remain empty in this case.

Formular:
if (b.isStateAffected(13)) b.addState(47); a.mat

Also you'll want to add to Effects:
Remove State: Wet

So that the target won't be Frozen and Wet at the same time.
Thank you so much it worked just like how I want it!
 

Latest Threads

Latest Posts

Latest Profile Posts

Signed a lease on a new place today. Back into town, closer to shops, family and takeaway - none of those could be a good thing! 10 days to moving date.
let me introduce you to my worlds source of "wool". A pretty simple-minded, easily scared and mostly blind, double-headed big wooly bird thingy :D Children may be able to ride on a trained one, but they don't support the weight of adults, so they aren't suitable for transportation. And herders use the shown tool to give them sound commands
6nwyqEJ.png
This Life is a Dream is in full production! More pics and some free promo assets coming soon!
Dragonfly3116 wrote on Redweaver's profile.
i need to ask do you mind sending me a link to tutorial town an legend of ancients Please My new Email is necroboy1973@gmail.com
I Am A Member On The Site Here As Well If Your Still teaching Let Me Know Thanks Joseph

Forum statistics

Threads
110,525
Messages
1,053,926
Members
143,614
Latest member
TrueNoper
Top