Breathing New Life Into Old DirectDraw Games 274
An anonymous reader writes "I bought a bunch of old Wing Commander games for Windows, but they use DirectDraw, which Microsoft has deprecated. They don't work too well under Windows 7, so I ended up reimplementing ddraw.dll using OpenGL to output the games' graphics. I wrote an article describing the process and all the fun workarounds I had to come up with, and released all related source code for others to hack on."
There were some damn fine games in that era... (Score:5, Insightful)
Or you could (Score:3, Insightful)
use an older version of Windows in a virtual machine.
Re:heads up for combat soldiers' family and friend (Score:1, Insightful)
You must be a real hoot at parties.
Re:Or you could (Score:3, Insightful)
the only appeal of using a virtual machine was to a lazy developer WHO DIDN'T WANT TO DO IT RIGHT.
thanks story submitter... glad someone out there still understands, and has some pride left.
Re:Or you could (Score:5, Insightful)
But to run Wing Commander on modern hardware, it doesn't need to be optimal. 80/20 rule dude.
Re:Wine? (Score:5, Insightful)
what seriously pisses me off with WINE is that something works with one version of it, but breaks in the next... the database is almost useless with regards to being kept up to date and I'm too old for all this hassle now... and there's TOO much emphasis on having the very latest game running on it to the detriment of making sure other games don't become broken by changes made to support the latest and greatest...
Re:Who says DirectDraw is going away? (Score:5, Insightful)
Re:Or you could (Score:5, Insightful)
No, I wouldn't have done this if you had payed me; I have my own interests and passions. I'm not at all interested in graphics programming or for that matter video games, though, apparently someone is and I think it's great that he saw a problem and decided to attempt to find a solution for it.
This is what being a geek is all about. Bravo.
Re:Wine? (Score:5, Insightful)
Re:I wonder about this (Score:3, Insightful)
Well, yes, I'm not entirely surprised your system has trouble pushing tens of gigabits of data whilst reading from a ten TB dataset and live-rendering 3D on a bank of 3 x 3 3200x1600 screens. All this on a side project "when you find the time", too, impressive. To the best of my calculations you'd have what, 7 PCI-E slots?
Re:Wine? (Score:2, Insightful)
You aren't really proposing an alternative though... Automated testing is practically impossible and manual testing is a huge, huge job if it means play testing thousands of games before every release. just saying "don't make mistakes" is not useful.
Re:Or you could (Score:5, Insightful)
It's only already done if the only ddraw game you want to play is Wing Commander 1-4 (Windows versions). And only with conventional monitor setups and only if you never want to capture the window content, due to the kludges involved. And if you can stand the known bugs he mentioned, eg. the blinking screen effect described in Wing Commander 4.
So basically, it's only already done if you want a suboptimal experience. But you were just talking about how you wanted an optimal solution, and how a solution that basically works better than this is "never" the optimal solution. To be fair, it sounds like 1-3 work pretty well, but for 4 you have to put up with some crap. And any other ddraw game is unlikely to work all that well.
This is a fun an interesting reverse engineering project. Stop being such a prick about it.
Re:Wine? (Score:5, Insightful)
Automated testing of all the applications is pretty much a nonstarter. However, automated regression testing to make sure function calls with the same arguments in the same context don't give different results just because you debugged a different set of arguments or in a different environment are easy to do with a proper test harness. The hard part is mapping the applications to test cases, but that's not impossible, just time consuming and somewhat difficult.
Re:heads up for combat soldiers' family and friend (Score:1, Insightful)
He said "At the time", and since he bought it in 1998 - at the time means that his friend was in war in 1998 ... so your explanation is very improbable ...
It doesn't matter. Reason of my posting is to correct the prejudice about my country. In 1998 there were no combat zones in Bosnia and his friend could not be in danger in any way that could be presented in a game about war.
Direct2D is useless for this (Score:1, Insightful)
Maybe you should take a look at what Direct2D and DirectDraw does before making some silly assumption that Direct2D is more suitable for simulating DirectDraw behavior.
Direct2D effectively acts as a hardware acclerated scanline renderer, so it is more comparable to GDI than DirectDraw. DirectDraw surfaces are actually much closer in design to Direct3D and OpenGL textures. So your real question should be why he didn't chose Direct3D instead. My guess is that he liked OpenGL's API better and this is about fun after all - nobody was paying him.
Re:Wine? (Score:3, Insightful)
I think I would be really worth it, to stop developing more features for a while and add as many regression tests as possible to the project. So that the project gains stability. Since in the end, the real success is always determined by the end user.
Re:heads up for combat soldiers' family and friend (Score:3, Insightful)
Comment removed (Score:3, Insightful)
Re:Wine? (Score:2, Insightful)
http://bugs.winehq.org/show_bug.cgi?id=421 [winehq.org]
is a ridiculous wine bug.
Oh stop (Score:5, Insightful)
The "Back in the day things were so much better," stuff gets annoying no matter what it is about and games are no exception. Were there good games back in the day? Sure were. Guess what? There were also bad ones, you just don't remember them as well. This is in part because our memory tends to deliberately filter out bad experience, but mainly because good games you played a ton, bad games got set aside.
Know what else? There are good games now. The modern graphics and so on have not stopped people form being able to make good games.
Also I don't like this elitist "purist" thing that people pretend to of "Oh I don't even like the graphics, I just want good gameplay." Guess what? The graphics and sound can well be a part of that. When games are visually appealing it can add to the immersivness. It is easier to lose yourself in a convincing world.
So stop getting all "Get off my lawn," about games. There are great old games and you can still enjoy them with the help of emulators. However don't hate on new games just because they look better. That is not a bad thing, it is a good thing.
Re:Oh SNAP! (Score:3, Insightful)
You are in with the old crowd here. S.T.A.L.K.E.R. is a few years old, except for Pripyat, and even then the graphics are the most dated part of the game.
And, yes, gameplay is what really matters. I still break out M.U.L.E. occasionally, and, guess who joins? My hardcore gaming kids, aged 8, 12, and 14.
Read that again: Game play IS the top priority in a game's longevity.
M.U.L.E.
Age of Empires
Age of Mythology
DOOM/DOOM2
Freelancer
Serious Sam
Oblivion
Rainbow Six 3: Raven Shield
Counter Strike (Half-Life1 AND 2 versions)
Quake, Quake2 CTF
These are just a few that drive home the "game play matters" idea. Notice how almost all of those are over 5 years old? My guess is that it is that we are in the era of "Milk the online play", and past the "Make it worthy of replay" era.
Re:Wine? (Score:3, Insightful)
Have you ever tried to use Wine in Windows? Last time I attempted was a couple years ago, but I remember spending hours trying to get the damn thing to work, only to eventually just give up. Wine is great on Linux, but the processes to get it installed and to use it for Windows could be greatly improved.
Re:Or you could (Score:3, Insightful)
You're kidding me. The effort to get an old computer, set it up, install the crappy old OS from slow floppies/CDs, mess around with limited memory and IRQs and realising at the last minute that you can't just transfer over wireless or USB... it'd be cheap if your time is worth nothing. Otherwise, running a VM (or just about any other method) is probably faster. I'd love another physical amiga, but I know I'd never use it, next to having a copy of UAE.
Re:There were some damn fine games in that era... (Score:3, Insightful)
...and we didn't need gimmicks like motion controllers, photo-realistic graphics and high framerates to enjoy them.
Oh please. Wing Commander was that game you played when you had just dumped a large sum of money into a new computer system and wanted to show it off. VGA graphics, expanded memory, Sound Blaster, megabytes of graphics, multi-media CD-ROM, FMV, etc. That was the one game you always had an optimized boot floppy around for. "Didn't need gimmicks*" my ass, I bet you bought the speech pack for it!
The games were fun, but let's be realistic, none of the Wing Commander games were intended for modest machines.