Skip to main content

(267) _POKELIST_GET_RESULT

Effect

Used in tandem with the _POKELIST_SET_PROC command.

Returns the values of which box the selected Pokémon is in and the position within that box.

info

The selected Pokémon comes from the _POKELIST_SET_PROC command.

Syntax

_POKELIST_GET_RESULT(index, box_index)
ArgumentDescriptionTypesRequired
indexThe position that the selected Pokémon is in the box. Returns -1 if no Pokémon is chosenWork, IntRequired
box_indexThe box that the selected Pokémon is in (party is -1)Work, IntRequired

Example

_POKELIST_SET_PROC(1)
_POKELIST_GET_RESULT(@LOCALWORK2, @LOCALWORK3)
_IFVAL_JUMP(@LOCALWORK2, 'EQ', -1, 'dummy_no_pokemon_selected')

The above script will open the PC UI window and highlight every Pokémon according to the value set in _POKELIST_SET_PROC. In this example, that means every pokemon that isn't in your party will be highlighted.

info

A list of which Pokémon are highlighted for each index can be found here.

If the player decides not to choose a Pokémon, the @LOCALWORK2 will return -1 which will then redirect the player to the dummy_no_pokemon_selected script.