Just a little update post. We’ve got scrollage (remember, you can move the ball with the arrow keys. You might have to click on the game to activate it though).
It hit me today that I didn’t need the ball to move, I needed the stage to move. It took some doing, but I’ve now got the ball staying still in the dead center of the stage, and the stage zooms around the ball. This probably will get some tweaking, but here is basically what I had to do:
1. Move the ball.
2. Capture the x, y values of the ball.
3. Put the ball back in the middle of the stage.
4. Capture the difference between where the ball was and where the ball is.
5. Move the stage by that difference.
I’ll explain in more detail in my forthcoming tutorial.
All that’s left now is to make the ball react to left sloping ground. Once I have that done, I’ll clean up the code and make a big level. Once I have *that* done I’ll play with it a bunch and either get bored with it, or I’ll add monsters and upgrades and actually make it into a game.











Sweet! I seriously had fun for at least a full two minutes, which is saying a lot. It’s interesting that you can’t get the ball to fly using just “up,” unless it is already in the air. If you start from the ground and push up, the ball won’t fly. But you can “bounce” the ball by clicking up a few times to get it in the air, then it will fly. Good times.
Also, why is it that sometimes the ball won’t bounce off of the blocks? If you fly up underneath, sometimes it won’t recognize the block at all, and sometimes only the “top” of the block. You really don’t have to answer, it’s just fun playing around in there after seeing you start from scratch. Thanks man.
I’m enjoying seeing the progress of your game. I can’t believe you’ve gotten it to do what it does, that seems impossible to me. I hope you keep going after you create your level and release constant updates and patches to the physics engine and continue to improve on it. How much time has it taken you so far, total?
I did notice that when the ball gets to the end of the level, if you push and hold left after it falls off the last cliff and bounce it against the wall as it’s falling, it will start creeping back up and you’ll be able to get back up to the ground.
Yeah, there are still lots of bugs. In the version you guys commented on, onle the bottom left corner of the ball was really registering hits. Now all four corners are registering. However there are still bugs. Like if the left side hits a solid vertical wall, it considers it a left corner hit, and you can sort of just crawl up the wall. This is a bug.
There are lots of things I need to work on on this.
As to how much time I have spent on it… probably about… 25 hours… maybe… It’s really hard to say. There was a lot of time “wasted” prototyping and learning everything, and if I did it all over again it would only take me five to ten hours at the most to get to this point again I think.
I think I will definitely keep working on it, depending on how many of these bugs I can work out…