Pokémon SDK Wiki
Credits

Start a wild battle

This page comes from the old Wiki. It's probably not up to date.

Start a simple wild battle

To start a wild battle, just call the command : call_battle_wild(id_pokemon, level)

Example :

call_battle_wild(:pikachu, 5)

(Use the List of Pokémon to find the correct Pokémon ID)

Start double wild battle

It's possible to start a 2v2 wild battle using the following command : call_battle_wild(id_pokemon1, level1, id_pokemon2, level2)

Example :

call_battle_wild(:pikachu, 5, :meowth, 5)

Start a wild battle against a specific Pokémon

You can generate a Pokemon using the following command :

pokemon = PFM::Pokemon.generate_from_hash(id: id_pokemon, level: level_pokemon)

The various parameter of the command (aside id & level) are :

Use case :

1v1 against Cosplayer Pikachu :

pokemon = PFM::Pokemon.generate_from_hash(id: 25, level: 5, form: 2, gender: 2)
call_battle_wild(pokemon, nil)

2v2 against two Cosplayer Pikachu :

pokemon1 = PFM::Pokemon.generate_from_hash(id: 25, level: 5, form: 2, gender: 2)
pokemon2 = PFM::Pokemon.generate_from_hash(id: 25, level: 5, form: 5, gender: 2)
call_battle_wild(pokemon1, nil, pokemon2)