Friday, 14 May 2010

It has been in our minds for quite some time and now finally it has become reality: Penumbra:Overture and the HPL1 Engine are now open source! In case that is all you need to know, then head straight to:http://GitHhub.com/FrictionalGamesto get your hands on it!

For more information just keep on reading.

Penumbra: OvertureFirst of all I would like to stress the fact that this open source release does not make Penumbra: Overture free in anyway. All assets (except a few that are part of the engine) are still under the same copyright as before. The thing that is free is the source code for the executable which is now released under the GPL version 3 licence.

The code for Penumbra: Overture is a continuation of the one used for the tech demo + some addition for the not so long lived Robo Hatch project. It also contains some code from Unbirth, giving it quite some history. This history means that the code is far from clean and as expected quite hackish in places. That said, it should have a few interesting bits, the major probably being the physicsal interaction system. This system is not the latest version in the Penumbra series and misses something like rotation. These features should be farily easily to add though.

It is also important to note that Penumbra: Oveture source will not run Black Plague or Requiem. AI for the infected, GUI elements, etc are all missing, but all needed to implement them is present in the engine code (in case anybody is up for the challenge).

HPL1 EngineFor my part, the biggest part of this release is the engine itself. This is engine that has powered all of the Penumbra games and it even includes the stuff used to create the 2D platformer Energetic. The engine code was started in December 2004 and was actively developed until early 2008. After that only smaller fixes where made to it.

The transition from 2D to 3D and the fact that it was my first stab at a full 3D engine, makes the code quite patchy (and downright horrible) in places. This is especially true for some old and low level parts like the sound and input handlers which have evolved anything but gracefully. Later parts are often cleaner and nicer, but the code is not without its share of quick-and-dirty-hacks.

When it comes to interesting features, I think the following are the most prominent:

Physics sound system. This is all the code that is used to play and tweak the sounds heard during physics interactions (bumping, sliding, etc). A lot of work has gone into the system and is the result of a combined effort between me and Jens (who does all sounds) for several years.

Stencil shadow volumes. The shadow system in the engine is quite robust and can work on pretty much any mesh, something that shadow volumes usually don't. It is far from state of the art these days (when shadow maps rules), but should provide nice info for the curious.

Serialize Class system. This is code used to easily save and load classes to disk. It is very useful when creating a save system for games.

The engine contains tons of more stuff (almost 100k lines of code), but these are the most interesting stuff I could think of right now. I am sure there is more for awaiting to those brave enough to explore its dark depths!

Finally, it is also worth noting that this is the latest and final version of the HPL1 engine. It is the beast that powers all games of the Penumbra series.

OALWrapperThis library is made almost entirely by our tool programmer Luis, who actually started out doing work for us on the OpenAL sound implementation. This library is simple and easy way of accessing the OpenAL functionality and was made since there is a strange lack of free sound libraries. This is also the only part of the open source release that we will continue to update and we hope that others will find it useful and contribute themselves!

Questions and SupportAs we are a small company and already swamped with work, do not expect us to do full time support on this. We will try and help as much as possible, but we also hope that a community will form helping each other out.

This is the place to go for more technical information and please ask any lengthy / technical question there instead this blog.

CreditsI must also stress that I am not very experience managing an Open Source project and most work in making it happen is due to Edward Rudd, who is also responsible for the Linux and Mac ports of Penumbra. So big thanks to him!

End notesWe are extremely interested in seeing what people will be able to do with this! Open source releases of other games have spawned very exciting stuff and we hope this release will do that too. This means we are very interested in what people are doing with it. So whether you plan to do a full blown mod, or just check the code for learning purposes be sure to tell us about it!

48 comments:

This is awesome! I love seeing projects like these go open source. Perhaps this will spawn some First Person Shooters with interesting twists thanks to the physics system, or maybe some nice puzzle games.

By the way, the code in the PenumbraOverture repository, I guess it's mostly there for reference? Will you get a working game if you use the game data from a purchased copy of Penumbra: Overture?

The only thing that actually bugs me about this release is the choice of revision control. Git isn't the greatest choice if you want to encourage developers from all platforms (being designed especially for Unix, it doesn't have the greatest performance on Windows, nor can it integrate very nicely with Windows IDEs...).

Mercurial or Bazaar would have been better choices. Oh well, I guess its too late now...

Yeah Windows Git isn't that bad anymore.. I agree that it used to be. But I myself have used msysgit and tortoisegit in a windows VM to track code changes for some .NET C# SQL Stored Procedures. And I know there is at least one IDE integration piece for Visual Studio. Though I don't really use the integrated IDE version control stuff anymore I just break out and use either gitg or GitX (depending on if I'm in Linux or Mac OS X).

leighman:Fiend: Already got entire source out at one point, but I assume it is gone now. Could put up if I can find on my harddrive. Awful code though :)Energetic: Not sure if I got the code anywhere.In any case, the code for these projects are pretty damn bad :P So not sure they would be helpful.

I am happy to see that you hit you monetary mark as well as the fact that the source code is now open source, now its up to the community to do something interesting with it, thank you for sharing with the open source community.

Thanks, this is awesome! :) Can you please provide a document describing how to build Penumbra: Overture, combining the open-source code with the resources from a purchased game? This would be really good. I guess it's not too difficult, and I hope this is something you intend to be possible.

Well, it's "Open Source" but it's definitely not Free Software, please don't associate GNU with Open Source. GNU represents Free Software as in User Freedom, GNU does not represent Open Source. Linus Torvalds and friends represent Open Source. The non-profit "Free Software Foundation", the non-profit "GNU Project", and the author of the GPL Richard Stallman, represent GNU and Free Software, please either take down the GNU image or change your terminology and fully liberate Penumbra, otherwise what you are doing isn't very helpful for our community.

