Game Development

Oracle’s Eye Development: Kicking the Ball

Oracle’s Eye development has been fairly slow since I started it in August. I’m trying to get working on it earlier in the evenings I have dedicated to development, but I find that I usually don’t get started until late at night. When I finally get into a groove or otherwise in The Zone, I learn that it is 12:30AM or 1AM and I need to go to sleep.

In any case, I finally accomplished another milestone. The Player can now kick the Ball around!

I won’t go into too much detail, but I found that I didn’t have to make too many changes or additions. I was originally going to create a somewhat robust Event handling system, but someone reminded me that this is supposed to be a VERY simple game. I am allowed to hardcode it for now. I can always add the Events if I find I actually need them in the future.

I am also trying to remember not to over engineer. I found that hacking things out didn’t cause as many problems as I thought it would. I added an enumeration for Direction: UP, DOWN, LEFT, RIGHT, and STOPPED. Doing so allowed me to keep the code I already had to move the Ball around. I just had to check which Direction it was moving and apply negative signs to the moveX() or moveY() functions as needed.

I then added a check to the GameWorld’s move* functions that control the Player. Now instead of just checking if it hits a Wall, it checks if it hit the Ball as well. The Ball then moves accordingly. It’s a simple check; the collision detection isn’t very robust, but it gets the job basically done. The Ball gets stuck if it hits the Wall for some reason, and the Player can move through the Ball if it is moving faster, but it works. I’ll fix it later.

My next chance to work on it will be Sunday, which is when I scheduled all-day development on Oracle’s Eye. Ideally that means eight hours to work on the project, but if past performance is any indication, I will probably get two, maybe three hours out of it. B-\ With a Ball being kicked around, I would think that it shouldn’t be too hard to create an Exit and apply a new check to see if the Ball hit the Exit. After that milestone is hit, I technically have a playable game. It’s great to know that my one month project is almost “completed” after almost four months. B-)