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
| # -*- coding: iso-8859-15 -*- | |
| """ | |
| Behavior Tree Example | |
| """ | |
| class WorldStatus(object): | |
| def __init__(self): | |
| self.aperta = False # Porta aperta? | |
| self.step = 3 # Distanza dalla porta |
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
| import os | |
| import wave | |
| import threading | |
| import sys | |
| # PyAudio Library | |
| import pyaudio | |
| class WavePlayerLoop(threading.Thread) : | |
| """ |
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
| using System; | |
| using System.Collections.Generic; | |
| using System.Diagnostics; | |
| /// <summary> | |
| /// Generic Implementation of the A* algorithm. | |
| /// </summary> | |
| public class AStar { | |
| #region ProfilingCollection |
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 NameGenerator { | |
| static string[] NameDatabase1 = { "Ba","Bax","Dan","Fi","Fix","Fiz","Gi","Gix","Giz","Gri","Gree","Greex","Grex", | |
| "Ja","Jax","Jaz","Jex","Ji","Jix","Ka","Kax","Kay","Kaz","Ki","Kix","Kiz","Klee","Kleex","Kwee","Kweex", | |
| "Kwi","Kwix","Kwy","Ma","Max","Ni","Nix","No","Nox","Qi","Rez","Ri","Ril","Rix","Riz","Ro","Rox","So","Sox", | |
| "Vish","Wi","Wix","Wiz","Za","Zax","Ze","Zee","Zeex","Zex","Zi","Zix","Zot" }; | |
| static string[] NameDatabase2 = { "b","ba","be","bi","d","da","de","di","e","eb","ed","eg","ek","em","en","eq", | |
| "ev","ez","g","ga","ge","gi","ib","id","ig","ik","im","in","iq","iv","iz","k","ka","ke","ki","m","ma","me","mi", | |
| "n","na","ni","q","qa","qe","qi","v","va","ve","vi","z","za","ze","zi","","","","","","","","","","","","","" }; |
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
| # Convert an image into a MovingAI .map file. | |
| # @author Davide Aversa <thek3nger@gmail.com> | |
| # @version 1.0.0 | |
| import sys | |
| from PIL import Image | |
| def load_image(filename): | |
| """ |
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
| // Original JavaScript Code from Marijn Haverbeke (http://eloquentjavascript.net/1st_edition/appendix2.html) | |
| export class BinaryHeap<T> { | |
| content: T[]; | |
| scoreFunction: (x: T) => number; | |
| constructor(scoreFunction: (x: T) => number) { | |
| this.content = []; | |
| this.scoreFunction = scoreFunction; | |
| } |
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
| // This is a basic asyncronous shader loader for THREE.js. | |
| function ShaderLoader(vertex_url, fragment_url, onLoad, onProgress, onError) { | |
| var vertex_loader = new THREE.XHRLoader(THREE.DefaultLoadingManager); | |
| vertex_loader.setResponseType('text'); | |
| vertex_loader.load(vertex_url, function (vertex_text) { | |
| var fragment_loader = new THREE.XHRLoader(THREE.DefaultLoadingManager); | |
| fragment_loader.setResponseType('text'); | |
| fragment_loader.load(fragment_url, function (fragment_text) { | |
| onLoad(vertex_text, fragment_text); | |
| }); |
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
| [user] | |
| name = <name> | |
| email = <email> | |
| [core] | |
| autocrlf = true | |
| excludesfile = | |
| [filter "hawser"] | |
| clean = git hawser clean %f | |
| smudge = git hawser smudge %f |
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
| #!/usr/bin/env ruby -w | |
| head, treshold, only_orphans = ARGV | |
| only_orphans ||= false | |
| head ||= 'HEAD' | |
| Megabyte = 1000 ** 2 | |
| treshold = (treshold || 0.1).to_f * Megabyte | |
| # Usage: | |
| # ruby find-old-binaries.rb <branch> <size limit in MB> <show only orphans?> | |
| # |
OlderNewer