Some problems with status ailments in ABS Chrono engine

Hello, i remember doing a similar threat like this some time ago, but with other issue. Here i want to ask a few things to fix some issues i have with status ailments in Chrono engine.

First, the duration of the ailments isn´t correct. I want poison, for example, to last 30 turns, or deal damage 30 times, however, when the player get poisoned, it only works good if the player stand still, if the player moves the poison doesn´t deal damage at the same pace (and also doesn´t show the number with the damage), and also removes way faster than usual. And when enemies are poisoned, the poison only deal damage 8 times, when it should be 30. (Something weird is this last thing only happens in a future project i want to make, in my corrent one it doesn´t, i don´t know why).


Captura de pantalla 2023-12-31 181229.png


Captura de pantalla 2023-12-31 181248.png


I have the switch constanly on, so the command event works.
That's a script I wrote to force "turns" to pass in ABS mode once per second so that the status effects would work in ABS mode. I don't see anything that would make it only hit 8 times.

Are you sure the enemies aren't taking damage but the damage popup just doesn't show? The popup is a bug with one of the Moghunter plugins where it just doesn't show when the player or event is moving.

It could also be the enemies are at 1 HP when it stops and the poison isn't killing them. I would try changing your .003 +12 damage formula because that's not what I originally had, you changed that.

The last thing I would check is what's turning on and off your "enemies poisoned" switch. Just so you know, that script is to track ALL buffs, debuffs, and statuses for everyone on the map, not just one enemy. If you're turning it on and off based on one enemy it will turn it off for everyone.
That's a script I wrote to force "turns" to pass in ABS mode once per second so that the status effects would work in ABS mode. I don't see anything that would make it only hit 8 times.

Are you sure the enemies aren't taking damage but the damage popup just doesn't show? The popup is a bug with one of the Moghunter plugins where it just doesn't show when the player or event is moving.

It could also be the enemies are at 1 HP when it stops and the poison isn't killing them. I would try changing your .003 +12 damage formula because that's not what I originally had, you changed that.

The last thing I would check is what's turning on and off your "enemies poisoned" switch. Just so you know, that script is to track ALL buffs, debuffs, and statuses for everyone on the map, not just one enemy. If you're turning it on and off based on one enemy it will turn it off for everyone.
Like i said, that only happens in the future project, in the current one it doesn´t, i don´t know what is different.

What happen is that the poison goes away sooner. And that bug not only doesn´t show the number, also the poison goes away sooner too. (Funny enough, i put the number of turns of the poison in 120 and actually deal damage 30 times, it seems that for whatever reason, is only counting a quarter of the turns).

That doesn´t matter, i put the original formula and the poison still last only 8 "turns". (That formula means they take 0.3% + 12 points of flat damage, so they die anyways).

I originally made two separate switches, one for the player, and other for the enemies, but in the end i put both in the same switch, i just forgot to change the name.

Other thing that i forgot is if the enemy dies from poison, the level up animation plays, even when you don´t level up.

Could you show me how you have the plugins? Maybe is some plugin screwing up something.

Update: I kinda fixed? With the enemies i put the state in 120 turns, so they take damage 30 times, and with the player i put it in 255 turns. If the player is constantly moving after being poisoned, the poison deal damage 30 times approximately (maybe 31 or 32 depending if the player has stopped moving for a second or not). I would still look for a better solution.
Press F8 to see if there's any error in the console log and F9 to see if your switch 13 is on when it stops. Also check what you have for States Duration for the ChronoEngine plugin in the Plugin Manager
Press F8 to see if there's any error in the console log and F9 to see if your switch 13 is on when it stops. Also check what you have for States Duration for the ChronoEngine plugin in the Plugin Manager
It doesn´t show nothing out of the ordinary, and the switch is on. The state duration is 480 too.

Also i fixed a small error in the code, in this part.

player = $gameMap.players()[0].battler();
if(player.isStateAffected(11)){player.gainHp(-Math.floor(player.mhp*0.003 + 12));}
player.startDamagePopup();
player.updateStateTurns(); player.updateBuffTurns();
player.removeStatesAuto(1); player.removeStatesAuto(2);

When you made the code, in the part where you specify the damage, you put battler.mhp. Yesterday i was testing the damage of the poison, and it was always the same. So i changed "battler" for "player" and now the damage was for the player max hp. I don´t know who´s hp was using the formula for the damage, but now uses the player´s hp instead.
Also i fixed a small error in the code, in this part.

When you made the code, in the part where you specify the damage, you put battler.mhp. Yesterday i was testing the damage of the poison, and it was always the same. So i changed "battler" for "player" and now the damage was for the player max hp. I don´t know who´s hp was using the formula for the damage, but now uses the player´s hp instead.
I don't know if that was my mistake or not because my current copy has player.mhp, but maybe I gave you an older version that had battler.mhp. The battler.mhp would be the max HP of the last enemy event checked. You could check who that is by typing $gameMap.allEnemiesOnMap() in the console and finding the last entry

