Bypass 100% Remove by damage states (I.e. Sleep) taken off upon hit.

atoms

Veteran
Veteran
Joined
May 31, 2013
Messages
495
Reaction score
295
First Language
English
Primarily Uses
RMMV
I hope this isn't a very complex request, but basically a plugin where if a state that usually gets taken off upon it, let's say a 100% Remove by Damage Sleep State usually gets taken off, well certain skills will bypass it and won't remove the state.

The only condition is, I'd like the Plugin to work with Yanfly Plugins.

I can achieve what I want through making all skills remove Sleep except the ones I want to bypass, so I don't need this plugin now, but I think a plugin like this could still be useful, and is a better method then that.

So, for that reason, I thought, whether it happens or not, there isn't any harm in requesting it.

Thanks for listening to the request! : )
 

ShadowDragon

Veteran
Veteran
Joined
Oct 8, 2018
Messages
1,719
Reaction score
568
First Language
Dutch
Primarily Uses
RMMV
it can be done with yanfly stateand buff plugin, but you might need state category plugin as well because if im recall correcly, it can bypass
some states you want, but it require lunatic code :)
 

Tiamat-86

old jrpg gamer
Veteran
Joined
Dec 5, 2017
Messages
356
Reaction score
139
First Language
english
Primarily Uses
RMMV
if (b.isStateAffected(X)) b.addState(X); formula
damage formula checks if they are sleeping. if so it reapplies sleep as it hits so they stay sleeping. otherwise it just does a normal hit
 

atoms

Veteran
Veteran
Joined
May 31, 2013
Messages
495
Reaction score
295
First Language
English
Primarily Uses
RMMV
@Tiamat-86

I tried if (b.isStateAffected(10)) b.addState(10); a.atk * 4 - b.def * 2

and
if (b.isStateAffected(10)) b.addState(10);a.atk * 4 - b.def * 2

in Battle Test.

They didn't reapply the Sleep State (which was ID 0010). I'm sure there is a damage formula close to that would actually do it, however still it wouldn't really bypass the state, just take it off and on. Visually, you'd see that happen too.


@ShadowDragon I thought that much would be true, my problem is, if it does work, I don't know the lunatic code to put in. But thanks.
 

caethyril

^_^
Veteran
Joined
Feb 21, 2018
Messages
1,552
Reaction score
1,028
First Language
EN
Primarily Uses
RMMV
States are removed after the damage is applied, which occurs after the damage formula has been evaluated, hence no dice with that. Also, simply reapplying the state would also reset the state's turn count unless you had some extra code to remember/reset that. :kaoswt:

So, I wrote this li'l plugin: Cae_StateControl.
Then let's say you have a skill that shouldn't remove state 10 on damage: just add a notetag to that skill~
Code:
<Ignore State Damage Remove: 10>
Should be compatible with most stuff that doesn't entirely overhaul the flow of damage. All it does is temporarily change the remove chance to 0 for relevant states (and resets it after the "remove by damage" check has completed). :kaothx:
 

atoms

Veteran
Veteran
Joined
May 31, 2013
Messages
495
Reaction score
295
First Language
English
Primarily Uses
RMMV
@caethyril I'm sorry I took so long to respond, but thank you for this! I hope more people can find more use for it too, thanks!
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Posts

Latest Profile Posts

The more I think about it, the weirdest part of going to work post-virus will probably be getting used to seeing my coworkers' mouths again. :LZYshock:
I think one of my weirdest realizations is that my speed of game development would probably be about the same if I *didn't* work a full-time manual labor job.
Quick question, what's the best way to capture-er, I mean RECRUIT playtesters? Should I make a project thread and use that?
Node Graph out of Date. Rebuilding...
Does anyone know of any good Discord groups for art or biology discussion, that sort of thing?

Forum statistics

Threads
98,056
Messages
948,945
Members
129,333
Latest member
rootcf
Top