ASUG0

Annihilation Special Unit Generation 0
Veteran
Joined
Jul 16, 2020
Messages
48
Reaction score
11
First Language
German
Primarily Uses
RMMV
Hi,
I wanted to ask how I can check the TP value of an enemy in battle.
My idea was to use this line of code:
if ($gameTroop.members()[1].tp > 49) {$gameVariables.setValue(62, 1);}

But it didn't work! pls help

thanks ^^


Edit: solved it myself
 
Last edited:

Soulrender

Jack Of All Trades
Veteran
Joined
Jan 12, 2019
Messages
1,111
Reaction score
642
First Language
Poland
Primarily Uses
RMMV
Probably because you aim for wrong troop member, keep in mind, that index 0 refers to first troop in group, so if you have 3 enemies in group, first one will have index 0 and the last one 2

Try $gameTroop.members()[0].tp

See in this pic? https://prnt.sc/15x47en
There is only one orc and by index 0 I can obtain TP, but with index 1 there is an error because he's alone in battle
 

ASUG0

Annihilation Special Unit Generation 0
Veteran
Joined
Jul 16, 2020
Messages
48
Reaction score
11
First Language
German
Primarily Uses
RMMV
Probably because you aim for wrong troop member, keep in mind, that index 0 refers to first troop in group, so if you have 3 enemies in group, first one will have index 0 and the last one 2

Try $gameTroop.members()[0].tp

See in this pic? https://prnt.sc/15x47en
There is only one orc and by index 0 I can obtain TP, but with index 1 there is an error because he's alone in battle
thank you for your replay ^^
 
Last edited:

Latest Threads

Latest Profile Posts

I have made 60 new skills! ''after test'' I have made 3 new skills!

Made a new battleback this week! How's it look?
"This is the real secret to life - To be completely engaged with what you are doing in the here and now. And instead of calling it work, realize it is play."
Me: "I don't to use other engines because I'd have to do a lot of coding."

Also my desktop right now....
mycurrentdesktop.jpg

...I literally spend more time using VS Code than MZ. :kaoswt:
actually, are there any JRPG type games (I guess turn based, so not ARPGs like say, Vagrant Story) where you have only one party member for the majority of the game? (I wonder if I'm forgetting something obvious.)

Forum statistics

Threads
113,809
Messages
1,077,640
Members
147,865
Latest member
raw2na
Top