If you only have one player character on the map, as opposed to a party, you can change
player = $gameMap.players()[0].battler();
to
player = $gamePlayer.battler()

I don't know if that would make any difference or not.
I don't know if that was my mistake or not because my current copy has player.mhp, but maybe I gave you an older version that had battler.mhp. The battler.mhp would be the max HP of the last enemy event checked. You could check who that is by typing $gameMap.allEnemiesOnMap() in the console and finding the last entry

If you only have one player character on the map, as opposed to a party, you can change
player = $gameMap.players()[0].battler();
to
player = $gamePlayer.battler()

I don't know if that would make any difference or not.
Yeah, maybe i took an older version.

I only have one player character in map, and i changed the code, but it does the same. You don´t know a way to fix the problem with the number not showing up and the ailment going away faster? (And also what i commented about the level up animation playing when the enemy dies from poison, even when the player don´t level up).
Do you have any other parallel events happening at the same time? Could you try adding wait commands to the end of them?
Do you have any other parallel events happening at the same time? Could you try adding wait commands to the end of them?
Other parallel events could cause problems to that one?

When you say wait commands, you mean the wait for frames ones, right? The one that have 60 frames default. If is it, yes.
Multiple parallel events can cause the game to lag and theoretically functions might not fire if the processor is busy with some other process. You use the wait command at the end of parallel processes to reduce how often that process is firing off. In most cases whatever it is doesn't need to happen 60 times a second, which is the default.
Multiple parallel events can cause the game to lag and theoretically functions might not fire if the processor is busy with some other process. You use the wait command at the end of parallel processes to reduce how often that process is firing off. In most cases whatever it is doesn't need to happen 60 times a second, which is the default.
I did some experimentation in my future project, because there i have three different damaging status ailments. Then i made sure the enemy have the three of them damaging it at the same time. And i saw something interesting. There three were dealing damage at the same time, and the three did it 30 times, but it only show the biggest number, no matter the order i applied the ailments, so the game seems to priorize the biggest number (the three have the 60 frames wait, probably if i would put different frames, the numbers of the three would show up). But like i said, they three worked fine at the same time.

Also, in one moment i removed the wait command in the poison parallel event and the HP of the character dissapeared in an instant, killing it in less of one second. So i suppose the parallel event was applying over and over at super fast speed.
Also, in one moment i removed the wait command in the poison parallel event and the HP of the character dissapeared in an instant, killing it in less of one second. So i suppose the parallel event was applying over and over at super fast speed.
Yes, by default whatever script is in that parallel event will run 60 times a second. I put a wait of 60 frames at the end so that it would wait 60 frames (1/60th of a second each) before happening again. If you remove that wait command it will do the poison damage 60 times a second and kill the enemy super fast. It can also lag the game running code that often.
Yes, by default whatever script is in that parallel event will run 60 times a second. I put a wait of 60 frames at the end so that it would wait 60 frames (1/60th of a second each) before happening again. If you remove that wait command it will do the poison damage 60 times a second and kill the enemy super fast. It can also lag the game running code that often.
I don't have time to see if the game lag or not when it kills me so fast, but maybe i could do it with enemies, but that is not really the point.

I mean, creating a separate poison status ailment, that only the player can suffer, and lasting 120 turns makes if the player is constantly moving when is poisoned, the poison damages him/her aproximately 30 times, but if the player stay still will do it 120 times instead. And i still i don't know why that happen only with the player, because the enemies can be moving constantly and they take the damage in the intended way. Maybe is because the player's and enemies' codes are different?
Are you sure the player is not taking damage when moving? Just because the popup doesn't display the damage doesn't mean the player isn't taking damage. Could you enable the MOG actor HUD and make it show the player HP on the screen?
Are you sure the player is not taking damage when moving? Just because the popup doesn't display the damage doesn't mean the player isn't taking damage. Could you enable the MOG actor HUD and make it show the player HP on the screen?
The player takes damage, the only thing is the number doesn't display and the poison goes away faster, but the player takes the damage.
The player takes damage, the only thing is the number doesn't display and the poison goes away faster, but the player takes the damage.
Ok, that is not an issue with this script, it's an issue with one of Mog's plugins, probably the damage popup one.
Ok, that is not an issue with this script, it's an issue with one of Mog's plugins, probably the damage popup one.
You talk about Mog_DmgPopupEffects?
You talk about Mog_DmgPopupEffects?
I don't know what it's called. I'm on my phone so I can't check. But I know it's an issue because it happens regardless of what's doing the damage.

Original thread: https://forums.rpgmakerweb.com/threads/some-problems-with-status-ailments-in-abs-chrono-engine.164319/