RMMV Passive States Based on a Section of HP (or anything else for that matter)

zerobeat032

Cloaked Wanderer...
Veteran
Joined
Mar 28, 2014
Messages
379
Reaction score
651
First Language
English
Primarily Uses
RMMV
So I've been using http://www.yanfly.moe/wiki/Auto_Passive_States_(YEP) to make passive states... But there's one thing I can't figure out. Say I want the effect to last when whatever HP,MP,TP is from 25% to 50% only... I basically have it where a section of whatever I'm using causes a state, or at least that's what I'm trying to do, but I can't figure it out. I got it working for under 25. But if I want under 50 BUT above 25, I can't seem to get it working without both states happening and I'm trying not to do that. If anyone knows what I'm not doing, I'd be thankful for the assistance.
 

Another Fen

Veteran
Veteran
Joined
Jan 23, 2013
Messages
608
Reaction score
320
First Language
German
Primarily Uses
You can always combine multiple conditions using && (both conditions must be met) or || (any condition must be met).
So for example, HP being both under 50 and above 25 percent could look like this:
user.hp < user.mhp * 0.5 && user.hp > user.mhp * 0.25
 

zerobeat032

Cloaked Wanderer...
Veteran
Joined
Mar 28, 2014
Messages
379
Reaction score
651
First Language
English
Primarily Uses
RMMV
OK I was thinking that's what I needed to do but I wasn't sure, I'll try it in a second here.
 

Another Fen

Veteran
Veteran
Joined
Jan 23, 2013
Messages
608
Reaction score
320
First Language
German
Primarily Uses
Not sure what exactly you are planning to do with it of course, but don't forget about the "exactly 25%" case too.
 

zerobeat032

Cloaked Wanderer...
Veteran
Joined
Mar 28, 2014
Messages
379
Reaction score
651
First Language
English
Primarily Uses
RMMV
This worked! Thanks a lot. I realized when I was trying this before I wrote it completely wrong and that's why it wasn't working.
 

Latest Threads

Latest Posts

Latest Profile Posts

Time for my daily walk/jog ''Literally starts raining while I open the door''
I just discovered there's a giant jellyfish in the Ace RTP. My day is made.
I'm pretty sure I submitted a username change like 4 months ago.
...
No offense but uh, still waiting for my name to be updated :/
Boss #1 - All 3 phases.
w5fSXys.gif

Forum statistics

Threads
112,394
Messages
1,068,008
Members
146,045
Latest member
Paul_code
Top