XNA Game Development: Brian O’Keefe

Brian O’Keefe gave the first Dead Coder Society presentation on his experience developing games using XNA and releasing on the Xbox 360. His first release is “Flipside“, and he’s working on another game right now. You can follow his recent developments at his website, Bokstuff.com. Feel free to read the collected notes from his presentation below:

XNA – Review and testing
Microsoft XNA is a set of development tools for developing on Xbox 360 (as well as for Windows, and Zune.) Visual Studio Express (the IDE) and XNA are free downloads. It’s easy to port and simple to hook up to debug on Xbox. The starter version of XNA only works for PC; pro version is ~$100/year (or free with MSDNAA, available through Stockton.) You can debug directly on Xbox360 via Ethernet cable. $1/$2.50/$5.00 are price-points for released indie games. You receive 70% of revenue (~67% after taxes. 30% goes to Microsoft.)

Once game is posted, there’s a peer-review process (no Microsoft employees, done through a forum.) If you release on Xbox Live, you can still release the PC version via other means (Steam). XNA redistributable package exists for Windows release.

There are two forums for testing on forums.xna.com: Playtest Feedback forum is just a general purpose feedback forum. Peer Review forum is specifically for game review prior to release. If you are going to test or peer review a game, you need to install a program onto your Xbox360 called XNA Game Studio Connect.
Peer review is primarily for crashes, not for “this isn’t fun” etc. A few people need to review it. If you have crashes, you cannot re-submit your game for a week, and when you do finally re-upload it, it goes to the end of the peer-review queue.

Gotchas to look out for in 360 development:
If you’re running the game and someone yanks the memory card out, things like that can’t cause a crash. If someone hits the “guide” button (button in the middle of the controller), the game should pause in the background. All controllers should work, etc. Must account for controller “dead zones” on analog sticks – the amount of throw the controller has when it gets old.
So-called “Evil checklist” for game acceptance (game needs to have these working), and “not-so-evil checklist” (not a release killer; left to the discretion of the testers (e.g. the text doesn’t render clearly on certain monitors)). If you fail, you need to wait a week to resubmit your game for retesting, but you can test as many times as you want. Incentive for the game-testers include a free game (release candidate, but still,) and you can get your game to the top of the queue. An interesting side note, Brian’s passed on the first try!

You can patch your games – it goes through the acceptance queue again. All existing customers get prompted for the new patched release.

XNA Framework and Game Development
Basic libraries for creating a game on Xbox: rendering, input from controller, sounds and networking. There’s no gamestate management and no particle effects. Another note: people develop libraries on top of XNA for network play and other things (p2p high score list was discussed.) No collision Detection built in to XNA default package.

Basic methods created when you create a new project:
Initialize, Load/Unload Content, Update, Draw For every frame, it calls Update, then Draw.
Brian’s State Management system:
Loading State, How to Play State, GamePlay State, etc… States for all major sections of gameplay, all being controlled by a State Manager class.

Programming for XBOX specific notes:

  • Apparently, branching logic in a shader is terrible for performance as it’s done by the video card. The inversion for the second half of the screen is a shader-inversion hack.
  • LoadContent handles everything – graphics, sounds, fonts, etc. On compilation, it compiles it into some arbitrary Microsoft format. You have sort of a resource file. You can create your own content types (e.g. maps)
  • You can have threads (up to 3 for three cores) if you need to separate some processing-intensive logic. Flipside didn’t use them, but could have.
  • Flipside was finished in five weeks total. It was powered through the whole time. Completed in march.
  • Made a particle manager that a state can have.
  • The “Foreach” for loop is a little more intensive than a regular for.
  • During development, it’s better to check the stuff in the checklist than doing everything at the end (i.e. pulling the memory card during a save and check for crash).
  • Trial allows you to play the game for 8 minutes. XNA handles this. You can create special modes of game play specifically for these 8 minutes. They specifically request for you to make the trial mode different.
  • Input Manager uses current controller state and saves previous controller state to detect compound actions (user presses button and releases, etc).
  • Sprite batches can do rotation and zoom, but if you want to do a transformation matrix, you have to actually open up the spritebatch which is costly in terms of performance.
  • Lastly, Brian is the best at his own game.

You can go to Brian’s site at BokStuff or Google his game Flipside. He showed us a Demo of his new game, Run Dead, and it’s looks fantastic!!

Leave a Reply

Your email address will not be published. Required fields are marked *