Store Item's Display Data
Jump to navigation
Jump to search
Store Item's Display Data 0007f45c: 27bdffb8 addiu r29,r29,0xffb8 0007f460: afb00040 sw r16,0x0040(r29) 0007f464: 00808021 addu r16,r4,r0 r16 = Unit Misc Data Pointer 0007f468: afbf0044 sw r31,0x0044(r29) 0007f46c: 0c04dac4 jal 0x00136b10 Get Item Graphic Data 0007f470: 27a40028 addiu r4,r29,0x0028 r4 = Stack Pointer 0007f474: 8e0302d8 lw r3,0x02d8(r16) Load Item/Equip Display Pointer 0007f478: 97a20036 lhu r2,0x0036(r29) Load Palette value? 0007f47c: 00000000 nop 0007f480: a4620006 sh r2,0x0006(r3) Store Palette value? 0007f484: 93a20034 lbu r2,0x0034(r29) Load Item Graphic X Load Location 0007f488: 87a60038 lh r6,0x0038(r29) Load Graphic Width 0007f48c: 87a3003a lh r3,0x003a(r29) Load Graphic Height 0007f490: 00002821 addu r5,r0,r0 Section Counter = 0 0007f494: afa20010 sw r2,0x0010(r29) Store Item Graphic X Load Location 0007f498: 93a20035 lbu r2,0x0035(r29) Load Item Graphic Y Load Location 0007f49c: 34070010 ori r7,r0,0x0010 r7 = 0x10 0007f4a0: afa20014 sw r2,0x0014(r29) Store Item Graphic Y Load Location 0007f4a4: 87a20038 lh r2,0x0038(r29) Load Graphic Width 0007f4a8: 00e63023 subu r6,r7,r6 r6 = 0x10 - Graphic Width? 0007f4ac: afa20018 sw r2,0x0018(r29) Store Graphic Width 0007f4b0: 87a2003a lh r2,0x003a(r29) Load Graphic Height 0007f4b4: 00e33823 subu r7,r7,r3 r7 = 0x10 - Graphic Height? 0007f4b8: afa00020 sw r0,0x0020(r29) Store Y Load Location 2? = 0 0007f4bc: afa2001c sw r2,0x001c(r29) Store Graphic Height 0007f4c0: 000617c2 srl r2,r6,0x1f 0007f4c4: 00c23021 addu r6,r6,r2 0007f4c8: 00063043 sra r6,r6,0x01 Width / 2 0007f4cc: 24c6fff8 addiu r6,r6,0xfff8 (Width / 2) - 8 0007f4d0: 00063400 sll r6,r6,0x10 0007f4d4: 000717c2 srl r2,r7,0x1f 0007f4d8: 00e23821 addu r7,r7,r2 0007f4dc: 00073843 sra r7,r7,0x01 Height / 2 0007f4e0: 24e7fff8 addiu r7,r7,0xfff8 (Height / 2) - 8 0007f4e4: 00073c00 sll r7,r7,0x10 0007f4e8: 00063403 sra r6,r6,0x10 X Shift = (Width / 2) - 8 0007f4ec: 8e0402d8 lw r4,0x02d8(r16) Load Item/Equip Display Pointer 0007f4f0: 0c01ed3b jal 0x0007b4ec Store Display Data 0007f4f4: 00073c03 sra r7,r7,0x10 Y Shift = (Height / 2) - 8 0007f4f8: 8fbf0044 lw r31,0x0044(r29) 0007f4fc: 8fb00040 lw r16,0x0040(r29) 0007f500: 27bd0048 addiu r29,r29,0x0048 0007f504: 03e00008 jr r31 0007f508: 00000000 nop