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
495
Reaction score
225
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 Posts

Latest Profile Posts

Evil7 added!


I did a bit of a remake on one of the maps, also I made a particle for jumping into the portal, and one for traveling through the portal. I'll probably add more sparkles later to embellish it. :LZSwink:
Polished the animation and added details :kaojoy:
Ami
What do you think about the Wood Bridge inside of Volcano?
Yet another gaming question, i'm currently playing Last of Us 2 and want to get another game to play next but can't decide between Ghost of Tsushima, Miles Morales & Jedi Fallen Order. After the latest mandalorian i AM on a star wars kick, but i also LOVED the last spiderman game that prequels Miles Morales. Ghost of Tsushima is the bottom of my list but i heard it was AWESOME. Just want a good story & fun gameplay.

Forum statistics

Threads
105,685
Messages
1,015,528
Members
137,362
Latest member
sdramose
Top