WolfGL, Wolfenstein and Spear of Destiny port to the Linux platforms using OpenGL

WolfGL is a famous DOS game from 1992 created by id Software. This is an attempt to port the source (released in 1995) to Linux.

Some time ago ID Software released the source code for their old Wolfenstein game, it was the first FPS game I can remember, with very cool graphics at the time it was released but not very nice for today's standards.

I don't know the reason why nobody had any interest in it, I've seen several ports of Hexen, Heretic and Doom but nobody did a Wolfenstein port. Maybe that's because the code was very complicated and required a lot of changes:


· It was a 16 bit program and most pointers were just unsigned shorts.
· There are several assembler routines.
· Drawing the 2D graphics is very complicated because of the VGA planes.
· Memory management is more complicated than it needs to be now.


The developer of WolfGL, a port of id Software's classic Wolfenstein 3D, thinks not. In short, no one else seemed willing to do it -- probably, he theorizes, because the source code released by id was significantly more complicated to work with than Doom's -- so he did it.

Fans who miss roaming the halls of Castle Wolfenstein, blasting Nazis and groping every brick for secret passages that led to golden crosses, treasure chests overflowing with coins, and the massive chaingun owe it to nostalgia to download WolfGL.

Like the protagonist of a sappy Disney movie, WolfGL asks that you love it for what it is: Wolfenstein 3D with a slightly brighter coat of paint. Go in with these expectations, and you'll have a great time.

So I decided to take some time and work on a simple conversion, it only took me about 1 week to be able to play the game plus another week just to fix the menus and a few other details. I guess that the best way to describe it would be to call it a 'hack', it still has a lot of unneccessary code and the rendering loop is almost not optimized but I can get 70 fps at 800x600 with my P2 and Riva TNT system.

My goal while doing the conversion was to keep the game as close to the original as possible, I know how to add lightmaps and other nice effects but that's not what I wanted to do. The only improvements to the code was the ability to play more than 1 digital sound effect at the same time and I changed the savegame file format. I've also decided to use OpenGL for the graphics so you'll get a bilinear filtering for the walls, and the sprites will look a little better with the increased resolution.

While the core of the 3D rendering code was done in assembler, you can get most of the information you need to know (like the location of the walls and which textures to use) from the C parts. As the game map is divided in areas connected by doors, I wrote a simple loop to draw all areas that are connected to where the player is.

The game already keeps track of that information, so I could easily know what needs to be drawn each frame and ended up with a very low triangle count per frame.


Screenshots:




Get Chitika | Premium

If you liked this article, subscribe to the feed by clickingthe image below to keep informed about new contents of the blog:

Share on Google Plus

About Giampaolo Rossi.

Fond of computer and video games. Stay informed of the latest news on games for Linux and Android. The future of gaming is in Linux. All you need to know about How to play Windows games on Linux.
    Blogger Comment
    Facebook Comment

0 commenti:

Post a Comment

Latest Posts.

Random Posts