Skip to content

Instantly share code, notes, and snippets.

View HybridEidolon's full-sized avatar
🐥

Eidolon HybridEidolon

🐥
View GitHub Profile
# Minecraft NSIS Installer Script
# Maintainer: Furyhunter <furyhunter600@gmail.com>
#
# Files:
# Minecraft.exe
Name "Minecraft"
OutFile "minecraft-win32-install.exe"
InstallDir "$PROGRAMFILES\Minecraft"
@HybridEidolon
HybridEidolon / gist:3922427
Created October 20, 2012 06:54
returning reference vector
#include <iostream>
#include <vector>
using namespace std;
void ints(vector<int>& tofill) {
tofill.push_back(1);
tofill.push_back(2);
tofill.push_back(3);
}
@HybridEidolon
HybridEidolon / gist:3965540
Created October 27, 2012 18:05
minimum translation vector between aabb's
vec_t Col_RectRect(const rectangle_t* a, const rectangle_t* b) {
vec_t ret;
float left, right, top, bottom;
// zero the vector
ret.x = 0;
ret.y = 0;
// axis
@HybridEidolon
HybridEidolon / main.cpp
Created December 12, 2012 00:44
Hello, GitHub Gists 2.0!
#include <iostream>
#include <string>
#include <list>
using namespace std;
class HelloWorld {
public:
HelloWorld() : words() {};
~HelloWorld() {};
public class CalculatorWindow extends JFrame {
// ...
JButton button0;
JButton button1;
// ...
public void doWhateverSetup() {
// ...
button0.addActionListener(new KeypadButtonAction(0, this));
button1.addActionListener(new KeypadButtonAction(1, this));
@HybridEidolon
HybridEidolon / .vimrc
Last active December 14, 2015 01:59
tentative .vimrc. Still learning. Needs gmarik/vundle and git on the local system.
set nocompatible
filetype off
set rtp+=~/.vim/bundle/vundle
call vundle#rc()
"""""""""""""""""""""""
" Bundles for vundle
"""""""""""""""""""""""
" Vundle must manage itself
@HybridEidolon
HybridEidolon / avg.py
Last active December 17, 2015 01:29
python average int list inject
from functools import reduce
# nums = [1, 2, 3, 4]
def average_value(nums):
avg = reduce(lambda t,i: t+i, nums)
avg /= len(nums)
return avg
print average_value([1, 2, 3, 4])
@HybridEidolon
HybridEidolon / GW2World.java
Last active December 17, 2015 19:19
list adapter example
package com.furyhunter.gw2assistant;
import org.json.JSONException;
import org.json.JSONObject;
import android.content.ContentValues;
import android.database.sqlite.SQLiteDatabase;
import android.os.Parcel;
import android.os.Parcelable;
@HybridEidolon
HybridEidolon / gist:6482163
Created September 8, 2013 05:43
Xbox 360 official DirectInput mappings
Xbox 360 Controller Mappings:
A: 0
B: 1
X: 2
Y: 3
LB: 4
RB: 5
//TopGearTimeTravel by Andrew "Yeti" S.
//Respect to J3DI From Ludum Dare
#include <iostream>
#include <ctime>
#include <string>
#include <sstream>
using namespace std;