This is a heavily glitched runthrough of Commander Keen 5 - completing the game in the impossibly short time of 2:42 - and the first submitted TAS using the emulator JPC-RR, which may be considered a proof-of-concept that the emulator is suitable for TASing.

Game objectives

  • Emulator used: JPC-RR r10 (syncs with r10.4)
    • VGA_DRAW must be enabled for the game to render properly, but enabling or disabling it does not impact gameplay.
  • Best ending
  • Uses warps
  • Uses hardest difficulty
  • Heavy glitch abuse
  • Takes damage to save time
  • Uses death to save time
  • Genre: Platform

Comments

Setting up the emulator

A prebuilt version of JPC-RR r10.4 is available from the TASTools Google Code repository (if you want to encode this, you'll also need the stream tools available there). Unpack it somewhere and start it. You will need to create two disk images using JPC-RR's Drives -> Import image utility:
  • The FreeDOS image normally distributed with JPC. The image is in the JPC source package, as resources/images/floppy.img. If you'd rather not do that, you can grab a prepared JPC-RR disk image for this from here (available under the terms of the GNU GPL v2).
  • The game (see the below section for more information about the disk image used).
After you've created the disk image (it should go into the disklibrary directory), run start-jpcrr.bat to start the emulator. (Flygon has reported that under Windows 7, the "java -jar" at the beginning of the command line within may be unnecessary and may prevent the emulator from running.)
The movie file can be loaded with Snapshot -> Load -> Movie; the appropriate images (including the game) will be loaded upon doing so. If you get a "no such image in library" message, it probably means you haven't built the game disk image properly.
Before starting the movie, you may wish to enable the VGA_DRAW hack in Debug -> Hacks; this doesn't affect sync but it results in the game displaying properly.
To start playback, go to System -> Start.

Game

This TAS uses v1.4 of the game - this is because the most important glitch works only in this version, as described below - and plays on Hard difficulty. If you happen to have another version of the game, keenmodding.org distributes a patch to convert your copy of the game to the appropriate version.
Here is JPC-RR's ImageMaker's report on the disk image I used (note that the hard disk geometry is the default when specifying "Hard disk" in the image creation utility):
Type               : HDD
Tracks             : 16
Sides              : 16
Sectors            : 63
Total sectors      : 16128
Primary extent size: 2744
Storage Method     : 3
Sectors present    : 1714
Calculated Disk ID : F278BE6EE81B72D8D7B51F186AFF6834
Claimed Disk ID    : f278be6ee81b72d8d7b51f186aff6834
Comments section:
Entry: N/A            N/A                                       4 /
Entry: 19900101000000 d080b7c53b0b374813a7479b559d4eb4     101990 /AUDIO.CK5
Entry: 19900101000000 d5598dcda25b02e61aeac17fcac9437b     573664 /EGAGRAPH.CK5
Entry: 19900101000000 33ffac175c3fb8e33fc3dbdc0ab6b965      73721 /GAMEMAPS.CK5
Entry: 19900101000000 075194c6617abf14e07cd78ea44e3266     106417 /KEEN5E.EXE

Reference

There is a 2:42 speedrun on Easy difficulty on YouTube which I used heavily as a reference. I am not sure what timing points are in use there; instead, here are some reference timing points for this run: first gameplay input to last moment gameplay is 2:38.533, and first input to triggering the action which eventually ends the game (setting off the mine; see level notes) is 2:36.133. Either way, there's a clear improvement with this run, not to mention the difference in difficulty levels (which throw a lot of new enemies in the path)!

Tricks and glitches

Central to most of the maneuvering in this run is the Impossible Pogo Trick. Tapping the jump (CTRL) and pogo stick (ALT) keys near-simultaneously while running allows a higher-than-normal pogo jump. On Easy mode Keen gets an extra unit of height out of this compared to some of the other two modes, so some of the maneuvers in the speed run are difficult if not impossible to replicate (Korath III comes to mind as a prime example of this).
There are two major glitches in use here:
  1. Warp glitch. Being pushed under certain conditions, including while hanging onto a pole, causes the end of the level to warp you to the game's secret level, Korath III. This is useful as the exit from Korath III takes you to the segment of the overworld just prior to the second last level of the game (as the exit to the secret level is in that level), meaning, if it's done early enough, you can skip a considerable number of levels. This glitch only works in v1.4 of the game.
  2. Death flag glitch. Saving and reloading a game causes the "you are dying" flag to be reset, but Keen is still in the dying animation, allowing him to clip through walls. This is most useful when done near the edge of a level, as touching the edge of a level while alive ends the level (which is never actually used in this game, and is a holdover from the other two games using the engine). Since one actually never sees the "you didn't make it past[...]" screen, I don't consider this death per se, but Keen still takes damage!

Stage by stage comments

Setup

To avoid flickering, I quickly turn on the SVGA Compatibility Mode option. I then start the game on Hard difficulty.

Ion Ventilation System

Key to this entire run are the presence of poles and Little Amptons (the purple pushing enemies), as they enable the use of the warp glitch in the very first level of the game! Keen shoots two of them to avoid slowing down or getting hit (he can only take damage from them if one of them slides into him on a pole), then hugs a pole and gets pushed off by the third, triggering the conditions for the warp glitch. Several tricky jumps and a handful of dead Sparkies later (the first Impossible Pogo after getting pushed needs to be effectively frame-perfect to work as advertised), Keen reaches the exit and mysteriously warps to Korath III.

Korath III Base

Frustratingly, Keen only has enough height to jump directly from the left platform to the hidden alcove on Easy mode. Instead, I land as quickly as possible on the right platform and Impossible Pogo up to the alcove. Two jumps later and Keen finds and breaks a fuse - doing so ends the level and also sets up the better ending later on.
No, Keen's quip about the fuse can't be dismissed any faster.

Gravitational Damping Hub

The death flag glitch sees use here. Keen needs to be standing almost as far to the right as possible in the alcove with the Volte-face in order to be close enough to the edge of the level after dying to get there without needing to save and reload more than once (given the time needed in loading the game, it is desirable to not have to reload more than once).
(Note that in the YouTube run, the Volte-face is already in a position where Keen can jump down right away. Here it starts off in the worst possible position for some reason, so I need to wait for a bit to jump down and wait a bit when it's down there...)

Quantum Explosion Dynamo

Here's the finale, and the longest of the four levels in this run. Sadly this level can't be skipped - triggering the ending in that fashion dumps him back to the overworld with no way to complete the game. The only way to trigger the ending is to reach and destroy the QED. To get to the QED requires three keys, and to blow it up needs a fourth.
The red and green keys are straightforward enough to obtain, needing little more than good timing and a few well-placed jumps. The blue key is a lot tricker thanks to the presence of a large number of Shockshunds. There is a Shockshund sitting right next to the key that eventually needs to be lured away, so a direct bypass approach isn't feasible; instead Keen ducks below the bridge area similar to the speedrun, though takes a lot less time shooting everything he can until he runs out of ammo, leaving a sufficient opening to collect the key. The remaining Shockshund moves slightly slower than Keen does, so just chasing it is out of the question; instead Keen ducks below and pulls off an impossible Impossible Pogo to escape.
The yellow key is en route to the doors, and the jump sequence Keen uses to get it and evade the Shikadi unscathed was the result of a lucky accident.
After unlocking the doors, Keen arrives at the QED itself. He evades a Shikadi Master and its attack and unlocks the red door, behind which are a number of Shikadi Mines - the only thing which can damage the QED. After painfully slowly luring it over to the QED, the mine explodes, taking down the QED, but also Keen? (Having Keen die here is slightly shorter than letting him live.)
Roll the ending!

Other comments

I anticipate that people may have difficulty getting the emulator to play back or would prefer to watch the run at normal speed. To that end, and as you've come to expect from me, I have encoded the run. Grab it at http://www.archive.org/download/CommanderKeen5TheArmageddonMachineIn0242.432BySgrunt/keen5-tas-sgrunt.mp4 or watch it below:
(flowplayer module removed)
A note about the encode: it uses the resolution of the game, i.e. 640x400, though there is a short segment of DOS at the beginning which is normally 720x400. Those images have been scaled to the appropriate resolution, similar to the norm of other runs which use multiple resolutions (such as Shadow of the Beast 2). You probably won't even notice, as that segment is so short, but I thought I would note what I did for future PC games that need encodes.
Here are some suggested screenshots:


Without the hard work that Ilari has put into JPC-RR, this run would not have been possible, so he deserves not only my thanks but yours as well!
Enjoy!

Nach: It slices! It dices! It causes the judges to go crazy and accept it! Explosion!


TASVideoAgent
They/Them
Moderator
Joined: 8/3/2004
Posts: 15584
Location: 127.0.0.1
Editor, Skilled player (1439)
Joined: 3/31/2010
Posts: 2108
DOS Run? Holy maccaroni!
Noxxa
They/Them
Moderator, Expert player (4124)
Joined: 8/14/2009
Posts: 4090
Location: The Netherlands
DOS TASing is possible now? Awesome.
http://www.youtube.com/Noxxa <dwangoAC> This is a TAS (...). Not suitable for all audiences. May cause undesirable side-effects. May contain emulator abuse. Emulator may be abusive. This product contains glitches known to the state of California to cause egg defects. <Masterjun> I'm just a guy arranging bits in a sequence which could potentially amuse other people looking at these bits <adelikat> In Oregon Trail, I sacrificed my own family to save time. In Star trek, I killed helpless comrades in escape pods to save time. Here, I kill my allies to save time. I think I need help.
arflech
He/Him
Joined: 5/3/2008
Posts: 1120
The link in the OP goes to the Git repository for JPC-RR rather than the Google Code TASTools repository and does not host any builds; here is the correct link: http://code.google.com/p/tastools/downloads/list
i imgur com/QiCaaH8 png
sgrunt
He/Him
Emulator Coder, Former player
Joined: 10/28/2007
Posts: 1360
Location: The dark horror in the back of your mind
arflech wrote:
The link in the OP goes to the Git repository for JPC-RR rather than the Google Code TASTools repository and does not host any builds; here is the correct link: http://code.google.com/p/tastools/downloads/list
The link has been fixed - thanks for pointing this out.
arflech
He/Him
Joined: 5/3/2008
Posts: 1120
In case anyone was curious about the old link, here it is: http://repo.or.cz/w/jpcrr.git
i imgur com/QiCaaH8 png
Joined: 6/4/2009
Posts: 570
Location: 33°07'41"S, 160°42'04"W
Big yes vote. This was fun. And I am happy about this emulator, open the DOS flood gates D
Joined: 11/22/2004
Posts: 1468
Location: Rotterdam, The Netherlands
I'm so glad we have proper DOS rerecording now. (Though I'm not sure if post-EGA era games have 100% accurate emulation.) I'd prefer to see a non-glitched version of this great game but big yes vote anyhow.
Mitjitsu
He/Him
Banned User
Joined: 4/24/2006
Posts: 2997
Unlike Virtual Boy and Lynx, there is clearly a vast library of games worth doing. I enjoyed the movie even though it was hard to judge from a technical stand point. I just hope the emu is stable enough to run most games and avoiding desyncing issues, espeacially when viewers themselves try to play back WIPs.
Joined: 11/4/2007
Posts: 1772
Location: Australia, Victoria
It was pretty cool, so I Yes voted. As much as I'd love to say I'm bringing you an encode that is making my CPU want to commit suicide, it turns out I am utterly incapable of dumping an AVI from this emulator without the game freezing at a certain point. This has been discussed with Grunt quite a bit, and well... what I can say is, don't try to dump this game using Windows 7 64-bit.
Post subject: Re: #2649: sgrunt's DOS Commander Keen 5: The Armageddon Machine "glitched" in 02:42.43
Joined: 1/26/2009
Posts: 558
Location: Canada - Québec
TASVideoAgent wrote:
You will need to create two disk images using JPC-RR's Drives -> Import image utility:
  • The FreeDOS image normally distributed with JPC. The image is in the JPC source package, as resources/images/floppy.img. If you'd rather not do that, you can grab a prepared JPC-RR disk image for this from here (available under the terms of the GNU GPL v2).
  • The game (see the below section for more information about the disk image used).
Hmm, I encounter some problem for the first import. I go to Drives > Import Image, then I enter a new image name, I press the "Image file/directory" button and select floppy.img, but the Image Type textbox keep telling me <" No valid choice ">... Did I do something wrong?
sgrunt
He/Him
Emulator Coder, Former player
Joined: 10/28/2007
Posts: 1360
Location: The dark horror in the back of your mind
Are you using the floppy.img I provided in the submission text? If that's the case, you can just put that into disklibrary as is.
Joined: 4/1/2010
Posts: 96
Oh dear me. The DOS TAS era begins!
Joined: 1/22/2008
Posts: 319
Location: Brasil
i just voted yes, i saw the your encode but im haveing dificult to emulate those images. i dind t understand well how it works
Run..Run...Run.....
Editor, Expert player (2479)
Joined: 4/8/2005
Posts: 1573
Location: Gone for a year, just for varietyyyyyyyyy!!
Wow, watched it with the emulator. I had no sound and it ran at about 3 FPS, but the input file did finish the game. Voting yes! Congratulations!
Post subject: Re: #2649: sgrunt's DOS Commander Keen 5: The Armageddon Machine "glitched" in 02:42.43
Joined: 1/26/2009
Posts: 558
Location: Canada - Québec
sgrunt wrote:
Are you using the floppy.img I provided in the submission text? If that's the case, you can just put that into disklibrary as is.
Ah, thanks :)
TASVideoAgent wrote:
This TAS uses v1.4 of the game - this is because the most important glitch works only in this version, as described below - and plays on Hard difficulty. If you happen to have another version of the game, keenmodding.org distributes a patch to convert your copy of the game to the appropriate version. Here is JPC-RR's ImageMaker's report on the disk image I used (note that the hard disk geometry is the default when specifying "Hard disk" in the image creation utility):
I patched the folder, but now I have no idea how to create the new image from that file, before importing(I doubt that I could import executable file alone)... You say there an option called ImageMaker? I probably missed something, but I'm unable to find such feature.
sgrunt
He/Him
Emulator Coder, Former player
Joined: 10/28/2007
Posts: 1360
Location: The dark horror in the back of your mind
The option you're looking for is in Drives -> Import Image. Be sure that the list of files in the directory matches what's in the submission text before you do so, though.
Joined: 1/26/2009
Posts: 558
Location: Canada - Québec
Alright, you made me realise that I can simply select a complete folder thought the windows explorer... now it sync and got the same primitive result as Aqfaq. Few improvement, good job.
Joined: 3/29/2010
Posts: 5
While it's not that amazing, it's still amazing. Some very nice use of glitches. (I should probably play the game but meh) (Hopefully I can vote) EDIT: I might try DOS TASing when it's not buggy as hell.
ventuz
He/Him
Player (125)
Joined: 10/4/2004
Posts: 940
Either dos emulator doesn't work, or I don't know what am I doing.
Joined: 11/11/2004
Posts: 400
Location: ::1
Sweet. I loved that game back in the day - I really hope there'll be TAS movies for the rest of the series and for the other old Apogee games, too. :D
Former player
Joined: 11/13/2005
Posts: 1587
Wow, the first DOS TAS... And it's Commander Keen, yay! Voting yes, because it was awesome.
Joined: 12/27/2005
Posts: 45
Location: Beauce, Québec, Canada
wow, 2 new systems in just 1 day, might be the greatest day of the tasvideos. Impressive yes vote!!! Dos game is now a reality... I'm so happy right now, you made my week!
Sorry, my english is really bad...
Joined: 12/10/2004
Posts: 82
Location: Ruotsi
This is not the first DOS TAS I think. http://tasvideos.org/forum/viewtopic.php?t=5279 Was submitted more than 3 years ago. Unless it doesn't count for some reason.
Senior Moderator
Joined: 8/4/2005
Posts: 5777
Location: Away
While it's technically not the first DOS TAS, it may well be the first DOS TAS made on an acceptable emulator. In other words, HOLY SHIT THIS IS BIG!
Warp wrote:
Edit: I think I understand now: It's my avatar, isn't it? It makes me look angry.