Jump to content
  • Advertisement
Sign in to follow this  
  • entries
  • comments
  • views


Sign in to follow this  
Jesse Chounard


Since posting my last entry, where I had a "playable" little platformer, I've had to go quite a bit backward to implement the features I want. (I put playable in quotes, because absolutely nothing happened when you collided with enemies. But you could jump around between platforms.)

I've done two things that I think are interesting.

1) I've played around the the XNA Content Pipeline. I made a simple animation file format (currently it's just XML) that the pipeline can load up automatically like it can handle textures or meshes. It's not useful yet, but it's a neat experiment on how to add something to the pipeline.

2) Collision detection research. The collision detection I was using before was simply checking Rectangle.Intersects, and then moving the character back to prevent the collision. That's not terribly exciting, and certainly doesn't help at all with sloped surfaces.

My plan is to use two methods of collision. Sprite vs. Platform collisions will be handled with the separating axis theorem (thanks for pointing that out Mr. Easily Confused), and bounding box plus nearly pixel-perfect collision for Sprite vs. Sprite collisions.

Now for some "exciting" screenshots. You control one of the red boxes, using the arrow keys to move, and the A and D keys to rotate. The other red box will push you away on collision (SAT collisions) and collision with the big 'C' looking texture (nearly pixel-perfect) will just change the background to yellow.

And here's the source code. It requires all of the XNA Game Studio Express stuff. I'm still trying to get my head fully wrapped around C#, plus it's just an experiment so don't expect the world's best code.

Sign in to follow this  


Recommended Comments

There are no comments to display.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!