Most Helpful Customer Reviews
|
|
16 of 16 people found the following review helpful:
5.0 out of 5 stars
This is a great beginner's book, November 3, 2005
Let me begin by saying that I went through no less than five DirectX game programming books before checking out Miller's book on a friend's recommendation. Most of those other books (some of them decent) used C++ as their code base - as you'd expect. I spent my entire college career coding C++, so I was no stranger to the language. But I found most of those books difficult to crack. DirectX 3D programming in C++ is just not intuitive for beginners.
Enter Tom Miller's book. You should know I had very little experience programming in C# before I got this book. Now I'm a total convert. Middleware aside, I just don't think there's a faster, more intuitive way to create your own 3D games than using Managed DirectX.
I found Miller's book to be well written, clear, and having a reasonable learning curve. He starts you out slowly, and adds complexity with each game project. Add in the ease of reading and programming in C#, along with the Managed DirectX sample framework, and you're starting out ahead.
That is not to say that Miller's book is perfect. But I found most of the faults lie with Managed DirectX itself (although I suppose Miller should share some of the blame since he's the one creating it :) Because this is "new" technology, the MDX API keeps changing. Your code may not work from one SDK update to the next. Hopefully most of this will settle down with the release of Visual Studio .NET 2005.
If you're having trouble getting the source code on the CD to work, don't fret - it works. But depending on the version of the SDK you have installed, you may have to do some minor massaging of his code, specifically to his main game object. If you're annoyed by this, I don't know what to tell you. A quick Google search and some source code cut-and-paste had his code compiling with minimal effort. And this was when I knew NOTHING about C#, DirectX, the sample framework, or Miller's code.
I was able to create a fairly complex 3D puzzle game in about 4 months. Honestly, it turned out great and exceeded my expectations. And I based my original code on Miller's simplest game example. Granted by the end of development, there was almost nothing left of his original code. But that's what was so great about it - I could make some minor changes, compile, see what happened. Add a new object, compile, see what happened. I got instant feedback through the entire development process, and that made a HUGE difference for me. I never felt like I was programming into a black hole, hoping I'd get workable code at the end.
Again, this book (or Managed DirectX, for that matter) is not perfect. You will have to put in a little effort. But honestly, if you're not willing to put in the effort, why would you be interested in game programming? It's a labor of love, with an emphasis on labor. When it comes right down to it, I just don't think you can do better than this book if you have some programming experience and you'd like to try your hand at creating a 3D game.
|
|
|
22 of 24 people found the following review helpful:
4.0 out of 5 stars
very informative despite all of the errors, May 4, 2005
This is one of the only books in print which covers Managed DirectX game programming. Many of the other books on DirectX 9 still use C++, leaving those of us who prefer Managed code in the dark. Since Tom Miller is the author of the API, he is one of the best people to introduce you to this material. This book does have quite a few errors, but I still think it's one of the best books around. Despite all of the errata, I'm giving this book four stars because it provides a very comprehensive intro to DirectX 9 and 3D game programming.
If you don't have a good understanding of 3D math, I suggest looking for an additional textbook which covers matrices more comprehensively. Fortunately, DirectX reduces some very ugly matrix multiplication to look like simple math problems and I could see some people using DirectX without knowing much about trigonometry or matrix math.
This book also gave me several realizations:
1) I need a computer and graphics card with Pixel Shader 2.0.
2) I need to become a better artist so I can create my own meshes and skins or I have to pay someone else to be the artist.
In the beginning of the book, several programs are mentioned for creating meshes. In additional to those professional (and therefore expensive) packages, I thought I'd mention a program called MilkShape which only costs $25 to register and does a pretty good job of creating meshes. It exports into many formats, including DirectX.
Unlike Tom's previous book, the code in this book relies on the Sample Framework which ships with this version of DirectX. It does seem to remove some code requirements, but I think it also weighs down the code unnecessarily. I think in some ways it might have been easier to understand the code without the sample framework. The book isn't really a sequel to Tom's other book, but it's more like a repackaging of ideas with a focus on game programming.
The code does compile, but you need to make sure that you have the references to the October 2004 release (v9.02.3900). If you have multiple versions of DirectX, the framework is going to default to the newest version.
I do have to say that I felt the frustration of the previous poster who found the book to be full of errors. There are many incorrect diagrams, many instances of incorrect code, and even a small error in the section on matrix multiplication (a second edition is definitely needed). Fortunately the source code is correct, so you can always look at the code to find the necessary corrections. The book also claims that VB.Net code is provided in the source code, but I could not find it anywhere (it's all in C#). I'm not sure why the code was never translated, but perhaps it was the unsafe code (some of which could have been avoided using Marshal.SizeOf) or perhaps it's because there are many cases where a variable has the same name as a property but with a different case.
In the first project, there is at least one critical line of code that never shows up in the book but is in the source code. Most of the errors relate to references to "device" with need to be replaced with either "e.Device" or "sampleFramework.Device".
In the second project, the author leaves you on your own in the middle of the project to figure out the UI design. Normally I wouldn't have a problem with that, but the UI actually uses some classes which aren't discussed until the ensuing chapters. It would be more helpful if the source code provided an incremental copy of the code for each chapter which shows only what's been done up to that point (rather then just the final result). It would also help if at the end of each chapter you could have a definitive result to compile and display (if only to tell that you haven't missed something). As an aside, the collision detection routine is also less than perfect, since you can make the tank go through some walls as well as off the playing field.
The third project is not a complete game. It is simply a program that's been started and left for the user to finish (so I take issue with the claim on the back of the book that there are three complete games). The source code is no more complete than what's in the book (whereas the first two games are complete in the source code). But it does teach you some really cool stuff about the programmable pipeline, and if I had a card with pixel shader 2.0 I might be able to view it faster than 0.5 frames per second.
I think it would be helpful if the errata were published on line, as well as the source code (for a while I had lost the source code for Tom's previous book and couldn't find it anywhere on line). Tom's blog has some discussions, but I couldn't find errata or source code (nor could I find it on www.samspublishing.com). I've tried sending some comments to him on his blog, but I haven't heard back.
To sum it up, this is a great book despite all of the errors. Kudos to Tom for helping bring DirectX to those of use who want to write games using managed code.
|
|
|
15 of 16 people found the following review helpful:
5.0 out of 5 stars
Excellent book covering many topics (see below), March 13, 2005
C# and Managed DX9 are arguably the easiest way to write understandable 3-D code. You don't have to mess with all of the convoluted C++ jargon and strange uses of variables that are initialized after passing them to methods.
I cannot stress enough how useful this book has been in the current game I am working on (a 3-D RTS). The chapters on User Interface and how to write a custom GUI have been particularly useful with where i'm at now.
This book would have also saved me tons of time earlier in the development process as he goes over such simple things as handling device lost states (such as when the user minimizes your game) and how to display an accurate framerate (I wasted tons of time on that last year!).
Tom also shows you how to write networking code to make a multiplayer game as well as how to do things such as have a nice skybox, multiple levels, loading screens, player selection screens, font output, and even the use of Shaders (to make objects shiny). He also shows how to do mesh animation using mesh hierarchies - which is very important if you want your model to be able to have different moving parts that animate (such as for walking).
This book covers a wide breadth of topics that any new programmer to game design will find useful. If you pair it up with his Managed DX9 Kickstart book (which you should read first probably), it will take you to the point where you can write your own framework for just about any game you want to write. It does not cover really advanced topics such as pathfinding algorithms and fancy AI code, but it will give you a broad overview and allow you to write several fun games (I'm especially fond of Blockers).
|
|
|
Most Recent Customer Reviews
|