Difference between revisions of "Game mode"

From ALttP Speedrunning Wiki
Jump to: navigation, search
 
Line 2: Line 2:
  
 
==Submodule==
 
==Submodule==
The submodule is where most of the magic of corruption happens. Fundamentally, all changes to the submodule are ''incrementations''; i.e. nothing is directly set. For example, an overworld mirror transition is submode {{HEX|23}}. If the mirror were used when the submode was already {{HEX|01}}, then the result would be submode {{HEX|24}}. In fact, this is exactly what happens during a mirror wrap.
+
The submodule is where most of the magic of corruption happens. Fundamentally, changes to the submodule via super- and subtile transitions are ''incrementations''; i.e. nothing is directly set. For example, an overworld mirror transition is submode {{HEX|23}}. If the mirror were used when the submode was already {{HEX|01}}, then the result would be submode {{HEX|24}}. In fact, this is exactly what happens during a mirror wrap.
  
 
{| class="wikitable"
 
{| class="wikitable"

Latest revision as of 11:32, 27 August 2021

The game mode is, in simplest terms, what the game is currently doing as its set of routines. For the context of this article, we will consider the game mode as the exact combination of 2 different addresses: $10 and $11, the main module and submodule, respectively. An in-depth understanding of these addresses is not necessary for No Major Glitches categories; however, understanding them at a basic level is helpful for routing and executing any transition-corrupting glitch.

Submodule

The submodule is where most of the magic of corruption happens. Fundamentally, changes to the submodule via super- and subtile transitions are incrementations; i.e. nothing is directly set. For example, an overworld mirror transition is submode 0x23. If the mirror were used when the submode was already 0x01, then the result would be submode 0x24. In fact, this is exactly what happens during a mirror wrap.

Submodule values
Main module 0x07 (Underworld)
Value Process Corruptable? Corrupted from Notes
0x00 Default state; player in control No
0x01 Subtile transition Yes
0x02 Supertile transition Yes West subtile somarias
0x03 Star tile hit No Somaria Door See: Overlay corruption
0x04 Unlocking key door No West supertile somarias
0x05 Shutter doors opening/closing No Not corruptable, but see § Non-increment corruptions
0x06  ??? No
0x07 Pit transition No
0x08 Auto stairs that go up south to north No
0x09 Cracked wall opening No
0x0A Torch-induced brightening No
0x0B Water drain No
0x0C Water Flood No
0x0D Flood gates No
0x0E Spiral staircase transition No
0x0F Entrance transition No
0x10 Auto stairs that go up north to south No
0x11  ???
0x12 Up straight staircase No
0x13 Down straight staircase No
0x14 Damaging pit scroll No
0x15 Telepad Partially*
0x16 Peg switch No
0x17 Pressure plate No
0x18 Crystal fanfare No
0x19 Mirror transition Yes
0x1A Triforce door No Subtile Mirror Door
Main module 0x09 (Overworld)
Value Process Corruptable? Corrupted from Notes
0x00 Default state; player in control No
0x01 Graphics Load
0x02 Graphics Again
0x03 Map32 to Map16/8 conversion
0x04
0x05
0x06
0x07
0x08
0x09
0x0A
0x0B
0x0C
0x0D
0x0E
0x0F
0x10
0x11
0x12
0x13
0x14
0x15
0x16
0x17
0x18
0x19
0x1A
0x1B
0x1C
0x1D
0x1E
0x1F
0x20
0x21
0x22
0x23 Mirror warp
0x24
0x25
0x26
0x27
0x28
0x29
0x2A
0x2B Pedestal
0x2C Mirror bonk
0x2D Flute activation
0x2E Whirlpool
0x2F Whirlpool

* Telepads can be corrupted only with a YBA, but doing so results in a game crash

Non-increment corruptions

LSD Blind

LSD Blind with both effects

By pressing select, drinking a potion, or opening the map as Blind enters the light in her room, the game may enter submodule 0x05 of main module 0x0E. This will create one or both of the iris wipe used by the Desert prayer and a mesh of vibrant colors replacing most of the game's palettes. The latter only appears to occur on certain frames with the select menu, and it is where the name of this glitch comes from. Using the mirror will begin the mosaic effect, leaving the screen in that filter when it is interrupted. This is caused by the door of the room attempting to close, which sets the submodule directly to 0x05. Since the main/sub module combination of 0x0705 never occurs, this leaves that door open.

Jingle Glitch

Main article: Jingle glitch

When stairs are used at the same time that shutter doors open or close, the submodule takes on its value of 0x05 directly. The actual execution of most scripts behaves as normal here, but this change does interrupt some data transfer and coordinate functions, leading to the sprite offset and some data spoofing.