This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package uk.calumgilchrist.ai.pathfinder; | |
import java.util.Collection; | |
import java.util.Collections; | |
import java.util.Iterator; | |
import java.util.LinkedList; | |
import java.util.List; | |
import java.util.PriorityQueue; | |
import org.json.simple.JSONArray; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Bullet < Chingu::GameObject | |
traits :velocity, :bounding_circle | |
trait :animation, :delay => 200, :size => [16,16], :width => 16 | |
def initialize(options = {}) | |
super(options.merge(:image => Image["cannon-ball.png"])) | |
end | |
def update | |
@image = self.animation.next if self.animation |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require_relative "island_tiles" | |
require "chingu" | |
include Chingu | |
# An area impassable to ships | |
# Other things can be built onto it | |
class Island < GameObjectMap | |
def initialize(options = {}) | |
super(options) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
*.pydevproject | |
.project | |
.metadata | |
bin/** | |
tmp/** | |
tmp/**/* | |
#Back ups | |
*.tmp | |
*.bak |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Some simple read and write tests using dd | |
# Write | |
echo "Write" | |
dd if=/dev/zero of=tempfile bs=1M count=1024 conv=fdatasync,notrunc | |
# Read Without Cache | |
echo "Read w/o Cache" | |
sudo echo 3 > sudo /proc/sys/vm/drop_caches |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# ------------------------------------------------------ | |
# file: $HOME/.scripts/dzenstat.sh | |
# author: Ramon Solis - http://cyb3rpunk.wordpress.com | |
# modified: June 2011 | |
# vim:fenc=utf-8:nu:ai:si:et:ts=4:sw=4:ft=sh: | |
# ------------------------------------------------------ | |
# ------------------------- |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdlib.h> | |
#include <stdio.h> | |
#define LBR '{' | |
#define RBR '}' | |
#define INTEGER 1 | |
#define SET 5 | |
#define PAIR 6 | |
#define TREE 7 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# earthquake.gem plugin | |
# post url to Pocket | |
require 'open-uri' | |
Earthquake.init do | |
_ = config[:ril] ||= {} | |
_[:apikey] ||= 'your-consumer-key' | |
# Sign Up for the Pocket API | |
# https://getpocket.com/developer/apps/new |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <stdlib.h> | |
#include <unistd.h> | |
#include "malloc.h" | |
#include "chunk.h" | |
/* Globals */ | |
Chunk* chunks; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# | |
# Possible Implementation for testing the wireless signal | |
# Outputs: | |
# {essid} {quality} | |
wicd-cli --wireless -d | grep -P -i "essid|quality" | cut -d " " -f 2 | awk '!/0$/{printf "%s ",$0}/0$/' |