Thomas:I am simply interested in why the developers didn't release the entire game. It can be released and still not run unless the CD is present, or it requires a code in the game retail box (this is tricky but can be done with a small part of the game being a binary blob that cannot be changed.) I think if any useful part of the game is still proprietary then it doesn't do much good.

Believe me it does some good -- like if this release allows mods to be easily made -- but it doesn't do enough to brag about it. And I might be unclear on the amount released, and what could be released in the future.

Also, the new image implies you think GNU is evil, which is contradictory. I think people will be confused. Wouldn't it be better to use the GNU head and just say "Free/Open Source" or "FOSS", or the easiest way would to just use Tux.

Though, Tux is the mascot for the Linux Kernel, not the GNU operating system, which is what Penumbra is available on, that's semantics.

Also, it would be cool to see the id Software approach applied to Penumbra, i.e. releasing source for each game a few years after it was put on the market.

InaTux:So all is clear. Perhaps this sentence had you confused:"AI for the infected, GUI elements, etc are all missing [...]"

Note that nothing is missing from overture, but it simply means that the Black Plague and Requiem executables contains stuff not present in Overture exe. If this source release works out well, then perhaps we will release the source for BP and Requiem too!

Thomas:Than that's great! I really don't know why companies don't just release their older work. It doesn't benefit competitors, as the newer stuff is the cooler stuff and is what people want.

My opinion on the matter is of two things:

It is okay to make money on software, actually absolutely essential for good quality software. Games are toys not tools, so they are less important, thus we need the source less. But I am one of those people who don't use software that I can't verify is safe, although I have played Penumbra in the past :) And I will now likely buy the collection once I examine the source code.

By the by, porting games to GNU/Linux is all the buzz right now, apparently the developers of Osmos had/having problems porting their game. http://linuxlock.blogspot.com/2010/05/why-games-dont-get-ported-to-linuxa.html

Now would be a great time for the developers to express their opinions on porting the game. It's a great way to get publicity for this, I will even give it publicity one way or another.

InaTux, let me explain a few things:"I really don't know why companies don't just release their older work. It doesn't benefit competitors, as the newer stuff is the cooler stuff and is what people want."

It's not true, because (1) there are always people willing to buy an older game, and (2) the new stuff may be cooler on the surface, but this is just makeup - under the hood, the programming principles and techniques don't change at the same pace. Not even close. For example, the BSP tree algorithm that some games use today, was used in the days of the original DOOM.

So, when someone releases the SDK, one can only say thanks, especially if the code is documented. The SDK is not useful only for the people creating mods, but also to anyone learning game programming.

That's why Thomas was careful, and kind enough to warn us:

"This history means that the code is far from clean and as expected quite hackish in places.

But, take a note:

"That said, it should have a few interesting bits, the major probably being the physical interaction system. This system is not the latest version in the Penumbra series and misses something like rotation. These features should be farily easily to add though."

The Penumbra's physics system is quite the competitive feature, one of the more important features of the game, and one that many modern games don't do so well.So it was quite brave to release this to public domain, even if it's incomplete.

This discussion seems pointless to me. Correct me if I'm wrong: the whole HPL1 engine was released, it is now free and open-source and it's in the hands of the community. However, HPL1 is not Penumbra; Penumbra is built on top of HPL1. So Penumbra is not free or open-source; HPL1 is.

Anyway, I say thanks even though I'll probably not use it; but I'm sure lots of people out there who are thinking about becoming game developers will have a great and fun time digging through it. And that'll probably mean great new games in the future, so you did a nice favor for all of us.

Anonymous (19 May 2010 22:46):Some people develop one thing and continue to use it in newer products, that's true. If a company authors a game engine, and 5 years later that company is still making games based on the same -- and not much improved -- engine, releasing source code would be a problem for them. But this is simply not the case for most companies.

Example: Compare id Tech 2 to id Tech 4, there are improvements that competitors can gain from, that's why id Software hasn't released it. Once id Tech 5 is out, it would probably be okay to release it (which Carmack said that he plans to petition Zenimax to release the id Tech 4 source upon the release of Rage).

id Software releasing these engines doesn't appear to be hurting id Software, it only seems to be helping them with their image of a good gaming company.

Thomas:To clarify, most of the Free Software community and I appreciate the liberation of Penumbra, even if some of it remains proprietary (most of us using GNU/Linux are using the proprietary kernel drivers after all).

And the Wii-mote controls are awesome.

I am curious though...

Is Penumbra now as FOSS as -- let's say -- Urban Terror?(which I believe also has proprietary assets)

And what do you exactly mean by "assets"?(I believe in Urban Terror the proprietary assets are some textures, scripts, and some utilities for controlling the id Tech 3 engine as well as their modifications to the engine.)

Everyone should stop comparing any part of the game industry to id Software and John Carmack. Of course He can afford to release all of His source code a few years later... He is fucking John Carmack. He has been the sole creator of most computer graphics breakthroughs since the early 90s. He is not your average game developer. And His hobby is rocket science... seriously.

I think most developers do not release their code for the following reasons: 1) It is embarrassing. No programmer is proud of every line of code they write in a game. There are always a few bits of elegant, mindblowing, engenious code, but most of it is not so. Games are filled with dirty hacks and workarounds to just get things to work right and to meet milestones. 2) It removes the value and magic of the game. You would no enjoy slimjims if you saw how they were made. 3) Fuck You. It's my code. I worked damn hard to get here and I'm not giving you shit. Fuck You. Fuck You.

Thanks for releasing this!!!! You put all the non-open developers to shame by bearing your soul like this.