1 2
17 18
Post subject: Hourglass, for Windows TASing
upthorn
He/Him
Emulator Coder, Active player (391)
Joined: 3/24/2006
Posts: 1802
Hourglass, for windows TASing, is available here: http://code.google.com/p/hourglass-win32/downloads/list Description page: http://code.google.com/p/hourglass-win32/ Original Post
Upthorn wrote:
Yes, this is yet another PC game TAS project. The difference here, is that this project has actually been in the works for several months, unannounced. And, in fact, already has some promising results. I'm being sparse with the details because this isn't really my project, and I'm not sure how much of a surprise the project lead wants it to be. However, with all the recent hub-bub about this sort of thing, I thought there should be at least some announcement to avoid massive and unnecessary duplication of effort. Surely things will get done sooner if we concentrate our efforts on one thing than if we each work on a different thing.
How fleeting are all human passions compared with the massive continuity of ducks.
Player (150)
Joined: 11/27/2004
Posts: 688
Location: WA State, USA
Impressive. Most impressive. (For those unable/unwilling to download the video, it contains short TASes of Bunny Must Die, Cave Story (Egg Corridor), and Eversion (Level 1).)
Nach wrote:
I also used to wake up every morning, open my curtains, and see the twin towers. And then one day, wasn't able to anymore, I'll never forget that.
gia
Player (109)
Joined: 5/3/2006
Posts: 223
Should have asked him first :P Now I would like more info.
upthorn
He/Him
Emulator Coder, Active player (391)
Joined: 3/24/2006
Posts: 1802
Gia: I did ask before making the announcement. He said he didn't mind, and the only real reason he had for keeping it secret was laziness. Still, I'd rather keep public details to a bit of a minimum. People who wish to contribute, of course, may contact me via private message on forums or IRC for further information. The basic idea is to hook the Windows system and DirectX DLL functions for things like sleep, time, input, and display, to fake determinism. Though this explanation is, as far as I can tell, greatly simplified compared to what has been necessary. Issues so far have been compatibility between different windows versions (movies that work in XP almost always work on any XP system, but playing back on Vista is far from guaranteed, and trying to run under 2000 results in immediate crashing), difficulty in dealing with games that do not update the screen all at once, and some troubles with wait loops. Additionally, savestates are not compatible between sessions due to the way Windows manages Handle resources, so when a game is closed and reopened, the movie must be played back in fast forward to refresh any savestates. Furthermore, as I understand it, there are some additional difficulties with thread timings that have yet to be worked out. There are probably other limitations, as well, but I haven't studied the way it works well enough to properly determine what they are.
How fleeting are all human passions compared with the massive continuity of ducks.
Joined: 7/2/2007
Posts: 3960
Oooh, looking good! I don't have the Windows skills required to be of help here, but I wish you all the best. (I'm highly amused that the "ability to walk to the right" relic was skipped in BMD)
Pyrel - an open-source rewrite of the Angband roguelike game in Python.
Player (6)
Joined: 10/25/2009
Posts: 22
I am green with envy that someone has beaten me to it. However, I'll be following this closely and possibly even contribute at some point.
Joined: 1/3/2006
Posts: 334
What are the technical limitations for the game wehn you say "simple" windows games? At what point does "complex" begin?
Lex
Joined: 6/25/2007
Posts: 732
Location: Vancouver, British Columbia, Canada
Awesome!!! The complications you've found sound like pretty detrimental problems though. They sound very hard to work around.
Emulator Coder, Skilled player (1310)
Joined: 12/21/2004
Posts: 2687
I guess I might as well admit to being the mystery project lead (before things get too awkward here). And I'll add a few more details for those who are curious (I won't bother withholding very much information, since surprising people later is not really my goal):
  • It records keyboard input per frame to a movie file. This isn't an AVI-editing based approach.
  • All of the usual TASing tools are present. This includes pause, frame advance, savestates, (really-)fast-forward, read-only movie toggle, RAM watch, and AVI dumping. There's no Lua support yet but that's surely possible.
  • Eversion is an SDL game, so hopefully that shows that this isn't limited to only DirectX games.
  • La-Mulana is working quite well in addition to the games shown in the above demo AVI. Various other games (such as IWBTG and Iji) are getting close.
  • There's no kernel-level programming involved here. It doesn't run any special drivers or even use any windows hooks. There's also no emulation, it's simply running the game natively.
  • There is no game-specific hacking or reverse-engineering going on (not even for savestates). The program tries to do the same general-purpose thing for all games (which does not involve changing/transforming the game's code, by the way) and that either works for the game or it doesn't.
  • It's limited to "simple" windows games at the moment partly because each technology (directx, opengl, etc.) has to be supported separately and it's easiest for me to focus on the technologies used by simple and freely-available games first. But I would say that games definitely become too complex to support at the point where they involve online integration and DRM and cheat-detector agents... I really don't want to deal with that stuff. And things that aren't very game-like probably won't be supported either, so this program isn't going to be able to TAS itself anytime soon. Finally, in the event that I am unable to solve "the multithreading problem" then this approach might be forever limited to games that do not make extensive use of multithreading.
  • About the complications mentioned, they are hard problems but I think that all of them can be worked around and some games will still be completely TASable even in the worst case that none of them are solved.
  • My guess is that eventually a true x86 emulator (or some VM-based solution) will surpass this in reliability and TASing utility, and if anyone else is working on a project like that, I hope they will continue so that we can reach that point. I think this is probably a more workable solution for the purpose of at least making some of these windows games TASable in the near-term future, however.
  • It's a very small and simple project so far (with very few if any library dependencies) compared to just about any emulator out there. I plan to open-source this thing, as soon as I get it presentable and work out whatever kinks I'm currently working on. I won't make any promises about how soon that will happen, though.
Player (6)
Joined: 10/25/2009
Posts: 22
I have mentioned here why I don't think that a VM is viable for practical TASing.
Emulator Coder, Skilled player (1310)
Joined: 12/21/2004
Posts: 2687
CyberShadow wrote:
I have mentioned here why I don't think that a VM is viable for practical TASing.
OK. Those are good points, although I think a VM could be given special modifications to make it more practical for TASing. But it would have its disadvantages anyway... There's a reason I didn't go with that approach either. You're definitely right about the speed advantage of doing it this way: Cave Story playing out at 5000+ frames/second has to be seen to be believed, and you probably can't get that sort of speed any other way. (It might sound useless to be able to go that fast, but believe me, it saves boatloads of time while TASing, albeit partly due to one of the aforementioned limitations of savestates.)
juef
He/Him
Player (154)
Joined: 1/29/2007
Posts: 208
Location: Québec, Canada
This is incredible! Congratulations to nitsuja and all involved, this thing is HUGE!!!
Joined: 11/11/2006
Posts: 1235
Location: United Kingdom
Might I suggest a name for this program? Hourglass. (Since hourglasses are associated with time and this doesn't actually emulate anything as far as I can tell, instead working as a wrapper for the game)
<adelikat> I am annoyed at my irc statements ending up in forums & sigs
adelikat
He/Him
Emulator Coder, Site Developer, Site Owner, Expert player (3573)
Joined: 11/3/2004
Posts: 4754
Location: Tennessee
Raiscan wrote:
Might I suggest a name for this program? Hourglass.
Seconded.
It's hard to look this good. My TAS projects
Emulator Coder
Joined: 10/9/2004
Posts: 453
Location: Norway
How would this work in conjuction with say DosBox (via D-Fend Reloaded) emulating older DOS games?
Emulator Coder, Skilled player (1310)
Joined: 12/21/2004
Posts: 2687
TNSe wrote:
How would this work in conjuction with say DosBox (via D-Fend Reloaded) emulating older DOS games?
This sort of thing could in theory be used to TAS any non-rerecording emulator that runs on Windows. If the emulator starts up in a simple enough way (like, it automatically starts running a game when it opens) then there's a small chance that it's supported already. However, it would probably take a lot of extra effort to make it actually work. Emulators generally fit into the "not really a game" category and there are some major issues that would need to be solved first to allow such programs to work.
Raiscan wrote:
Might I suggest a name for this program? Hourglass.
Hmm... maybe. Although time is only one of the aspects of this (savestates and movie/AVI support being other major things that are perhaps less common than time alteration). Right now I'm simply calling it "winTASer" which might do but I suppose it's not very creative. Maybe "Hourglass" is better... does anyone have any other suggestions?
Senior Moderator
Joined: 8/4/2005
Posts: 5777
Location: Away
I think "Hourglass" is a great name.
Warp wrote:
Edit: I think I understand now: It's my avatar, isn't it? It makes me look angry.
Emulator Coder
Joined: 10/9/2004
Posts: 453
Location: Norway
WinTAGE (Tool-Assisted-Gaming-Evironment?)
nitsuja wrote:
If the emulator starts up in a simple enough way (like, it automatically starts running a game when it opens) then there's a small chance that it's supported already.
I was more thinking in the line of using the GUI D-Fend Reloaded has to launch games into Tool Assisted mode. D-Fend Reloaded is a frontend for launching old DOS games, Windows games and SCUMM games. Incorporating it directly into this could possibly improve some conformity in starting & playing back a TAS.
Joined: 1/26/2009
Posts: 558
Location: Canada - Québec
TNSe wrote:
WinTAGE (Tool-Assisted-Gaming-Evironment?)
Sound interesting. But... hmm, does this program could run on ReactOS? If it is, I'm sure that there could be a way to design our own TAS-OS, just like you guys were talking in the previous topic.
Senior Moderator
Joined: 8/4/2005
Posts: 5777
Location: Away
I would rather not complicate things that much. A "TAS OS" would require writing drivers for hardware devices, which is something bad enough that people don't want to do this for popular operating systems.
Warp wrote:
Edit: I think I understand now: It's my avatar, isn't it? It makes me look angry.
Joined: 1/26/2009
Posts: 558
Location: Canada - Québec
moozooh wrote:
I would rather not complicate things that much. A "TAS OS" would require writing drivers for hardware devices, which is something bad enough that people don't want to do this for popular operating systems.
The purpose would be to run the OS in a Virtual Machine, so we can simply get the current default build and adding the additionnal program for TASing, etc... This might solve comptability problem for particuliar game and at least if someone is looking for playing thought these movie file, they won't have to buy and configure these popular OS. (simply downloading the already all-configured "TAS-OS" should be enought and easier for portability). edith: fixed some non-sense sentence
Skilled player (1444)
Joined: 7/15/2007
Posts: 1468
Location: Sweden
This sounds fantastic, I can't wait for when this is all stable. Dying to see a TAS of Elastomania :)
Agare Bagare Kopparslagare
Senior Moderator
Joined: 8/4/2005
Posts: 5777
Location: Away
Sorry to disappoint you, but… <moozooh> Upth: i don't remember, have i asked you about elma compatibility yet? <Upthorn> moozooh: elma is not compatible. <moozooh> aww!!!! I wanted to try it myself. :\
Warp wrote:
Edit: I think I understand now: It's my avatar, isn't it? It makes me look angry.
upthorn
He/Him
Emulator Coder, Active player (391)
Joined: 3/24/2006
Posts: 1802
moozooh wrote:
Sorry to disappoint you, but… <moozooh> Upth: i don't remember, have i asked you about elma compatibility yet? <Upthorn> moozooh: elma is not compatible. <moozooh> aww!!!! I wanted to try it myself. :\
Keep in mind that this is with the current alpha version. There's no telling whether or not it will be compatible when more work has been put in.
How fleeting are all human passions compared with the massive continuity of ducks.
Post subject: 1000 posts!
Skilled player (1416)
Joined: 10/27/2004
Posts: 1978
Location: Making an escape
I shall spend my 1000th post here to praise this project. This is indeed looking rather neat. Can't wait for more! Good to see the old version of Eversion being used (the new music stinks). I can only hope that Eternal Daughter works here as well.
A hundred years from now, they will gaze upon my work and marvel at my skills but never know my name. And that will be good enough for me.
1 2
17 18