Call on number of states affecting target?

phasmo

Villager
Member
Joined
May 27, 2020
Messages
5
Reaction score
2
First Language
English
Primarily Uses
RMMV
Hello! I'm trying to make a skill that does more damage with the more states are currently affecting a target.
I don't mean if the target is affected by a specific state, just want to call the number of states currently applied.

I've tried for example
a.mat * b.states.size

But this doesn't work.
Thanks!
 

Dopan

Veteran
Veteran
Joined
Mar 27, 2020
Messages
493
Reaction score
222
First Language
German
Primarily Uses
RMMV
Hello! I'm trying to make a skill that does more damage with the more states are currently affecting a target.
I don't mean if the target is affected by a specific state, just want to call the number of states currently applied.

I've tried for example
a.mat * b.states.size

But this doesn't work.
Thanks!
try "states().length" (instead of "states.size")
JavaScript:
$gameActors.actor(1).states().length;
// returns the Amount of States Affected on Actor ID 1
"$gameActors.actor(1)." can be replaced with any other valid Character.. (for example " $gameParty.leader(). " ect)
Also in some Cases with "a." or "b."..
(in most Cases "a. = user" & "b. = target" ... and i think this counts as Character in SkillDMGFormulas for Example.. also in other Yep Stuff)
 
Last edited:

phasmo

Villager
Member
Joined
May 27, 2020
Messages
5
Reaction score
2
First Language
English
Primarily Uses
RMMV
try "states().length" (not size)
JavaScript:
$gameActors.actor(1).states().length;
// returns the Amount of States Affected on Actor ID 1
$gameActors.actor(1) can be replaced with any other valid Character.. (for example " $gameParty.leader() " ect)
Also in some Cases with "a." ..
(in most Cases "a. = user" & "b. = target" ... and i think this counts as Character in SkillDMGFormulas for Example.. also in other Yep Stuff)
b.states().length worked perfectly, thank you so much!
 

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

Latest Threads

Latest Profile Posts

All of the auditions for our game are so good, I'm so glad I'm not in charge of choosing completely. lol I just can't with some of them. I listen to them on repeat. XD
Working on a Patch to integrate AlphaABS into random generated Dungeons. Was a bit tricky, but the outcome is a real Life Changer!!

Will release it the next days!
Been pretty busy... but I got a better headset for recording and listening today. Dad says that he'll consider taking me to Great Wolf Lodge for the first time once I finish summer classes (my final semester!) I'll be taking my plushie friends with me: Bendy, Lolbit, and Helen Henny. (I WUV PLUSHIES!)
SF_Monster3,4 added!


My only regret is the portal mirror effect is too subtle to show up in these GIFs. It probably just needs more sparkles. :LZSwink:

Forum statistics

Threads
105,650
Messages
1,015,290
Members
137,327
Latest member
Mezzy
Top