Skip to content

Instantly share code, notes, and snippets.

Widget Menagerie

@karol-f
karol-f / robot.js
Created December 4, 2012 19:57
test
function Robot(robot) {}
Robot.prototype.onIdle = function(ev) {
var robot = ev.robot;
robot.turn(90); // keep turning 90 degrees when idle
};
@karol-f
karol-f / robot.js
Created December 4, 2012 19:53 — forked from randompast/robot.js
QR-bot-009
function Robot(robot) {}
// well, we need to do something...
// whenever our robot is idle, this method gets called.
Robot.prototype.onIdle = function(ev) {
var robot;
robot = ev.robot;
robot.ahead(150);
robot.rotateCannon(360);
robot.back(100);
@karol-f
karol-f / robot.js
Created December 4, 2012 11:32
night
//FightCode can only understand your robot
//if its class is called Robot
var go=120;
var Robot = function(robot) {
};
@karol-f
karol-f / robot.js
Created December 4, 2012 11:31 — forked from fabiopimentel/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();