Skip to content

Instantly share code, notes, and snippets.

View chrahunt's full-sized avatar

Chris Hunt chrahunt

View GitHub Profile
@chrahunt
chrahunt / example-offense-bot.user.js
Created February 21, 2015 02:36
Example Offense Bot that makes use of tagpro-navmesh library.
// ==UserScript==
// @name TagPro Example Offense Bot
// @description Limited example offense bot for TagPro.
// @version 0.1
// @grant none
// @include http://tagpro-maptest.koalabeast.com:*
// @include http://tangent.jukejuice.com:*
// @include http://*.newcompte.fr:*
// @author snaps_
// @namespace http://www.reddit.com/user/snaps_
@chrahunt
chrahunt / lap-timer.user.js
Created February 20, 2015 02:20
Lap Time Tracker for /r/tagproracing
// ==UserScript==
// @name TagPro Lap Time Tracker
// @namespace http://www.reddit.com/user/NewCompte
// @description Track lap times
// @include http://maptest.newcompte.fr:*
// @include http://maptest2.newcompte.fr:*
// @license WTFPL
// @author NewCompte, snaps
// @version 0.9.1
// ==/UserScript==
@chrahunt
chrahunt / simple-cors-http-server.py
Created February 7, 2015 17:36
Serve content from a local file directory using Python 3.4 and include the 'Access-Control-Allow-Origin' header.
#! /usr/bin/env python2
# From http://stackoverflow.com/a/21957017/1698058
from http.server import SimpleHTTPRequestHandler, HTTPServer
import http.server
class CORSRequestHandler (SimpleHTTPRequestHandler):
def end_headers (self):
self.send_header('Access-Control-Allow-Origin', '*')
SimpleHTTPRequestHandler.end_headers(self)
@chrahunt
chrahunt / tagpro-fc-status.user.js
Last active August 29, 2015 14:14
Show name of flag carrier at bottom of UI in TagPro game.
// ==UserScript==
// @name TagPro Flag Carrier Name
// @namespace http://www.reddit.com/user/snaps_/
// @description Adds the name of the flag carrier next to the flags on the TagPro game UI.
// @license GPL version 3 or any later version; http://www.gnu.org/copyleft/gpl.html
// @version 0.1.3
// @author snaps
// @downloadURL https://gist.github.com/chrahunt/03a399925e42f7c4f1e6/raw/tagpro-fc-status.user.js
// @include http://tagpro-*.koalabeast.com:*
// @include http://tangent.jukejuice.com:*
@chrahunt
chrahunt / exampleBot.user.js
Created January 29, 2015 20:18
A userscript-based starter bot for the game TagPro.
// ==UserScript==
// @name TagPro Example Bot
// @description Limited example bot for TagPro.
// @version 0.1
// @grant none
// @include http://tagpro-maptest.koalabeast.com:*
// @include http://tangent.jukejuice.com:*
// @include http://*.newcompte.fr:*
// @author Cflakes, snaps_
// @namespace http://www.reddit.com/user/snaps_
// ==UserScript==
// @name Socket.io Loopback Interface
// @namespace http://www.reddit.com/user/snaps_/
// @description Adds a loopback capability to socketio sockets. Emitting a message with the event name prepended with "local:" will emit the message to the client-side socket listeners.
// @include http://tagpro-*.koalabeast.com:*
// @include http://tagpro-*.koalabeast.com/groups/*
// @include http://tangent.jukejuice.com:*
// @include http://tangent.jukejuice.com/groups/*
// @include http://maptest*.newcompte.fr:*
// @include http://maptest*.newcompte.fr/groups/*
/**
* @module mover/browser
*/
define(function() {
/**
* The Mover is responsible for executing actions within the
* browser environment and managing keypresses.
* Agents should utilize a personal `move` function that should
* be set as the move function of the object created from this
* class.
@chrahunt
chrahunt / velocity.user.js
Created January 22, 2015 18:22
Show arrows indicating current velocity.
// ==UserScript==
// @name Velocity Arrows
// @version 0.1.0
// @description Shows an arrow indicating the player's current velocity. Example of a graphics object drawn static relative to the player.
// @include http://tagpro-*.koalabeast.com:*
// @include http://tangent.jukejuice.com:*
// @include http://*.newcompte.fr:*
// @author snaps
// ==/UserScript==
// ==UserScript==
// @name TagPro Tile Pattern
// @namespace http://www.reddit.com/u/snaps_/
// @description Tints every other floor tile a slightly different shade.
// @include http://tagpro-*.koalabeast.com:*
// @include http://tangent.jukejuice.com:*
// @include http://*.newcompte.fr:*
// @license GPL version 3 or any later version; http://www.gnu.org/copyleft/gpl.html
// @author snaps
// @version 0.1.0
// ==UserScript==
// @name TagPro Chat Enhancer
// @namespace http://www.reddit.com/user/-omicron-/
// @description Disables ingame chat messages while logging messages outside the game environment with the same styling/formating but allowing for all kinds of extra functionality in doing so.
// @include http://tagpro-*.koalabeast.com:*
// @include http://tagpro-*.koalabeast.com/groups/*
// @include http://tangent.jukejuice.com:*
// @include http://tangent.jukejuice.com/groups/*
// @include http://maptest.newcompte.fr:*
// @include http://maptest.newcompte.fr/groups/*