Upcoming Events
Seattle Game Conference
2/4 @ Seattle, WA

Casuality Europe
2/7 - 2/9 @ Amsterdam, Netherlands

Profiting in the Video Game Economy
2/16 @ New York, NY

nullarbor
2/23 @ Perth, Australia

More events...


Quick Stats
6090 people currently visiting GDNet.
1945 articles in the reference section.

Help us fight cancer!
Join SETI Team GDNet!



Link to us

Home » Books » Book Listing
  search:   
Books @ GameDev.net Jump to:
Game Programming books
All books
Game Programming All in One, 2nd Ed.
by Jonathan Harbour
Published July 2004
List Price: $49.99, Your Amazon.com Price: $32.99
Course PTR Price: $39.99
Average rating:
Amazon Sales Rank: 59,334

Buy it now: From Course PTR

Summary
Create your own high-caliber games with some of the same tools used by professional game developers! If you have a working knowledge of C or C++, then "Game Programming All in One, 2nd Edition" can get you started on your journey. It uses hands-on projects to explain each new subject and includes many sample programs to reinforce the material in each chapter. Begin by learning about cross-platform game programming, writing code that will run under Windows®, Linux®, Mac OS® X, and many other systems. Enhance your skills by working through the core features of the Allegro game library and writing code to load images, manipulate sprites, scroll the background, use double-buffering, read a joystick, detect collisions, and implement other core features of any game. You will gain experience by creating a complete game and adding features to it in each new chapter. You will also learn how to write a scrolling platform game and a vertical shooter.

