Monday, February 27, 2012

pyBotWar: State of the Code

Tomorrow we are moving into the final hackfest for this class. Before the hackfest I want to outline what we've gotten done so far and what I think we can get done before the project is due.

What We Have
  • Working back end code pushing to a memcache
  • Working client reading memcache and properly drawing all elements of the game.
  • Updated graphics for all the bots
What We Need to Have
  • Facebook authentication
  • User uploaded bots
  • Restricted python
  • Starting a game with friends' bots 
Would be Nice
  • Better selection of starting bots
  • Different weapons/ body types
  • Multiple arenas
  • Game playback
  • Communication protocol
    • hacking other bots (mwuhahaha)
At this point I feel comfortable saying we will have a finished, polished product. The remaining necessary features are fairly low hanging fruit. Given the amount of time we are planning on spending  hacking tomorrow I don't think we'll have any problems getting this done.
That means we get to spend most of the hackfest adding cool new features. I'm really excited to implement some new weapons and bodies. Also, I love the idea of hacking other bots through a communication protocol. You could have a bot that could just sit still and use all of it's processor power cracking the encryption of the other bots and telling them to attack each other.

Wednesday, February 15, 2012

PyBotWar

For the Open Source game design class we're going to try and make an online multiplayer version of the classic RoboCode game. We found a python port on google code http://code.google.com/p/pybotwar/ that we hope to put up on open shift. Robo Code is a game where you actually program a robot that fights other robots in an arena. The robots rely solely on the code you right as you cannot control them once the match starts. Our goals for the project are as follows:

Required:
  • Refactor the graphics stack to support a javascript client. Adding json communication between the server and client.
  • Upgrade existing sprites and graphics assets
  • Prevent users from calling dangerous python packages in their robots
  • Facebook authentication
Optional:
  • Add new arenas beyond the basic square one
  • Add additional weapon
  • Add different sensors
Pie in the Sky:
  • Communication protocol for teams of robots
  • Ability to hack opposing robot's using communication protocol
    • stack overflow, false commands, etc.
  • RPG elements including leveling up and earning new weapons or stats
At the moment we're still focusing on reverse engineering the graphics stack. We'll then implement a function that exposes the current state of the world using json. From there we simply need to write javascript to draw the game state.

Once our core goals are complete, we'll hopefully have time to focus on adding fun things like new weapons and body types. These would add value to the game play without requiring much time. If we get to this stage of development we should be able to produce several new options.

Friday, February 10, 2012

AJAXING It up!

I learned about ajax this week in class. I knew about it in the past but I haven't had much experience implementing it. Seems like a really good way to send and receive data quickly.

The basics of AJAX is that you create a function that will serve json whenever it is called. This function is tied into a URL that can be called with optional parameters. Then you can have another program, be it a web client or desktop software send a request to this URL. The program then receives back json formatted information it can use.

I will be using AJAX to implement my final project for class. I'll be able to run the python pyBotWar program on a server with a modified AJAX function that sends out the state of the game. The client can then ping this function periodically to get information about robot position, angle, health, etc. and draw the state.