TASVideos

Tool-assisted game movies
When human skills are just not enough

Submission #5393: AkagitsuneYuki's GBA Yu-Gi-Oh! 7 Trials to Glory: World Championship Tournament 2005 "game end glitch" in 00:35.33

Console: Game Boy Advance
Game name: Yu-Gi-Oh! 7 Trials to Glory: World Championship Tournament 2005
Game version: USA
ROM filename: Yu-Gi-Oh! - 7 Trials to Glory - World Championship Tournament 2005 (USA) (En,Ja,Fr,De,Es,It).gba
Branch: game end glitch
Emulator: BizHawk 1.11.9.1
Movie length: 00:35.33
FrameCount: 2110
Re-record count: 401
Author's real name: Michael L.
Author's nickname: AkagitsuneYuki
Submitter: Akagitsune Yukimura
Submitted at: 2017-02-14 21:30:30
Text last edited at: 2017-02-21 16:28:12
Text last edited by: Spikestuff
Download: Download (1657 bytes)
Status: published
Click to view the actual publication
Submission instructions
Discuss this submission (also rating / voting)
List all submissions by this submitter
List pages on this site that refer to this submission
View submission text history
Back to the submission list
Author's comments and explanations:
Wait, did you just buy a bunch of cards in one shop?

-Yeah, so?

That's against the code, isn't it?

-Screw the code, I got glitches!

Objectives

  • Emulator: BizHawk 1.11.9.1
  • Core: mGBA
  • Abuses programming errors
  • Triggers the end credits

Comments


(Link to video)

Yu-Gi-Oh! 7 Trials to Glory is a video game based on the Yu-Gi-Oh! anime series and card game. Normally the player would have to battle other duelists, enter tournaments, and more to become the new Duel Monsters champion. Normally this can take many days to do casually, but thanks to a glitch discovered by gcah2006 (a.k.a. the Master) we can have the game think it's been completed without having to play one card game.

This glitch, which will be referred to as the "shop glitch", is very simple to set up but currently has no full explanation as to why it works. To put it simply, I used lag to buy 3 of a card pack when normally I can only buy 1, and, with a combination of other packs, set the game in a post-completion state.

The glitch in more detail

Since this glitch is still new, not much is known about it. I've done quite a bit of research into this glitch and I was able to draw a few conclusions;

  • When adding cards to your basket there's a small window of frames where if you select to buy an adjacent pack in the shopping list and then cancel the order, the number you had of that previous pack will be copied over to the pack you've just canceled.
tl;dr Lag in the shop allows us to copy data.
  • You're limited to how many of each pack you can buy by your DP (Duel Points, this game's currency) and by the limit Grandpa (the shop owner) puts for each pack. Volume Packs and Standard Decks don't do anything weird if you glitch to buy more than what they were limited to, but Collection Packs do. Results caused by buying too many card packs differ depending on what you purchase (most results from what I've tested either crash or softlock the game), and it just so happens that buying the packs seen in this TAS makes the game think it's been beaten.
tl;dr Buying more cards than intended causes problems with the game's code. This is used to beat the game fast.
  • This glitch does not work with arbitrary code like many other game end runs on the site. Instead it takes advantage of poor programming with purchasing cards. Using a debugger I noticed that the game gets stuck in a loop for a while, but I couldn't gather as to what it was doing (I'm still new with assembly code). My guess is that due to the invalid amount of cards in our basket the game jumps to an unintended portion of code (which changes depending on what cards we buy). The code that the game jumps to happens to set a the flag that says the game has been beaten to true, which allows us to roll the credits whenever (this can only be done if the game has been completed).

tl;dr Too many cards equals beating the game apparently.

What's going on?

Starting the game

I set the language to Japanese to save a few frames of dialogue.

The B button is used to skip the intro to the main menu.

When starting the game, the player arrives in the Game Shop run by Yugi Moto's grand dad. He suggests that we buy some cards from him so we can start dueling.

The magic

I quickly select to buy 3 Volume 3 packs. I then use a glitch with the game's lag to select 3 Volume 4 packs and 3 Spellcaster Collection packs. Then I go to exchange the cards and that's when the magic happens.

Roll credits

I explain the glitch in more detail above, but here's a basic summary of what happened. Due to an error in the programming for purchasing cards, the game jumps to an unintended portion of code that, depending on what cards you purchase, changes a large amount of data. With this set-up, a flag that determines whether the game has been beaten or not is set to true, technically making the game completed. The game includes a feature only accessible in a post-completed state where you can play the credits at any time by inputting the Konami code (this code changes the color of the main menu as well).

(The Konami code does not trigger the credits in buildings, during dialogue, in duels, in menus, or on the title screen)

I input the code before leaving the house but after Grandpa finishes talking (the "game completed" flag was set to true before this), this is done to save frames.

Side effects

In the next section I explain some of the side effects that this glitch has in more detail, so I'll just bullet point them here;
  • The language gets set to Japanese (goes unnoticed in this run)
  • The animation speed gets set to 1 (the slowest)
  • The player gets between ~47 to 50% of all the cards in the game
  • The Player's DP becomes super low (34 with this route)
  • Despite having 0 wins/loses/draws and never entering any tournaments the game still thinks it's been beaten.
  • The day randomly changed.

Other comments

I wish I could provide a better explanation as to why this glitch happens, but sadly the glitch is still an enigma to everyone working on it. Hopefully I or anyone else will be able to find out the exact reason for this.

Some other notes;

  • About 4 seconds could have been saved if I was able to skip the BIOS (despite changing the settings it wouldn't let me skip it).
  • This is currently 3.23 seconds (RTA time) faster than the current world record.


Note to encoders

There's a scene after the credits that isn't that important. I would recommend stopping any encodes after the game fades to black from the card percentage screen.


Fog: Judging.

Fog: Game end glitches are always interesting runs to judge, as there's a lot to consider when judging runs like this. This game is of no exception. Under normal circumstances, game end glitches will trigger the credits with manipulating the game to run the credits routine. However, this run uses an easter egg to trigger the credits at any point after beating the game by entering in the Konami Code. The Konami Code is used in two places in normal play throughs of the game, to change the title screen colours between blue and purple, and to play the credits at any point after beating the game. Both uses can only be done if the game has been beaten, or in this case, thinks that the game has been beaten.

What the main glitch does in this run is set the game to think that it's in a post-completed state, thanks to some bad programming in the card shop. What this also does is unlock some extra tournaments which are only accessible after being the main game. After the movie has finished playing, you can take control over again, save the game, and reboot the game, and it will still have all of the effects of beating the game. But this run also brings up the question of what is a valid method of showing the credits or a post-completion state. We have had submissions in the past where there was no normal way of showing the credits in normal gameplay, and could only be accessed from the main menu. However, there is a known way to reach the credits in this game through normal playthrough. Seeing as this run is aiming for reaching the end of the game with a glitch, these arguments don't really apply, unless the method of achieving the glitch does not actually put the game in a post-completed state.

Because this run puts the game in a post completed state, and then plays the credits in a legitimate way (using an easter egg code only accessible after beating the game or placing it in a post-completed state), I will accept this run for Vault under the 'game-end glitch' branch.

Spikestuff: Needs more Motorcycles. Publishing.


Similar submissions (by title and categories where applicable):