Making a platformer can be a lot of fun, but some of the physics and collision detection can be quite tricky. I suggest using some existing code to get started (make sure you give credit on your project page).