RMMZ Make slip damage KO enemies but not allies

jkweath

Goes Fast
Veteran
Joined
Sep 21, 2016
Messages
406
Reaction score
610
First Language
English
Primarily Uses
RMMV
Hello,

So I'm wondering if anyone would be open to writing a script (unless there's one floating around already that I'm not aware of) to make poison ("Slip") damage KO enemies, but not allies.

In the editor, you can set up slip damage to KO or not to KO, but the setting applies to both allies and enemies. I'd like this setting to *only* apply to allies, if possible.
 

Kenen

Veteran
Veteran
Joined
Apr 3, 2012
Messages
341
Reaction score
252
First Language
English
Primarily Uses
RMMZ
JavaScript:
_Game_Battler_maxSlipDamage = Game_Battler.prototype.maxSlipDamage;
Game_Battler.prototype.maxSlipDamage = function() {
    if (this.isEnemy()) return this.hp;
    return _Game_Battler_maxSlipDamage.apply(this);
};
 

jkweath

Goes Fast
Veteran
Joined
Sep 21, 2016
Messages
406
Reaction score
610
First Language
English
Primarily Uses
RMMV
Awesome, thank you! I'll check this out ASAP :rhappy:
 

Latest Threads

Latest Posts

Latest Profile Posts

I have made 60 new skills! ''after test'' I have made 3 new skills!

Made a new battleback this week! How's it look?
"This is the real secret to life - To be completely engaged with what you are doing in the here and now. And instead of calling it work, realize it is play."
Me: "I don't to use other engines because I'd have to do a lot of coding."

Also my desktop right now....
mycurrentdesktop.jpg

...I literally spend more time using VS Code than MZ. :kaoswt:
actually, are there any JRPG type games (I guess turn based, so not ARPGs like say, Vagrant Story) where you have only one party member for the majority of the game? (I wonder if I'm forgetting something obvious.)

Forum statistics

Threads
113,809
Messages
1,077,643
Members
147,866
Latest member
raw2na
Top