Poupouille

Veteran
Veteran
Joined
Mar 1, 2017
Messages
179
Reaction score
32
First Language
French
Primarily Uses
RMMV
Hello,

For a particular boss in my game, I would like regenerate his HP if the player uses the poison on him (heal the boss + a random message in the dialog box "oh, he can cure himself with poison")
But I couldn't set this up, as simple as it sounds.
If you can illustrate the configuration with a screenshot, that would be nice.

Thank you!!!
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
37,041
Reaction score
10,041
First Language
German
Primarily Uses
RMMV
that is NOT easy to setup, because there is no direct poison in the engine.
poison is setup as a state with negative regeneration, and all regeneration is simply added together.

you have two options to proceed here: either you use a plugin to handle the poison state differently, or you trick the player with two different poison states.

Basically you make a regular poison state with negative regeneration, and a fake poison state with positive regeneration. then you make all enemies other than the boss immune to the fake poison state, and the boss immune to the regular poison state. the actors should also be immune to the fake poison state.

and then every skill or item that can apply poison tries to apply both versions, with the true poison sticking to regular targets and the fake poison sticking to the boss on those skills and items.
 
  • Like
Reactions: Bex

udime123

[C]reator of Axial
Veteran
Joined
Mar 29, 2018
Messages
111
Reaction score
24
First Language
English
Primarily Uses
RMMV
Like Andar said, this is a tricky one without plugins. The method listed should work fine, although it sounds a little clunky since it means making every entity (enemy or actor) aside from this one boss immune to the regenerating state. With Yanfly plugins it sounds like it could be a little cleaner, though it's up to you what you'd prefer to try.

Using EX Dot and Element Core, you could set the poison dot to have an element that is absorbed by the boss. I haven't tested this, but it should theoretically cause the boss to be healed by the damage. Another option could be using Buffs/States Core to remove the damaging Poison and replace it with an identical healing Poison effect. This would require Javascript shenanigans, but I like this method a bit better because
A. I definitely know this method works and
B. You probably won't be getting that dialogue box there without using Reaction Effects anyway.

So I guess for this, I would set up Buffs/States Core, then add the following notetag to the poison state:

Code:
  <Custom Apply Effect>
if (user.enemyId() === X)
{
user.removeState(Y);
user.addState(Z);
}
  </Custom Apply Effect>

X is your boss's Enemy ID, Y is the damaging poison state, Z is the regenerating poison state.

Again, the double-state effect should work, it just sounds a little messier than I typically prefer haha

EDIT: I just remembered you can use Troop tags to check if an enemy has a given state. *headbonk*
Given that knowledge, using JS to make the textbox would be pretty inefficient, although I still think the rest of this is still preferred for me personally.
 

Aphotic

Veteran
Veteran
Joined
Feb 19, 2019
Messages
54
Reaction score
32
First Language
English
Primarily Uses
RMMV
Hello,

For a particular boss in my game, I would like regenerate his HP if the player uses the poison on him (heal the boss + a random message in the dialog box "oh, he can cure himself with poison")
But I couldn't set this up, as simple as it sounds.
If you can illustrate the configuration with a screenshot, that would be nice.

Thank you!!!
Use Yanfly's Auto Passive States to make a State, name it like "Absorb Poison" or something like that, and make it a passive state in the enemy's notes. It needs no actual effects, descriptions, or icons, just leave it blank other than the name so you know which one it is.

Create an if statement in the actual Poison state itself that checks for this passive state. If true, poison would heal whoever has the state, if false -- which would be the standard -- poison would cause damage.

Code:
<Custom Regenerate Effect>

\\we make a value representing 10% 'regen'
var p = (user.mhp * .1);
\\x is the passive state
\\if the affected target (user in states) has the
\\passive state, they are healed for the regen variable
if (user.isStateAffected(x)) {
user.gainHp(p)
} else {
\\otherwise they are damaged for the regen variable
user.gainHp(p * -1)
}

</Custom Regenerate Effect>


The benefit to doing it this way is that it's very compact and can be used in more than one situation without additional work if it's something you wanted to recycle later on. This would essentially implement a "Poison Heal" type mechanic from Pokemon with minimal work.

In terms of the message, as long as he's the first instance of this mechanic, you can just include it in his encounter event.
 
Last edited:

Latest Threads

Latest Posts

Latest Profile Posts

New sprites & animations for Mint and Beri are coming along!
Guh-Colorbound.gif
ScreenShot_10_5_2022_4_44_8.png
Mad O' Malley... a stick figure that's afraid of it's existence being erased. so they always start battle in an anxious state.
Before, I was drawing all the sprite work, super big and shrinking it down. Which was really time consuming if thing's changed. So instead I'm drawing the characters sketch, and then remaking it with pixel art instead.
Why are job interviews so terrifying. :kaodes:

Forum statistics

Threads
125,801
Messages
1,173,666
Members
164,964
Latest member
oliveleaf
Top