Skip to content

Instantly share code, notes, and snippets.

View banister's full-sized avatar
🇳🇱

John Mair banister

🇳🇱
View GitHub Profile
def check_actor_collision
@cur_tile ||= @env.get_tile(@x.to_i, @y.to_i)
c_list = @cur_tile.collision_list
#puts "display c_list #{c_list}" <--- if i uncomment this line it crashes
c_list.each do |thing|
unless thing == self
if intersect?(thing) then
case thing
when Tank
glBegin(GL_TRIANGLES); // Drawing Using Triangles
glVertex3f( 0.0f, 1.0f, 0.0f); // Top
glVertex3f(-1.0f,-1.0f, 0.0f); // Bottom Left
glVertex3f( 1.0f,-1.0f, 0.0f); // Bottom Right
glEnd(); // Finished Drawing The Triangle
builder { |xm|
xm.em("emphasized")
xm.em { xm.b("emp & bold") }
xm.a("A Link", "href" => "http://onestepback.org")
xm.div { xm.br }
xm.target("name" => "compile", "option" => "fast")
xm.instruct!
xm.html {
xm.head {
xm.title("History")
def c src, options = {}
options = {
:expand_types => true,
}.merge options
end
emacs-snapshot:
Installed: 1:20080228-1ubuntu1
Candidate: 1:20080228-1ubuntu1
Version table:
*** 1:20080228-1ubuntu1 0
500 http://archive.ubuntu.com hardy/universe Packages
100 /var/lib/dpkg/status
#include <stdio.h>
#include <stdlib.h>
//struct fren_s;
typedef struct fren_s fren;
struct fren_s {
fren * zhivago;
fren * chris;
void
save_floats_in_array(int sz, float * arr, ...) {
int i;
va_list va;
float float_val;
va_start(va, arr);
for (i = 0; i < sz; i++)
require 'rubygems'
require 'inline'
class Object
inline do |builder|
builder.c %{
VALUE get_klass() {
return CLASS_OF(self);
}
module main;
import tango.io.Stdout;
class A
{
this () {
foo ();
}
At a far extreme, on the other end of the world, should you travel that far, you will find the most intelectually eloquent language ever invented, LISP. In the realm of LISP, from the Basic programmers perspective, things look strange and soft. Symbols are tangled and twisted, and yet somehow slowly unfold under the light of reason. From the high refuge of Quick Basic, LISP doesn't even look like programming. Only the long journey down the mountain and across the wilds of deformed and crippled scripting languages can shape your eyes to see the beauty of a LISP proccessor as it slowly meditates upon itself, always looking inward upon its own mathematical truth. But that is a far way off.
Within view, upon a craggy spire of hard rock, many have seen C. Encrusted upon brittle rock, it is etched by the flow of magma, continually belching sulphur and cracking into new formations. It is a land of iron, maleable and refinable. It is a land of legend and of simplicity. It is a place where a rock is a rock. Nothing