Salvage Item Manipulation

Discovered by OrangePlasticCup

Technical Explanation

Explanation by LagoLunatic

When forest water expires on the same frame the grappling hook hits the sunken treasure, the salvage point tag you're about to salvage will no longer count as the active one, but it still triggers the salvage. Because there's no active tag, the active index is set to -1. There's no sanity check in place to prevent the chest from coming up when the index is negative. This means that the game tries to read the item ID from 4 bytes before the start of the list in RAM instead. Since this byte is unrelated to the sunken chest, it could be literally anything. This allows for salvaging any of the 255 (used and unused) items in the game.

After closing the textbox for the item, the game normally crashes because it reads the salvage to be the kind of salvage corresponding to treasure charts (kind 0). It then fails to to save the treasure chart information, because it ends up in an invalid range (0 again). This crash can however be avoided by fishing up the treasure chest with Storage.

How To

First, the memory must be setup in order for you to salvage the item you want. At 0x803EA014 on JP and at 0x803F6B44 on US there is a pointer to an address, and 4 bytes before that pointed address is what is read to be an item ID. If you can control that byte then you can obtain any item that you want early. Currently, there are no good setups that are not luck-reliant. Once that byte has the value you want, you can proceed with performing the glitch.

Example of luck-reliant setup to get the Hookshot

Have a bottle with forest water close to expiry. Get Storage, climb in the boat and get ready to salvage a sunken treasure (it can be any kind of treasure, one from a chart or one from a light ring). Salvage the chest and have forest water expire on the exact same frame as the grappling hook hits the chest. You must also release the grappling hook button right as it hits the chest or a little bit before (the frame window can vary). The forest water text will then appear and you can close it to cancel the salvaging animation. Reload the area to obtain the item, just like with chest storage.

Method to avoid the crash

This trick relies on a frame perfect forest expiry and a small frame window for releasing the grappling hook, it is thus very difficult.

Uses in Speedruns

The main use of this trick is to obtain the Hookshot early. With an early hookshot, it is possible to enter the Earth Temple early. This skips learning the Earth God's Lyrics and teaching the Song to Medli. In All Dungeons Speedruns, this also leads to skipping Hyrule 2 (the Tetra to Zelda Transformation Cutscene only used to being required to make Medli appear on the overworld in that category) when combined with Early Master Sword Cutscene Skip. All of these timesaves combined should save over 10 minutes in All Dungeons.

Due to the volatilness of the known setups to get the Hookshot and the difficulty of the trick, it is currently considered TAS-only.

Last updated 08/06/2021 – azer67