Monday, October 31, 2005

Big advances on the game

I made large strides in the game today. Now, I have a ship that shows up on the screen (with transparency), as well as asteroids. To get the game a little more interesting, I set up basic keyboard interaction (using keypress events). This is limiting, because you can only send one message at a time, so hitting two keys (like rotate left and thrust) has only one key's effects.

I created a little extra line, too, to show the ship's current velocity vector. I almost have the physics for the game complete. The ship can thrust and rotate. The asteroids can be set with a given velocity, and they keep that. The only additional physics concept I want to model for v1 is friction; objects will slowly decelerate, with the idea being that they are being affected by space dust or super small asteroid chunks or something.

I started working on the bullet class, because I want to shoot stuff. I guess first I should get collision detection set up for the ship and asteroids, though.

I also got more cool tools for Visual Studio that relate to Test Driven Dev installed. I can now see my code coverage, and run tests from within Visual Studio. Both of these are huge advances. The code coverage will help me design better unit tests. The ability to run tests from within the IDE will greatly increase my productivity.

I also messed with the inheritance chain now. The chain for the player's ship now looks like this:
PlayerShip->Ship->SpaceRockObject->BasicSprite. Getting deep, isn't it?

2 comments:

Primate Buddy said...

Waiting for the multiplayer version myself.

Unknown said...

I'm waiting for Courtney to post something myself.