(Link to video)
Recently, a glitch was found that can replace an egg with a null sprite so that you can basically take any sprite with you. I use this glitch to confuse the game with its indexing and jump to controller data to manipulate some data and jump to the credits.

Game objectives

  • Emulator used: lsnes rr1-Δ18
  • Aims for fastest time
  • Abuses programming errors in the game
  • Executes arbitrary code
  • Achieves credits early

Comments

The glitch happens when you grab the egg from the head of a Mouser and let him despawn before he "realized" that you took it from him (without him touching the floor). Then the egg also despawns but you still "have" this egg (the RAM value of the egg counter is still showing that you have this egg) and the sprite slot of that egg is also saved, but opened so that every sprite can take its place. So far so good but the problem that people had was that when they went into the goal ring, the game crashes for 99% of the sprites that were brought. So I took a look at what was going on with the game and found out that it checks every egg you have and indexes it so that every different sprite ID has it's own function (a normal egg just returns from this function). This is probably for the other sprites you can have, for example a key or a big egg and so on. I quickly found out that a Shy Guy will bring the code to $02:608C... and that just happens to be the x position of Yoshi!
So $608C is the low byte, $608D is the high byte, $608E is the y subposition and $608F is some value from 0x04 to 0xFC (probably for calculation stuff)
So I want to jump to controller data, that would be JMP $4218, in hex: 4C 18 42, but I had a better idea that made the run a bit faster: instead of JMP $4218 I would JML $024218, in hex: 5C 18 42 02, because getting my x position to 0x5C instead of 0x4C was faster.
So I will cover changing x position low byte later, but how do I change my x position high byte to 0x18? I don't! The high byte is 0x0E at the end of 2-2 and jumping to $420E wasn't a problem because YI is good at recovering from BRKs (0x00), so I just let the game jump over some of the registers. Changing y subposition to 0x42 wasn't a big problem either, you just have to press B and release B at the correct times, and the last value wasn't a problem, it just was 0x02 (it could have been every value from 0x00 - 0x04).
So now to the x position change. The goal ring is not movable so how do I trigger the goal ring while being at the correct position? I just use another null sprite egg to change the properties of the goal to make it possible to lick it and spit it out. Then it recovers itself so I can trigger it again.
When the code is at controller data, I couldn't just use WAI to get the next input, because IRQ is activated every H-Blank, so it will stop there. Changing the mode of IRQ (so that it only fires at V-Blank) also isn't possible since it changes itself back to the other mode. Deactivating IRQ also isn't an option because NMI is very short and returns while Auto-Joypad Read is enabled (so the controller data is garbage).
The way I did it was just activating DMA controllers to stop the game for a few frames (that is why strange things are going on with the video at the end). That worked wonderful and all I had to do was set Data Bank and Direct Page to zero, setting gamemode ($0118) to 0x1B and jumping to the start of the main game routine (which loads the gamemode and decides what to do/where to jump next) to trigger the credits. The good thing is that normally the main game routine is called at the highest stack value, meaning that the code will never return back to the controller data/egg routine/garbage code.

Stage by stage comments

Intro

Trying to get 14 coins as fast as possible to do the warp glitch to go to 2-2.

2-2

I took the fastest route I could think of while getting 4 eggs for the third/last room. There I had to manipulate sprite slots to do the glitch and win the game.

Other comments

Possible improvements

  • Maybe some tiny frame improvements in room 1 (any% like route)
  • Finding another glitch (infinite tongue glitch?) to reach credits faster

Thanks to

  • Arne for finding this glitch
  • Carl Sagan for the possible improvements
  • YI community for finding every glitch in the Game Resource page

Suggested Screenshots

[dead links removed]

Nach: Once of the most awesome runs of the year, accepting.

