Hi everyone!
Currently, I'm trying to create a script inside a common event that will be called in battle.
The script inside the common event needs to identify the currently selected target by the actor, as the common event is called using the Skill after it is selected on a target by the player.
For instance, the player has chosen for Actor 1 to use "Sneeze". They have then selected their enemy target (it is a single target skill) and confirmed. When the skill is executed, it calls a common event with the script inside.
I want this script, with everything it does, to reference the selected enemy by storing that index number in a variable.
I expect the line to be something like:
$gameTroop.members()[this._gameTroop.membersId] - but I know that is unsightly, garbled and wrong.
Currently, I'm trying to create a script inside a common event that will be called in battle.
The script inside the common event needs to identify the currently selected target by the actor, as the common event is called using the Skill after it is selected on a target by the player.
For instance, the player has chosen for Actor 1 to use "Sneeze". They have then selected their enemy target (it is a single target skill) and confirmed. When the skill is executed, it calls a common event with the script inside.
I want this script, with everything it does, to reference the selected enemy by storing that index number in a variable.
I expect the line to be something like:
$gameTroop.members()[this._gameTroop.membersId] - but I know that is unsightly, garbled and wrong.