This year there was no RADRace, instead QNH organised the GameRace 2009.
I entered with my colleague Jamie Craane.
We chose to use Java and Groovy.
One of the challenges was to make a pong player application which could get information from the gameserver and act accordingly to bounce the ball back.
After the first day, completing some of the other challenges we had just begun on solving the pong puzzle. One tactic is just to try to get the pad to match the Y-position of the ball. But, there is another way.
During the trip back home we started to think about possible ways to predict where the ball would hit the X=0 line after it had left our pad. The first draft of the algorithm we came up with looked somewhat like this :
predictYpos = ( ( ballXpos- ( gameFieldWidth * 2 ) ) * abs(ballXtep) / abs(ballYstep) % gameFieldHeight ) + ballYPos
this was not a bad start but it only works if the ball is moving in positive x and y direction.
This is about the implementation of the algorithm we used, in the past couple of days we have updated this algorithm and written some code to make the perfect pong player!
Will post code soon...
dinsdag 20 oktober 2009
donderdag 19 maart 2009
maandag 29 september 2008
zondag 28 september 2008
woensdag 3 september 2008
Chrome
The first beta version of Google's browser, Google Chrome, is available for download.
http://www.google.com/chrome
It installs in seconds and works pretty fast.
One of the biggest issues I discovered so far : it has trouble opening secured sites (like gmail and google reader)
Hopefully an update will come along soon...
http://www.google.com/chrome
It installs in seconds and works pretty fast.
One of the biggest issues I discovered so far : it has trouble opening secured sites (like gmail and google reader)
Hopefully an update will come along soon...
woensdag 30 juli 2008
Quote of the day
"The single most important factor that distinguishes a well-designed module from a poorly designed one is the degree to which the module hides its internal data and other implementation details from other modules."
-- Joshua Bloch, Effective Java
-- Joshua Bloch, Effective Java
Abonneren op:
Posts (Atom)

