Programming
Programming Linux Games
Format: Paperback
Author: Loki Software
ReleaseDate: August, 2001
Publisher: No Starch Press
Rating:
Good beginning walkthrough for game programming
Although this book is dated (A lot of API evolution can occur in 4 years), it is probably the best introduction I have seen so far. There aren't enough books written about game programming for Linux. The book walks you through the creation of a simple, but full-featured game using mostly cross-platform APIs. It is elegantly written and easy to understand. Because of how much the libraries have changed, you will not be able to use all of the code directly, but it should not be difficult to look up the new function calls in the respective libraries' online documentations. It would be great if someone could write an update of the book. This book is not a one-stop place for all you need to know, but it is a good place to start and get you thinking. After reading the book, you should know what to look for to learn more.
Good into to SDL and Game Scripting. Horrible otherwise
This is where the book fails terribly. The book starts off ok with a good introduction of the various API's and is ok reading up untill chapter 6 "Programming Linux Audio". None of the audio samples will compile and the information about OpenAL is just plain wrong. First the function used to open a WAV file is no the corerct function to use for linux. The author uses the win32 version. This is just the start of the openAL errors. Minus one star!
Second the book's two websites (one of which no longer exists (Loki) ) contains no errata and no way to contact the author. The only information is avalible is a zip file of the books sample files (which do not compile of course). Minus two stars!
Ohter things about the book that did not work for me was the fact that the author uses C instead of C++. While C is still used for game development , most programmers are attempting to migrate to C++ and OOD. Books released about 1950 should reflect that!
Second the author uses Tcl as a game scripting engine. While I can agree to a point (based on the fact of the easy of implementation) the author should have used a common scripting engine such as Lua. (although the author does mention at the end of the book that Tcl was proably a bad idea.
Third the author should have introduced Autoconf very early in the book instead of waiting untill Chapter 10.
The main thing that I liked about the book was the good intro to programming with Linux in general. The topics of linux debugging and Makefiles I thought was good (assuming you have experince in these areas on other platfoms).
Also the coverage of SDL was a pretty good intro. .
Easy reading
But the steady rise of linux on fast, cheap hardware and the parallel rise of an open source community leads one to wonder if there are alternatives. The computer game market is dominated by dedicated game console platforms, like Sony's Playstation and Microsoft's XBox.
Which leads to this book. It has some of the ambience of the flashback to the 70s or 80s, when programmers in their spare time might gin up a cool game, which would then spread like a virus when word got out. Of course, you can use the book's advice to design a proprietary game. Nobody says you need give it away. The book's code examples are in C. Not Java, please note. While Java is good for some applications, typically in gaming, performance is always an issue, as measured by latency, for example. The book also does not mention C++. Pity. C++ compilers nowadays are usually as efficient as C compilers. Plus, if you want to code a game of any complexity (over 100 000 lines, say), then C scales badly, unless you use really strict design and coding standards. Overall, though, the book is well done. Very easy reading if you're experienced. Very little knowledge of graphics is required. The book is more about the back end design. Graphics is pushed out to OpenGL and similar packages.
|