Skip to content

Instantly share code, notes, and snippets.

@Mr0ok
Mr0ok / robot.js
Created December 7, 2012 17:19 — forked from jaskolek/robot.js
jaskolek
var robots = new Array();
//FightCode can only understand your robot
//if its class is called Robot
var Robot = function(robot) {
};
Robot.prototype.start = function( ev ){
@Mr0ok
Mr0ok / robot.js
Created December 6, 2012 20:51 — forked from f6p/robot.js
NecroBadger
// helpers
function areEnemies(robot, sighted) {
var sightedIsChild = (robot.id == sighted.parentId);
var sightedIsParent = (robot.parentId == sighted.id);
return !(sightedIsChild || sightedIsParent);
};
function baseStep(robot) {
@Mr0ok
Mr0ok / robot.js
Created December 6, 2012 20:33 — forked from jaskolek/robot.js
jaskolek
var robots = new Array();
//FightCode can only understand your robot
//if its class is called Robot
var Robot = function(robot) {
};
Robot.prototype.start = function( ev ){
@Mr0ok
Mr0ok / robot.js
Created December 6, 2012 19:55 — forked from chaosu/robot.js
CHAOSU
//FightCode can only understand your robot
//if its class is called Robot
var go=120;
var Robot = function(robot) {
};
@Mr0ok
Mr0ok / robot.js
Created December 6, 2012 19:54 — forked from chaosu/robot.js
Zolmeister
//FightCode can only understand your robot
//if its class is called Robot
var go=120;
var Robot = function(robot) {
};
@Mr0ok
Mr0ok / robot.js
Created December 6, 2012 19:31
MmmMHHmmmm
var Robot = function(robot) {
this.direction = 1;
this.found = 0;
this.speed = 3;
};
Robot.prototype.onIdle = function(ev) {
var r = ev.robot;
@Mr0ok
Mr0ok / robot.js
Created December 6, 2012 19:22
ILIVETWICE
//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;
@Mr0ok
Mr0ok / robot.js
Created December 6, 2012 19:16
MR #9
//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;
@Mr0ok
Mr0ok / gist:4227042
Created December 6, 2012 18:51
MR #9
We couldn’t find that file to show.
@Mr0ok
Mr0ok / robot.js
Created December 5, 2012 18:14 — forked from Shipow/robot.js
Shipow#001
var Robot = function(robot) {
robot.rotateCannon(-90);
};
Robot.prototype.onIdle = function(ev) {
var robot = ev.robot;
robot.ahead();
//i'll add a clone but i need to refactor collision
//robot.clone();
};