Skip to content

Instantly share code, notes, and snippets.

@wanderr
wanderr / robot.js
Created December 6, 2012 07:26 — forked from dziorki/robot.js
[CAELUM TEAM]Megatron
//FightCode can only understand your robot
//if its class is called Robot
var Robot = function(robot) {
};
Robot.prototype.onIdle = function(ev) {
var robot = ev.robot;
robot.clone();
@wanderr
wanderr / robot.js
Created December 4, 2012 04:01 — forked from tarsisazevedo/robot.js
Woot Sucks
var Robot = function(robot){
robot.turnLeft(robot.angle % 90);
//robot.turnGunRight(90);
robot.clone();
this.direction = 1;
};
Robot.prototype.onIdle = function(ev) {
var robot = ev.robot;
robot.ahead(1);
if (robot.parentId) {