[Utility] 8F Helper - gbz80aid
Posted by: Cryo
        Date: 2016-12-10 21:57:42
    After a good bit of going back-and-forth to the Wiki (and later back-and-forth to a text file) in order to look up values for the 8F glitch, I decided to write a program in C using lookup tables that could directly parse gbz80 assembly and machine code, then output the results to the console pretty quickly (~12 milliseconds) in a variety of outputs.
You can check it out over at its Github page, 8F Helper.
As an example of its output, I took the assembly instructions for the perpetually resetting save file by Wacko and converted them to 8F items with the utility.
test.asm:
ld l,$6E
ld (hl),$36
ld a,$D3
ld ($D36F),a
inc b
ld c,$1c
ld h,$78
ld l,$48 ; 1c:7848: SaveSAVtoSRAM
ld b,c
call $35d6 ; BankSwitch
jp nc,$1f49 ; SoftReset
Command and output:
root@gbdev:~# gbz80aid -o gen1 -f test_code.asm
Item            Quantity
========================
X Accuracy      x110
Max Revive      x54
Lemonade        x211
TM34            x111
TM11            x4
Awakening       x28
Carbos          x120
X Accuracy      x72
X Attack        x205
TM14            x53
TM10            x73
Old Amber       xAny
Hope it can be of use! ;D