v1.3
v1.3, or: I put a whole SNES in the port so you can lose to a randomizer
The port plays A Link to the Past. As of this release it also plays alttpr.com randomizer seeds, and it brings an item tracker that fills itself in while you play. The normal game hasn't changed. Your saves, settings, rumble and MSU pack are all where you left them.
Randomizer seeds
There's a Randomizer button on the start menu now, under Play. It opens two choices:
- Built-In Randomizer, greyed out, with a COMING SOON sign on it. It's coming. Soon. Ish.
- ALTTPR.COM Randomizer, where you drop seeds.
Generate a seed on alttpr.com from the Japanese 1.0 ROM, drag the .sfc onto the window, and press Play This Seed. Or run zelda3 seed.sfc and skip the clicking.
The page reads the seed and shows everything it will admit to: its five hash icons (the same ones alttpr.com shows, so you know it's the right seed), its alttpr.com link, logic, mode, goal, crystal requirements and item count. Seed Details goes further: item pool, key and map shuffles, swords, quickswap, pseudo boots, silver arrows, menu speed, heart beep, heart color, the clock, the tournament flag and starting items. The medallions and every dungeon's prize are in there too, hidden behind a button, for when you've given up.
Why there's an emulator in here now
A seed isn't a few shuffled chests. The randomizer rewrites a lot of the game's own code, so the port can't play it and pretend. Seeds run in a SNES emulator instead: the one the port has always been checked against (LakeSnes, by way of upstream), which I put back together as a whole console. That's a CPU, a PPU, a sound chip, DMA, timers and cartridge save RAM, all stepped together a cycle at a time. It plays the ROM exactly as the randomizer built it. Getting there took fixing an off-by-one in the branch instruction, in both the CPU and the sound chip, which hung the game waiting on a sound chip that had wandered off.
- Saves go next to the seed as
seed.srm. - Off for seeds: snapshots, cheats and Turbo. It's a race. No fast-forwarding.
- Still on: fullscreen, pause, window size, volume, and Ctrl+R to reset.
The tracker
It reads the game's save data every frame, so there's nothing to click and nothing to get wrong. Its icons and maps come out of the seed itself, so it looks like the game and ships no art.
The large layout (the default) has:
- a counter: items found out of the seed's total, hearts, and crystals against what Ganon's Tower and Ganon want
- the full inventory
- a table of all 13 dungeons: checks left, small keys, big key, map, compass, boss and prize, with a colored stripe for how each one stands
- both world maps with every check marked, and a legend so you know what the colors mean
The compact layout fits the same into a narrower panel. The tracker can go beside the game (either side), over it, in a window of its own, or nowhere. T switches between those while you play.
And there are 21 options for it on the page: layout, which parts show, only the current world's map, full or short dungeon names, prizes once you have the map or always, which medallion Misery Mire and Turtle Rock want (spoiler), dimmed or hidden missing items, greyed or hidden cleared checks, marker size, overlay opacity, corner and size, and a green-screen or magenta background for keying the tracker out on a stream. All of it lives in [Randomizer] in zelda3.ini, apart from the normal game's settings.
What seeds borrow from the port
- Rumble, on by default, working exactly like it does in the port.
- Widescreen, off by default and labeled experimental. It mostly works. Outdoors the edges can show stale tiles for a moment while scrolling.
- MSU-1, using the same pack the normal game plays. Nothing to copy or rename. The seed's own code picks the tracks. A normal-game pack's tracks past 34 are ignored, because the randomizer uses those numbers for its per-dungeon music and would otherwise play your pack's track 35 in Eastern Palace. Ask me how I know.
Things I broke and then fixed before you saw them
- The very first file select screen of a fresh seed came up pitch black. The game was running fine behind the curtain; the PPU was just looking at the screen's brightness once per frame, and the randomizer turns the screen on a few lines late there. It looks every line now.
- Seed audio crackled, from two separate bugs in how sound got from the emulated chip to your speakers. It's one smooth, continuous stream now, and it adjusts its speed by half a percent at most to keep up.
- With the tracker in its own window, you couldn't close the game, and putting the tracker back squished everything. Both fixed.
Also
- NixOS: a
flake.nix, courtesy of adamzwakk in the first outside pull request this fork has ever had. Thank you! - The README grew a proper randomizer guide, with every tracker option and its
zelda3.inikey in one table. - New credits: the alttpr.com team, whose generator and z3randomizer source told me where a seed keeps everything, and kattothepast's alttptracker, where the tracker's check data comes from.
Getting it running
- Download the game for your system, and the tools if you want them.
- macOS (Apple Silicon, macOS 11+): unzip and drag the app to Applications, then run
xattr -dr com.apple.quarantine /Applications/alttp-zig.app(and the same forzelda3-tools.app) once. Still not notarized. Still haven't paid Apple $99. - Linux (x86_64, glibc 2.35+):
chmod +xthe AppImage and run it. If it complains about FUSE, installlibfuse2orfuse3, or add--appimage-extract-and-run. - Windows (x86_64): unzip anywhere and run
zelda3.exeorzelda3-tools.exe. SmartScreen will still clutch its pearls: "More info", then "Run anyway". - Give the game your US ROM and press Play. For seeds, generate one on alttpr.com from the Japanese 1.0 ROM (MD5
03a63945398191337e896e5771f77173) and drop it on the Randomizer page. No game data is included, as ever.