Player (12)
Joined: 6/17/2006
Posts: 501
Masterjun, you've done it again! Congratulations and yes vote!
Joined: 12/22/2009
Posts: 291
Location: Michigan
Very impressive work, sir. Well done. Yes vote.
Current projects: Yoshi's Island Disassembly Yoshi's Island any% TAS with Carl Sagan
GhostSonic
He/Him
Joined: 3/14/2013
Posts: 61
Ilari wrote:
Tested with modified bsnes core (more accurate emulation of autopolling). Works fine.
You think there's a chance of this being console verifiable then? I don't currently own Yoshi's Island so I can't test it at the moment. I wonder if the bsnes core emulates the Super FX 2 accurately enough to work properly. I remember the old run not syncing at all on newer version of Bizhawk and lsnes.
Emulator Coder, Skilled player (1141)
Joined: 5/1/2010
Posts: 1217
GhostSonic wrote:
Ilari wrote:
Tested with modified bsnes core (more accurate emulation of autopolling). Works fine.
You think there's a chance of this being console verifiable then?
I mainly wanted to check against exploiting that known emulation error. Also, verifying this means controlling 4 controllers independently.
GhostSonic wrote:
I don't currently own Yoshi's Island so I can't test it at the moment. I wonder if the bsnes core emulates the Super FX 2 accurately enough to work properly.
AFAIK, there are known emulation errors with SuperFX (such as the CPU-SuperFX memory access race). I think usually that error just results some missed lag frames (because it emulates that operations occur faster than the equivalent in real world).
GhostSonic wrote:
I remember the old run not syncing at all on newer version of Bizhawk and lsnes.
Probably doesn't sync on any version of lsnes.
Glitcher
He/Him
Joined: 3/24/2007
Posts: 216
Location: London, U.K.
Looks like it's possible to glitch to the credits in both Super Mario World games, eh? Hey, any run that omits that tedious autoscrolling part in Bowser's Castle is fine by me!
Editor, Experienced player (608)
Joined: 11/8/2010
Posts: 4012
Wow, this was amazing, Masterjun! I love that this game can be broken in a similar way as the original SMW. Yes vote!
Joined: 1/24/2013
Posts: 9
I watched it without reading the commentary first (and I didn't even notice the name). It was only near the end, when the weird movement started, that I realised what was probably happening and what was coming. I was right, too, but even that couldn't have prepared me for the goal ring. Magnificent.
Joined: 5/8/2010
Posts: 177
Location: Entropy
Had to watch it a 2nd time, only then I noticed the goal moving. This game has so much dafuq in it! Big yes on my part once more!
Joined: 2/20/2010
Posts: 209
Location: I'm in space
well that made sense, yes
Oh, play it cool. Play it cool. Here come the space cops.
Post subject: Movie published
TASVideoAgent
They/Them
Moderator
Joined: 8/3/2004
Posts: 14852
Location: 127.0.0.1
This movie has been published. The posts before this message apply to the submission, and posts after this message apply to the published movie. ---- [2431] SNES Super Mario World 2: Yoshi's Island "game end glitch" by Masterjun in 02:36.81
ALAKTORN
He/Him
Player (99)
Joined: 10/19/2009
Posts: 2527
Location: Italy
why didn’t the previous movie get obsoleted? http://tasvideos.org/2337M.html
Emulator Coder, Skilled player (1141)
Joined: 5/1/2010
Posts: 1217
ALAKTORN wrote:
why didn’t the previous movie get obsoleted? http://tasvideos.org/2337M.html
Huh? It shows as obsoleted here.
ALAKTORN
He/Him
Player (99)
Joined: 10/19/2009
Posts: 2527
Location: Italy
I’m not seeing it http://i.imgur.com/49Mp6Ny.jpg
Experienced player (508)
Joined: 11/2/2010
Posts: 359
ALAKTORN wrote:
I’m not seeing it http://i.imgur.com/49Mp6Ny.jpg
Shows as obsolete here http://i.imgur.com/wyET0TT.png
Skilled player (1705)
Joined: 9/17/2009
Posts: 4952
Location: ̶C̶a̶n̶a̶d̶a̶ "Kanatah"
Bobmario511 wrote:
I wonder just how many games can be glitched like this, it's crazy. Yes vote.
I'm simply waiting for the day someone with more technical knowledge than me obsoletes this run by using the glitch featured there to skip directly to the credits instead of to the last boss. :P Oh, and this game might be glitchable too.
Patashu
He/Him
Joined: 10/2/2005
Posts: 4014
78k views on nicovideo and rising: Link to video
My Chiptune music, made in Famitracker: http://soundcloud.com/patashu My twitch. I stream mostly shmups & rhythm games http://twitch.tv/patashu My youtube, again shmups and rhythm games and misc stuff: http://youtube.com/user/patashu
negative_seven
She/Her
Active player (354)
Joined: 11/25/2012
Posts: 102
Location: Europe
Masterjun, can you do something normal for once...
Joined: 2/20/2010
Posts: 209
Location: I'm in space
Just realized that Yoshi actually tongues and then spits out the goal ring. Incredible. I really, sincerely hope this sets up a future Yoshi's Island playaround run, akin to the Link's Awakening playaround, like maybe Yoshi could swallow signposts and components of the stage select dialog next.
Oh, play it cool. Play it cool. Here come the space cops.
Patashu
He/Him
Joined: 10/2/2005
Posts: 4014
goldfish wrote:
Just realized that Yoshi actually tongues and then spits out the goal ring. Incredible. I really, sincerely hope this sets up a future Yoshi's Island playaround run, akin to the Link's Awakening playaround, like maybe Yoshi could swallow signposts and components of the stage select dialog next.
There's huge potential for a null egg glitch playaround for sure. You can use it to get 'any' sprite in the game into your egg inventory and bring it to 'any' room in the game. I've seen the submarine transformation bubble be bought into Salvo's boss fight.
My Chiptune music, made in Famitracker: http://soundcloud.com/patashu My twitch. I stream mostly shmups & rhythm games http://twitch.tv/patashu My youtube, again shmups and rhythm games and misc stuff: http://youtube.com/user/patashu
Joined: 4/3/2006
Posts: 269
OMG! I never thought that was possible. I find it entertaining to watch! Thank you for making this run!
Skilled player (1705)
Joined: 9/17/2009
Posts: 4952
Location: ̶C̶a̶n̶a̶d̶a̶ "Kanatah"
I got a question. Can this glitch be extended to do something like a "glitched 100%" run?
Masterjun
He/Him
Site Developer, Skilled player (1970)
Joined: 10/12/2010
Posts: 1179
Location: Germany
You would have to fill all the level bytes and the level score, then run the save routine. That would take a long time to execute and this is actually pretty unstable (since I use DMA to let the joypads refresh). Also, IIRC there is no indication in the credits scene that you have 100%, so it wouldn't even be visible for the normal viewer...
Warning: Might glitch to credits I will finish this ACE soon as possible (or will I?)
creaothceann
He/Him
Editor
Joined: 4/7/2005
Posts: 1874
Location: Germany
That's why you just hack a completion percentage HUD display into the game. ;)
Patashu
He/Him
Joined: 10/2/2005
Posts: 4014
I think the idea is you would use Null Egg Glitch to get red coins/flowers/stars easier, duplicate/spawn/create them, etc. Problem is, Null Egg Glitch takes so long to set up that it would be tricky to save time with it, and it's so new and huge in its potential use no one knows everything you could do with it yet. Imagine if you could use Null Egg Glitch to spawn a red coin carrying shy guy and keep it through the whole game like keyhole%, for example.
My Chiptune music, made in Famitracker: http://soundcloud.com/patashu My twitch. I stream mostly shmups & rhythm games http://twitch.tv/patashu My youtube, again shmups and rhythm games and misc stuff: http://youtube.com/user/patashu
Skilled player (1705)
Joined: 9/17/2009
Posts: 4952
Location: ̶C̶a̶n̶a̶d̶a̶ "Kanatah"
Patashu wrote:
I think the idea is you would use Null Egg Glitch to get red coins/flowers/stars easier, duplicate/spawn/create them, etc. Problem is, Null Egg Glitch takes so long to set up that it would be tricky to save time with it, and it's so new and huge in its potential use no one knows everything you could do with it yet. Imagine if you could use Null Egg Glitch to spawn a red coin carrying shy guy and keep it through the whole game like keyhole%, for example.
That sounds like it would make a very entertaining "glitched 100%" run/playaround. :o