More AJAX Games – Battleship
How long before Pong? Battleship, a pretty easy game to implement, has made it’s appearance as an AJAX powered game.
It has a few defects: if you reload the page it repeats the dialog and puts you back into the setup phase which made the UI get out of sync with the game state. Also, my opponent was apparently unable to shoot after he hit my first ship. The chat function was marvelous for commiserating about how the game didn’t work.
The game makes use of many of the most popular Javascript libraries.
<script src="js/import/prototype.js" type="text/javascript"></script>
<script src="js/import/scriptaculous.js" type="text/javascript"></script>
<script src="js/import/effects.js" type="text/javascript"></script>
<script src="js/import/window.js" type="text/javascript"></script>
<script src="js/import/dragdrop.js" type="text/javascript"></script>
<script type="text/javascript" src="js/chat.js"></script>
I’d say it’s good for one play before the tears of boredom stream down your face.


