Skip to content

Instantly share code, notes, and snippets.

View AGoblinKing's full-sized avatar
🐢
INFRASTRUCTURE

a Goblin King AGoblinKing

🐢
INFRASTRUCTURE
View GitHub Profile
var connect = require('connect'),
dnode = require('dnode'),
config = require('./config'),
iface = require('./interface');
var server = connect.createServer();
server.use(connect.static(__dirname+'/static'));
dnode(function(client) {
var Widget = new Class({
initialize: function(options) {
this.options = Object.merge(this.options, options);
},
members: {},
options: {},
update: function() {
this.destroy();
this.render();
},
@AGoblinKing
AGoblinKing / moooooo
Created March 24, 2011 06:17
Mootools debuging
new Element('div', {
styles: {
fontWeight: 'bold',
position:'fixed',
top:'0px',
right:'0px',
display:'none'
}
}).inject($$("body"))
@AGoblinKing
AGoblinKing / Jixel v0.2
Created March 27, 2011 04:17
Jixel v0.2 new Syntax
Jxl.init();
Jxl.loader.load({
'animals': ['image', 'examples/assets/animals.png']
}, function() {
Jxl.state = new Jxl.State({
members: [
new Jxl.Sprite({
x: 150,
y: 320,
graphic: Jxl.loader.get('animals'),
Jxl.init(function() {
Jxl.loader.load({
'animals': ['image', 'examples/assets/animals.png']
}, function() {
Jxl.state = new GameState();
});
Jxl.start();
});
var GameState = new Class({
Jxl.init(function() {
Jxl.loader.load({
'animals': ['image', 'examples/assets/animals.png']
}, function() {
Jxl.state = new GameState();
});
Jxl.start();
});
var GameState = new Class({
self.clear();
self.render(self.scene.skyScene, self.scene.skyCamera);
self.render(fakeScene, fakeCamera);
@AGoblinKing
AGoblinKing / tumlbr_template.html
Created August 7, 2012 05:05 — forked from pamelafox/tumlbr_template.html
Twitter Bootstrap Tumblr Theme
<!doctype html>
<!--[if lt IE 7 ]> <html class="no-js ie6" lang="en"> <![endif]-->
<!--[if IE 7 ]> <html class="no-js ie7" lang="en"> <![endif]-->
<!--[if IE 8 ]> <html class="no-js ie8" lang="en"> <![endif]-->
<!--[if (gte IE 9)|!(IE)]><!--> <html class="no-js" lang="en" xmlns:fb="http://www.facebook.com/2008/fbml" xmlns:og="http://ogp.me/ns#"> <!--<![endif]-->
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name='description' content='{MetaDescription}'>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
@joints = {}
for key, value of zig.Joint
material = new THREE.MeshBasicMaterial
color: "0xFF0000"
@joints[value] = new THREE.Mesh (new THREE.SphereGeometry 50, 10, 10), material
@joints[value].position.set 0,0,0
@body.add @joints[value]
engage = zig.EngageUsersWithSkeleton 1
engage.addEventListener "userengaged", (user) =>
$ ->
WIDTH = window.innerWidth
HEIGHT = window.innerHeight
VIEW_ANGLE = 45
ASPECT = WIDTH/HEIGHT
NEAR = 0.1
FAR = 100000
renderer = new THREE.WebGLRenderer()