For an event, i wanted to save the ID of any party member that has a certain skill to a variable. However, it just sets it to "0".
Here's what I tried so far:
Neither of these sets the variable to anything above 0.
Here's what I tried so far:
JavaScript:
$gameParty.members().forEach(function(actor) { if (actor.hasSkill(12)) { return actor; } } )
$gameParty.members().forEach(function(actor) { if (actor.hasSkill(12)) { return actor.actorId(); } } )
$gameParty.members().forEach(function(actor) { return actor.actorId() && actor.hasSkill(12); })
Neither of these sets the variable to anything above 0.