Status Condition Help Thread

Hello i need some help making some status conditons and passives cause lunatic mode is really complex for good reason

1. Freeze: Stops enemy from moving until hit with a fire or physical attack SOLVED

2. Ultimate Freeze: Same effects, except whilst in the status effect all attacks will do increased damage or crit unti; worn off. SOLVED

Passive:

3. Phoenix: Once per battle, when a actor or enemy dies, they are revived with 1 hp and will have hp regen for 3 turns that restors 10-20 percent of their health.

4. Ancient: Every time this actor is attacked it's attack is increased by 20%, up to 200%, if this is maxed out it is reset and the unit will have it's MP maxed. SOLVED

5. Marzex: If this actor is below 50% they will not be able to move for 5 turns, but will put up a barrier that will negate %40 of all actors current hp, aswell as give 10% hp regen for 2 turns.
SOLVED

6. Showtime: Each time the actor uses a basic attack during a battle increase its damage by a set percentage or amount, caps at 10, when maxed at 10, the next hit is guaranteed to be a critical hit and inflict stun on the opponent

Pleeeease, I will try solve some of these myself, but all help will be very very very much apprieciated, as i do want the best combat system for ya'll, Idk any good rewards for helping but thanking you, ill creidt you aswell.

Thanks

Gen
Alright, so I don't really know about any of the others, but the freeze on is easy.
Just set the state to resitrict movement, and then have all of your fire skills remove that state
For ultimate freeze, just have it increase the Physical Damage Rate, as well as the Magical, if you want that.
Alright, so I don't really know about any of the others, but the freeze on is easy.
Just set the state to resitrict movement, and then have all of your fire skills remove that state
For ultimate freeze, just have it increase the Physical Damage Rate, as well as the Magical, if you want that.
Thank you's so much Tri, forgot how basic that is to set up, now the other passives are the only issue xd, again thanks!
Hmm. Phoenix sounds like something that could be easily done with yanfly's autolife tips and tricks.
The only thing you'd need to add is a state that makes the character immune to any further application of phoneix until the battle ends. (And the health regen, which is a pretty standard state you can just make in the engine)

Marzex sounds like a troop event kinda thing. Check every turn if character that has marzex state is in party and if so save their max and current HP in 2 variables. If current HP < 50% max HP force action with a dummy barrier skill. Use yanfly's instant cast to avoid it using up the characters turn for bonus points.
If you want to make number 1 with yanfly plugins, it's (add your fireId and stateId):

<Custom Respond Effect> if (this.isPhysical() || this.item().damage.elementId == fireId) { target.removeState(stateId); } </Custom Respond Effect>
If you want to make number 1 with yanfly plugins, it's (add your fireId and stateId):

<Custom Respond Effect> if (this.isPhysical() || this.item().damage.elementId == fireId) { target.removeState(stateId); } </Custom Respond Effect>
Yesssshhh, thanks mi lord, gonna add this to the base freeze effect!, thanks you'
Cool. For number 2 I think you can add with the above respond effect also a react effect:

<Custom React Effect> target.result().critical = true; value = this.applyCritical(value); </Custom React Effect>
Ancient can be done with buffs & states, but how closely you want to follow it changes things. you can have a set of 11 states for the base, +20% atk, +40% atk, +60% atk and so on, and have each of them do something like this to make it so that you get the next stage when the actor gets hit

Code:
<Custom React Effect>
target.removeState(stateId);
target.addState(stateId+1);
</Custom React Effect>

and have the 200% apply the base once again with an additional
Code:
target.gainMp(target.mmp);
thrown in.
It could be made into one stacking state, however doing so would afaik would need the actual effect to change from adding +20% atk per stack to increasing damage dealt by 20% per stack since you cant directly edit the parameters from the notetags. if you want that instead i can write it up

Marzex as i see it would have to be 4 states. one main one that checks after taking a hit if the target was knocked below 50% to trigger the others, and all the other effects since they have different durations
Code:
//Marzek
<Custom Deselect Effect>
if (target.hpRate() < .5){
target.friendsUnit().aliveMembers().forEach(member => member.addState(MARZEK SHIELD));
target.addState(MARZEK REGEN);
target.addState(MARZEK STUN);
target.removeState(stateId);
}
</Custom Deselect Effect>
Code:
//Marzek Shield
<Custom Apply Effect>
user._shield = user.mmp*.4;
</Custom Apply Effect>

<Custom React Effect>
if (this.isDamage()) {
 if(value >= target._shield){
  value = value - target._shield;
  target._shield = 0;
}
 else{
  target._shield = target._shield - value;
  value = 0;
 }
}
if (target._shield <= 0) {
  target.removeState(stateId);
}
</Custom React Effect>
the regen can be the editor's default 10% hp recovery for 2 turns and the stun can just be restriction: cannot move for 5 turns. Do test these first. I havent.
om
Ancient can be done with buffs & states, but how closely you want to follow it changes things. you can have a set of 11 states for the base, +20% atk, +40% atk, +60% atk and so on, and have each of them do something like this to make it so that you get the next stage when the actor gets hit

Code:
<Custom React Effect>
target.removeState(stateId);
target.addState(stateId+1);
</Custom React Effect>

and have the 200% apply the base once again with an additional
Code:
target.gainMp(target.mmp);
thrown in.
It could be made into one stacking state, however doing so would afaik would need the actual effect to change from adding +20% atk per stack to increasing damage dealt by 20% per stack since you cant directly edit the parameters from the notetags. if you want that instead i can write it up

