Skip to content

Instantly share code, notes, and snippets.

View samshull's full-sized avatar
🎯
Focusing

Sam Shull samshull

🎯
Focusing
View GitHub Profile
@samshull
samshull / robot.js
Created December 3, 2012 17:01
destroyer of worlds
//FightCode can only understand your robot
//if its class is called Robot
var Robot = function(robot) {
};
Robot.prototype.onIdle = function(ev) {
var robot;
robot = ev.robot;
@samshull
samshull / robot.js
Created December 3, 2012 17:36
W00t #1 YEAH!!!! (Zolmesiter)
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) {
@samshull
samshull / robot.js
Created December 3, 2012 17:37 — forked from cezarsa/robot.js
Simple Wall Robot
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) {
@samshull
samshull / gist:fe4ea1f14396387f4f6d
Last active August 29, 2015 14:06
simplifying method_missing functionality with Proxy
var root = (function(){ return this; })();
function ProxyClass() {
if (this === root) throw Error();
var instance = this;
return Proxy.create({
get: function(receiver, name) {
console.log('get', name);
return instance[name] || (instance._get && instance._get(name, receiver)) || undefined;
},
@samshull
samshull / api.md
Last active January 24, 2020 23:24 — forked from AdamMagaluk/api.md
EpicMix Mobile API
http://www.epicmix.com/vailresorts/sites/epicmix/api/mobile/mountains.ashx
http://www.epicmix.com/vailresorts/sites/epicmix/api/mobile/weather.ashx
http://www.epicmix.com/vailresorts/sites/epicmix/api/mobile/terrain.ashx
http://www.epicmix.com/vailresorts/sites/epicmix/api/mobile/lifts.ashx
http://www.epicmix.com/vailresorts/sites/epicmix/api/mobile/mountaincams.ashx
http://www.epicmix.com/vailresorts/sites/epicmix/api/mobile/roadconditions.ashx