Quote:
Originally Posted by DeathOrDoom0
If the player controls the NPC that would work
|
In this case you can do something like the following (in a script)
1. save the player's pokemon data somewhere (free ram, see FBI's
portable storage system for example)
2. give the player the NPC's pokemon (givepokemon should work)
3. swap the player's battle backsprite with the NPCs (use JPANs engine or
this routine)
4. initiate the trainer battle
5. after the battle, delete the given pokemon (JPANs engine special or see
this thread)
6. get the player's original pokemon back (eg. the portable storage system again)
You will probably want to allow the game to continue in the event the player loses the trainer battle, which means using Oak's tutorial battle (you can toggle the tutorial text with
this or just
allow continuation via a flag)
This might look like a lot but you'll learn a lot by getting it all to work. Good luck!