Final Fantasy IV: The After Years (PAL) [WF4P] Assembly item drop code

Started by player0, July 23, 2009, 01:36:36 PM

Previous topic - Next topic

player0

Hello everyone, this is my very first post and my very first try on hacking a WiiWare game with USBGecko

As I don't have the code db access, feel free to port it there if you are more capable  ;) (just credit me)

Actually this is more like half the code because I was playing with the disassembler and I dont know how to turn the hack into GCT code yet.

Anyway, here it is
Monsters always drop all 4 types of items after battle
(normally you only get 1 out of 4 possible drops from each monster per battle if you are lucky,
this code gives you all 4 with 100% drop. e.g. if you kill a Goblin, it will give you a potion, a tent,
a bronze hourglass and a Goblin sphere. Some monsters like Larva only drop 2 types of items, but in fact they are
still listed as 4 types in the game with 2 being repeated, so killing a Larva will give you a potion and 3x hi-Potion)

8008EF54:  38C00005   li   r6,5
8008EF58:  38C6FFFF   subi   r6,r6,1
8008EF5C:  2C060004   cmpwi   r6,4
8008EF60:  41820074   beq-   0x8008efd4
8008EF64:  2C060003   cmpwi   r6,3
8008EF68:  41820084   beq-   0x8008efec
8008EF6C:  2C060002   cmpwi   r6,2
8008EF70:  4182009C   beq-   0x8008f00c
8008EF74:  2C060001   cmpwi   r6,1
8008EF78:  4182009C   beq-   0x8008f014
8008EF7C:  48000110   b   0x8008f08c
8008F058:  4BFFFF00   b   0x8008ef58
8008F07C:  4BFFFEDC   b   0x8008ef58

Now the only thing missing is how to transform these assemby codes into GCT codes. Should it be 04xxxxxx or 06xxxxxx?
Or each line must be accompanied with a 20xxxxxx to be sure the correct codes are patched? Thanks guys!

matt123337

it should be 04xxxxxx if you are modifiying the ASM, witch I think you are (right click them click "export to GCT" then the 04xxxxxx)

player0

Hehe, thanks. I guess I've figured it out. It should be a combination of 20, 06 and 04

Always drop all 4 items [player0]
2008EF54 807B0000
0608EF54 0000002C
38C00005 38C6FFFF
2C060004 41820074
2C060003 41820084
2C060002 4182009C
2C060001 4182009C
48000110 00000000
0408F058 4BFFFF00
0408F07C 4BFFFEDC
E0000000 00000000


matt123337


Chris-FireFox