View Single Post
  #20404    
Old January 23rd, 2012, 02:19 PM
robosllim's Avatar
robosllim
Unhatched Egg
 
Join Date: Jan 2012
Gender: Male
Quote:
Originally Posted by The_Show View Post
Try changing his AI to a higher number. If you want to tell a trainer how/when to use items, you gotta ASM
Here's the way things are now. There's a particular trainer, Battle Girl Lauren, who is known to cause problems. So I moved her to my debug location using Advance Map. She has a Hitmonlee with AI Value 200. She has an Antidote, a Burn Heal, a Full Heal, and a Full Restore. I poison the Hitmonlee and, consistently, she uses a Super Repel one turn, followed by a ?????? the next turn. Each will say "Foe HITMONLEE's SUPER REPEL/?????? cured POISON!" without actually doing so.

So next, I remove all of her items and set Hitmonlee's AI Value to 0. I confirm that these changes take effect through HxD. I also change her name to confirm I'm loading the right ROM in VBA. So now, when Battle Girl Laurrrrrr battles me, she still uses a Super Repel and a ?????? when her Hitmonlee gets poisoned. Same behavior as before, even though her data changed.

Now, I've figured out all the bytes in the trainer Pokemon data section (AI, level, dex number, item, and attacks), but I've got some holes in the trainer data:

Code:
0-1   - ???
2-3   - Music and Sprite
4-15  - Name
16-23 - Items
24-27 - ???
28    - Type (07 is story battle, I think)
29-31 - ???
32    - Pokemon count
33-35 - ???
36-39 - The address of the Pokemon data
I'm wondering if any of the blanks could be causing issues. So, two questions: First, can anyone fill in my blanks? Second, is there anything else that may account for the weird item behavior? It definitely seems to be tied to particular trainers, rather than some corruption of the battle code... though I obviously am not certain.

Last edited by robosllim; January 23rd, 2012 at 02:21 PM. Reason: Typo