Scriptcall to check if damage is Magical

Status
Not open for further replies.

Fernyfer775

Veteran
Veteran
Joined
Oct 6, 2013
Messages
1,317
Reaction score
818
First Language
English
I dug around some of his other plugins and found the code myself. If a mod sees this, please feel free to close this thread, thank you! :D


Hello all. How would i do a scriptcall/conditional to check to see if damage being taken is MAGICAL?


I am currently using Yanfly's plugin to recreate his "Stagger" tips and tricks (linked at the bottom of the post), but from what I see, it only works on Physical damage taken.


The spoiler shows the code. How do i get it to work on BOTH physical AND magical damage?

<Custom React Effect>


if (this.isPhysical() && this.isHpEffect() && value > 0) {


target._staggerDmg = target._staggerDmg || 0;


var reduce = Math.ceil(value * 0.35);


value -= reduce;


target.addState(142);


target._staggerDmg += reduce;


}


</Custom React Effect>
 
Last edited by a moderator:

Kes

Veteran
Veteran
Joined
Aug 3, 2012
Messages
22,299
Reaction score
11,712
First Language
English
Primarily Uses
RMVXA
This thread is being closed, due to being solved. If for some reason you would like this thread re-opened, please report this post and leave a message why. Thank you.



@Fernyfer775 It's usually better to Report your opening post and ask for the thread to be closed.  It's easy to miss a post, but we will see your Report.  Thanks.
 
Status
Not open for further replies.

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

Latest Threads

Latest Posts

Latest Profile Posts

How many parameters is 'too many'??
Yay, now back in action Happy Christmas time, coming back!






Back in action to develop the indie game that has been long overdue... Final Fallacy. A game that keeps on giving! The development never ends as the developer thinks to be the smart cookie by coming back and beginning by saying... "Oh bother, this indie game has been long overdue..." How could one resist such? No-one c
So I was playing with filters and this looked interesting...

Versus the normal look...

Kind of gives a very different feel. :LZSexcite:
To whom ever person or persons who re-did the DS/DS+ asset packs for MV (as in, they are all 48x48, and not just x2 the pixel scale) .... THANK-YOU!!!!!!!!! XwwwwX

Forum statistics

Threads
105,853
Messages
1,016,986
Members
137,561
Latest member
visploo100
Top