User:Zeroman/Write to WRAM using the item pack
Jump to navigation
Jump to search
This setup requires two glitch items: 4F (0x59) for both Pokémon Red, Blue, and Yellow and item 0x6B for Pokémon Red and Blue or (what better item for Pokémon Yellow)?
Functions
= Write to memory
Reset the value and address
This is used to reset the address and value you wanna write (to). It resets the address and value to DFFF and FF, respectively.
The item bag
As items:
- item 1: 4F (0x59), x255
- item 2: item 0x6B, x255
- item 3: Carbos (0x26), x(first byte of address)
- item 4: X Accuracy (0x2E), x(second byte of address)
- item 5: Lemonade (0x3E), x(value)
- item 6: Item 0x77, x201
- item 7: Carbos (0x26), x211
- item 8: X Accuracy (0x2E), x255
- item 9: Lemonade (0x3E), x255
- item 10: TM01 (0xC9), x(any, but preferably 99)
END OF LIST
As ASM instructions: At DA65: jp D322
At CD35: jp D32A
At D322 (load the value of register a into register hl; "write value you want to write to address you want to write to."):
- ld h, $DF
- ld l, $FF
- ld a, $FF
- ld (hl), a
- ret
At D32A (reset function):
- ld h, $D3
- ld l, $22
- ld a, $DF
- ld (hl), a
- ld h, $D3
- ld l, $23
- ld a, $FF
- ld (hl), a
- ld h, $D3
- ld l, $24
- ld a, $FF
- ret
As HEX bytes:
At $DA65/$DA64:
- C3 22 D3
At $CD35 (Pokémon Red and Blue only):
- C3 2A D3