It's running on the Xbox, too.

jwatte's picture

As I've mentioned at times, I sometimes scratch my coding itch by hacking around with Microsoft XNA Game Studio for Visual Studio Pro 2005 (now that's a mouthful!). The cool thing with it is that you can write games that run both on Xbox 360 and regular PCs. Recently, I got a new project up and running on the Xbox, and here's a screen shot.

screen shot

What you might not see, but is interesting, are the following bits and pieces:

  • The terrain is large. As in, many kilometers across. It uses geomipmapping with multiple levels of LOD.
  • The terrain uses 16-bit grayscale files for height (for those smooth curves), and uses a 5-layer single-pass splatting shader. The splatting shader supports alpha fringing along the transitions, based on alpha in the splat textures. There's a single RGBA splat control texture.
  • The model (that rusty thing in the middle) is using a color map, a gloss map and a normal map, doing per-pixel lighting.
  • There is a particle system, as you can see from the dust being blown out by that hovercraft.
  • The hovercraft is built on top of JigLibX, which I have integrated. I started writing my own collision detection and physics a while back, but threw it out when I found that JigLib was ported to C#.
  • Level files are built out of XML. The XML is parsed at runtime (not through the content pipeline) and System.Reflection is used to manufacture and configure objects.
  • The hovercraft is also interesting, because it is built using an entity component composition mechanism. The following components are used in the hovercraft:
    • ModelComponent for rendering
    • PhysicsComponent for collision testing
    • HoverComponent for the hovering forces
    • CameraComponent to drag the camera around
    • HoverInteractor to read the control input
    • ParticleComponent to render the particle system
    • HoverDustController to control the particle component based on the hover component simulation

All the components use late discovery and configuration, which makes them fairly well de-coupled and re-usable. Yay!

Now all I've got to do is to come up with some gameplay. I'm thinking some machine guns and missile launchers, and fighting as a freedom rebel against the Big Evil Empire. Quite the original idea, isn't it? :-)

AttachmentSize
Screen Shot 2008-03-24 (terrain and dust)93.96 KB