You are not logged in.
Pages: 1
I am having problems to add new pokemon in Pokered. After $C9, the added mons are occupying the IDs of the trainers, when I try to find them in the wild, a random trainer battle begin. Can someone help me to fix that?
Offline
The game assumes that opponent IDs less than 200 ($C8) are Pokemon, and opponent IDs greater than or equal to 200 are trainers.
To remove this, you need a new way to manage opponent IDs. For example, allow both lists of IDs to start at 1, then have a flag somewhere that is set for trainer battles and not set for wild battles, or something similar.
To get an idea of the places of code that you need to edit, look around the disassembly for 'cp 200' and 'sub 200', and look at places where 'wCurOpponent' is written to and read from.
Other memory locations to take a look at are 'wEnemyMonOrTrainerClass', 'wEnemyMonSpecies2', and 'wTrainerClass'
Offline
In Red++, I did this by borrowing the code Sanqui used in his red randomizer. One of these days I'll get around to adapting that to a modern copy of pokered for people to use if they want, since the existing commits are for a copy of pokered that is like 4 years outdated at this point haha. Not sure when I'll get a chance to do that, but I'll try to soon.
Current Projects:
Pokémon Christmas
Pokémon Red++
Offline
I also started working on doing this by trying to port over Mateo's RPP implementation, so far it seems I've hunted down and set up everything required to make the "wIsTrainerBattle" system work including the new files for pic pointers and such, but any time I try to start a battle it leads to a crash making me think there's mabye a problem in the battle initialization at battle_transitions.asm or at battle/core.asm at InitBattleCommon.
Any leads would be great, I can upload my stuff if need be too.
Offline
Pages: 1