Jump to content

OAM DMA hijacking: Difference between revisions

no edit summary
No edit summary
Line 33:
 
OAM DMA hijacking is useful as a form of 'real-time' arbitrary code execution, allowing the player to perform exploits such as walk through walls in Generation II or writing a [[0x50 sub-tile]] permanently to the beginning of the screen data for Generation I.
 
 
This glitch works by hijacking the "OAM DMA" process associated with sprites. {{elaborate}}
 
An easy means to perform OAM DMA hijacking in both {{RB}} and {{GS}} is to write to the HRAM region FF80, however care must be taken as this region will be executed every frame. For this reason it is safe to place a ret (0xC9) opcode at the beginning of this region, write the code after it and replace the ret with a nop (0x00) byte afterwards. This exploit was documented by Crystal_.
 
{{YouTube|1w2iQdAHPh4|Crystal_}}
 
==Setup (OAM sprite manipulation)==
Cookies help us deliver our services. By using our services, you agree to our use of cookies.