Marzex as i see it would have to be 4 states. one main one that checks after taking a hit if the target was knocked below 50% to trigger the others, and all the other effects since they have different durations
Code:
//Marzek
<Custom Deselect Effect>
if (target.hpRate() < .5){
target.friendsUnit().aliveMembers().forEach(member => member.addState(MARZEK SHIELD));
target.addState(MARZEK REGEN);
target.addState(MARZEK STUN);
target.removeState(stateId);
}
</Custom Deselect Effect>
Code:
//Marzek Shield
<Custom Apply Effect>
user._shield = user.mmp*.4;
</Custom Apply Effect>

<Custom React Effect>
if (this.isDamage()) {
 if(value >= target._shield){
  value = value - target._shield;
  target._shield = 0;
}
 else{
  target._shield = target._shield - value;
  value = 0;
 }
}
if (target._shield <= 0) {
  target.removeState(stateId);
}
</Custom React Effect>
the regen can be the editor's default 10% hp recovery for 2 turns and the stun can just be restriction: cannot move for 5 turns. Do test these first. I havent.
omg, THANKS SO MUCHHHHH, defintley going to check it out, again thanks
Cool. For number 2 I think you can add with the above respond effect also a react effect:

<Custom React Effect> target.result().critical = true; value = this.applyCritical(value); </Custom React Effect>
should i add it to the base ultima freeze code or have it 2 seperate codes on the same state
I think those 2 separate should work. Maybe you could combine them, but I don't feel like thinking about that, LOL.
I think those 2 separate should work. Maybe you could combine them, but I don't feel like thinking about that, LOL.
XD fair enough, thanks tho broaski
Hi guys i want to make a passive that increases basic attack damag every time its used consecutively in a battle?
Hi guys i want to make a passive that increases basic attack damag every time its used consecutively in a battle?
JavaScript:
<Custom Action Start Effect>
if (user.currentAction().isAttack()) user._concMod = user._concMod + 0.1 || 1;
else delete user._concMod;
</Custom Action Start Effect>

<Custom Confirm Effect>
if (user._concMod && this.isAttack()) value = Math.ceil(value * user._concMod);
</Custom Confirm Effect>

<Custom Remove Effect>
if (user._concMod) delete user._concMod;
</Custom Remove Effect>
just change the +0.1 in the 2nd line to whatever you want your consecutive bonus to be
JavaScript:
<Custom Action Start Effect>
if (user.currentAction().isAttack()) user._concMod = user._concMod + 0.1 || 1;
else delete user._concMod;
</Custom Action Start Effect>

<Custom Confirm Effect>
if (user._concMod && this.isAttack()) value = Math.ceil(value * user._concMod);
</Custom Confirm Effect>

<Custom Remove Effect>
if (user._concMod) delete user._concMod;
</Custom Remove Effect>
just change the +0.1 in the 2nd line to whatever you want your consecutive bonus to be
yesshhh thanks so much robro, used it and it works perfectly
yesshhh thanks so much robro, used it and it works perfectly
i just looked at the edit to the first post. its not 1:1 but its easy enough to add the cap and the state at 10 stacks.

the phoenix state is simple since youre already using the passive plugin.

you'd have a passive with this:
Code:
//best to not make this visible. all it does is ensure the battler gets a reraise
<Custom Battle Effect>
user.addState(RERAISE);
</Custom Battle Effect>

and then have your reraise state be this (mostly taken from yanfly's autolife tip linked earlier by Harlekin)
Code:
//reraise
<Category: Bypass Death Removal>
<Custom Deselect Effect>
if (target.hp <= 0 || target.isDead()) {
  target.removeState(stateId);
  target.gainHp(1);
  target.addState(REGEN);
}
</Custom Deselect Effect>
and your regen state be this:
Code:
//regen
<Custom Regenerate Effect>
var hpTickRate = Math.round(Math.random() * 10)+10;
user.gainHp(Math.ceil(user.mhp*hpTickRate/100));
</Custom Regenerate Effect>
i just looked at the edit to the first post. its not 1:1 but its easy enough to add the cap and the state at 10 stacks.

the phoenix state is simple since youre already using the passive plugin.

you'd have a passive with this:
Code:
//best to not make this visible. all it does is ensure the battler gets a reraise
<Custom Battle Effect>
user.addState(RERAISE);
</Custom Battle Effect>

and then have your reraise state be this (mostly taken from yanfly's autolife tip linked earlier by Harlekin)
Code:
//reraise
<Category: Bypass Death Removal>
<Custom Deselect Effect>
if (target.hp <= 0 || target.isDead()) {
  target.removeState(stateId);
  target.gainHp(1);
  target.addState(REGEN);
}
</Custom Deselect Effect>
and your regen state be this:
Code:
//regen
<Custom Regenerate Effect>
var hpTickRate = Math.round(Math.random() * 10)+10;
user.gainHp(Math.ceil(user.mhp*hpTickRate/100));
</Custom Regenerate Effect>
oooh perfectoo' you've been such a big halp thanks so much, i just have a question about ancient though, is it 2 sepearate states or one single one?
i just have a question about ancient though, is it 2 sepearate states or one single one?
its actually 11 near-identical states. its a little awkward because each stack is supposed to increase atk by 20%, but atk isnt easily changed through notetags alone. 11 states in total, one for each stack of +20% atk. Each one makes it so that when the battler with the state is hit it triggers the next one, with the last one applying the first one and having the gainMp() tossed in.

its why i had mentioned the alternative of making it just increase the damage instead of the atk of the battler. it can be made into one short state that way instead of 11

Original thread: https://forums.rpgmakerweb.com/threads/status-condition-help-thread.161208/