Features

  • Includes everything needed to write complete games, including the compiler, editor, and game library
  • Accessible to beginning game programmers, yet includes high-level game theory, such as artificial intelligence, game physics, mathematics, algorithms, and multiplayer programming, which are integrated into the featured game.
  • A professional-level book that gives readers the skills they need to get a job in the game industry.

    Table of Contents
    Part 1: Introduction To Cross-Platform Game Programming
    1. Demystifying Game Development
    2. Getting Started with Dev-C++ and Allegro
    3. Basic 2D Graphics Programming with Allegro
    4. Writing Your First Allegro Game
    5. Programming The Keyboard, Mouse, and Joystick
    Part 2: 2D Game Theory, Design, and Programming
    6. Introduction To Game Design
    7. Basic Bitmap Handling and Blitting
    8. Basic Sprite Programming: Drawing Scaled, Flipped, Rotated, Pivoted, and Translucent Sprites
    9. Advanced Sprite Programming: Compiled Sprites, Collision Detection, and Animation
    10. Programming Tile-Based Backgrounds with Scrolling
    11. Timers, Interrupt Handlers, and Multi-threading
    12. Creating A Game World: Editing Tiles and Levels
    13. Vertical Scrolling "Arcade Games"
    14. Horizontal Scrolling "Platform Games"
    Part 3: Taking It To The Next Level
    15. Mastering The Audible Realm: Allegro's Sound Support
    16. Using Data Files To Store Game Resources
    17. Playing FLIC Movies
    18. Introduction to Artificial Intelligence
    19. The Mathematical Side of Games
    20. Introduction to Physics Modeling
    21. Publishing Your Game
    Appendices
    A: Chapter Quiz Answers
    B: Useful Tables
    C: Numbering Systems: Binary and Hexadecimal
    D: Recommended Books and Web Sites
    E: Configuring Allegro for Visual C++ and Other Compilers
    F: Compiling The Allegro Source Code
    G: Using the CD-ROM


  • Similar Books
    3D Game Programming All in One by Ken Finney
    Beginning OpenGL Game Programming by Dave Astle, Kevin Hawkins
    Programming Role Playing Games 2nd Ed by Jim Adams
    MultiPlayer Game Programming by Todd Barron

    Write an online review and share your thoughts with other members.
    Staff Reviews

    When my copy of Game Programming All In One arrived on my doorstep, my first thought was "why is Course Technology sending me all of these other books on game programming with OpenGL and shaders and Java and such. This book's got it all". Of course, this isn't the case. While Game Programming All In One is a sizable tome at 700 pages, it doesn't cover everything. It picks a couple of topics useful to beginners and covers them more comprehensively than other books of its type.

    First off, this book's all about 2D programming using the C language and the Allegro library. If you're not overly interested in 2D, C, or Allegro, you should probably look elsewhere. Thankfully, the Allegro library uses DirectX as a back-end, so if you're feeling particularly Windows-centric, this book will still serve your needs. In fact, Allegro runs on Windows, Mac OSX, and a half-dozen flavors of Unix, so it'd be a good start for your development. The book switches randomly between Windows and Linux for screenshots and builds, so if you're a Linux kinda person, this will serve your needs nicely.

    Unfortunately, this courtesy is not extended to Mac OSX. Other books I've reviewed, namely Focus on SDL and Beginning OpenGL Game Programming, had the same problem. They trumpet the cross-platform nature of the libraries they're teaching, but then proceed to ignore the largest non-Intel platform out there. It doesn't have to be a big focus about the book, but I'd like to eventually see a discussion of OSX build issues, endian-neutral programming, and other things that would crop up when programming across different platforms. At least Game Programming All In One covers Linux well, which wasn't done with the aforementioned books.

    Apart from a couple of design-centered chapters near the front, the bulk of this book is about Allegro. Just about every function call (even trivial ones, like the function that draws a horizontal line) gets an example program of its own. If you're a programming newbie who knows enough C to get by and wants to write a game, this would be a good place to start. The book assumes you're already familiar with C, so you should find yourself a C tutorial if your knowledge of C is wobbly.

    While the book occasionally digresses into vertical shooters and horizontal platform-jumpers, the bulk of the examples center around an evolutionary project called "Tank War", a two-player tank shooter in the spirit of the old Atari 2600 Combat. The game starts out small, displaying a couple of blocky rectangles for tanks. Later the blocky tanks are swapped for better-looking bitmaps. Then the bitmaps learn to rotate. After that, the game is changed to a split-screen view, gets sound, gets level-building via the third-party "Mappy" tile-editor, and the game ends up a fairly respectable little tank shooter. The coverage of the Mappy program is excellent and would be useful to anyone who needs 2D level-building in their projects.

    Apart from the short shrift given to OSX, my other complaints are minor. The final three chapters seem tacked-on and have very little to do with the "thread" of the book. Every chapter up to 17 is all about using C and Allegro and Mappy to design and build and enhance Tank War. Chapter 17, inexplicably, is a discussion of how to display Autodesk Animator files. While interesting, the book fails to mention that the Animator program has been discontinued for years, and no alternative ways to make Animator files are provided. The remaining chapters discuss AI and mathematics, but similarly have nothing to do with the progress made on the Tank War game. I would've traded all three of those chapters for a good chapter on how to get Tank War running on a network. Tank War would've been a natural for networking, but Game Programming All In One doesn't cover networking.

    If you are just getting started, and you know enough C to write simple text-based programs, and you're interested in writing 2D arcade style games that'll run on a variety of platforms, Game Programming All In One will take care of you. The last three chapters aren't as well chosen as the previous 16, but all that means is that you've got a good 550-page book rather than a good 700-page book.

    And that's more good material than most programming books I've read.




    Member Reviews
    I would say that it's an 2D Game Programming book all in one except networking. I don't know much about game programming but I was sure happy I chose this book as my first game programming book because it's a very good approach to game programming. Allegro and DevC++. I was surprised to see that this appears to be one of the few Allegro books out there. I can't find any other than this one but it's the best approach to game programming for beginners who know enough C language, probably equivalent to half a college class on C. DevC++ and Allegro are both free so you can just install them both from the CD and get started right away.

    I thought allegro programming was too easy because I looked at windows code before this book. Windows programming requires two pages of intimidating code to get you started while Allegro needs only a few lines. If you're a beginner and interested in the directx library or windows game programming, you should at least first start off with this book to have something easier on the eyes and at least get the concepts of programming a game. You can just pick it up and go much quicker than if you started programming in Windows. Allegro is also multiplatform so you can make programs for linux or other platforms.

    Aside from how Allegro is great gaming library, the author covers what you need to know to get started. When you need to advance, finish this book first. I wish it was in C++ but I guess I can use it when I start projects on my own. No networking but that can come from a different book.


    Hands down one of the best beginning game programming books on the market. By utilizing the allegro game engine and mappy map creator the author is able to take the reader through a wide array of game programming techniques while avoiding complex the complex code required by some platform specific libraries like directx. Allegro allows novice game programmers to forgo learning directx or other complex libraries and concentrate on actual game design.

    The author takes you from creating a simple combat-style vector game and enhancing it with each new technique learned until you come away with a full fledged multiplayer game with beatiful 2D graphics courtesy of SpriteLIB. In addition, the author discuss a wide range of topics from vectors, bitmaps, sprites, scrolling maps, and more. The reader can expect to come away from this book with the skills necessary to recreate many of the classic games from the 80's and 90's or create their own unique games.

    The one obvious absence in the book is networking your games.

    I definatley recommend this book to anyone who knows a little C and wants to get started writing games as quickly as possible.


    After reading all the reviews here on gamedev, it seemed like it was a pretty good book, so I thought I would try it. It is a very good book, and I would reccomend it to anyone who has a basic understanding of C/C++ and wants to move onto more advanced things. If I have one complaint, its that instead of improving one game the whole time, I would have rather have made a unique game for each topic covered, and then make one new, ultimate game at the end of the book using everything I have learned. And also as johnhattan said, the last few chapters are worthless.


    Great book! One bad thing though, is that all of the source is included in the book in snippets, and then reprinted at the end of the chapter. It really makes the book alot bigger than it has to be! Of course, this is the trend today in these beginning books, so no biggy. Worth the money, it gets my 5 stars.


    If this hadn't been a revision, I would have added networking, and agree it would have been a lot of fun too. Tank War should be a MP game with support for many players. However, the goal was to just cover the Allegro library. As far as I know, there is no networking library for Allegro, so it would have to be cross-platform sockets. I did cover pthreads, so I might have also covered sockets, but had a tough deadline. Had this been a new-title book with full compensation and writing schedule, it would have been fun to cover networking. I think there's a strong demand for more books on cross-platform programming, as it does away with all the logistics and lets you focus on game design and get out of engine mode. "DirectX" is not game programming, it's just another library! Allegro is absolutely AWESOME and I love using it. I hope to write about Allegro again in the coming year. The new version will be interesting if it is ever released, but being open source, the developers seem to be in a deadlock over features and direction. This could be because the current version of Allegro is already very solid and well done.




    I got this book thinking, i know i read a review of this, and that it wasnt that bad, so what the hell. I thought this book was good with discussing the allegro library very well, the author wrote the book in a fun manner, and he included lots of good pictures for his examples.
    Of course, there are things that could have been better. Like johnhattan said, a networking chapter would have been very good, and had he included one, well, this book would be 5 star.
    Even though the book uses c, It uses a c++ compiler, and all of his code isnt too c specific, so using c++ instead is VERY easy (I found myself doing it with every example just because I could).
    All in all a good book for learning the allegro library, and a must for any beginning programmer looking for a good starter book.


    All times are ET (US)


    Write an online review and share your thoughts with other members.
    Full details
    See the full details or purchase this book online at one of the links below:

      Course PTR
      Amazon.com
      Amazon.co.uk 
      Amazon.ca
      Amazon.de
      Amazon.fr