How to check the stats of party members?
I mean, how to check ATK of ANY active party member in conditional branch?
I mean, how to check ATK of ANY active party member in conditional branch?
$gameParty.members()[index].atk
// Note that you'll have to replace "index" by the index of the party member you want to access.
For example, "if at least one of party members has ATK more or equals 60"
var check = false;
for (var = i ; i < $gameParty.members().length; i++) {
var pm = $gameParty.members()[i];
if (pm.atk >= 60) {
check = true;
break;
}
}
$gameSwitches.setValue(1, check);
Okay.
$gameParty.members().some(function (m) { return m.actor().atk >= 20; })
$gameParty.members().some(actor => actor.atk >= 20)
Thank you.
Original thread: https://forums.rpgmakerweb.com/threads/partys-stat-check-script.109138/