View Single Post
  #4    
Old March 26th, 2012 (09:32 AM).
sonic1's Avatar
sonic1 sonic1 is offline
ASM is my life now...
Team Sinnoh
 
Join Date: May 2008
Location: Portugal
Age: 20
Gender: Male
Nature: Timid
Posts: 79
Quote originally posted by RicePigeonKKM:

EDIT: In Fire Red, after disassembling the routine at 809a1f8, it seems that the value of 1 is subtracted from the item amount in r0. Changing this to 0 will cause the TM to not be consumed, but it will do the same for all items as well...
Well, to put it blunt, item index is passed through r4. Make a branch at that offset you mentioned and check if r4 is between tm01 and tm50 item values:
Code:
0x121≤r4≤0x152
If yes, then don't subtract anything. If not, subtract 1 like normal items.

~Sonic1
__________________
This signature has been disabled.
over 350px high
Please review and fix the issues by reading the signature rules.

You must edit it to meet the limits set by the rules before you may remove the [sig-reason] code from your signature. Removing this tag will re-enable it.

Do not remove the tag until you fix the issues in your signature. You may be infracted for removing this tag if you do not fix the specified issues. Do not use this tag for decoration purposes.
Reply With Quote