This file contains 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
// Listen for connections | |
io.on('connection', function(client){ | |
// Let us know someone connected | |
console.log("Client connected!") | |
// When a player sends the join message | |
client.on('join', function(data) { | |
// TODO 1: Do something about a player joining | |
}) |
This file contains 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
var pl = require('planck-js'); | |
var Vec2 = pl.Vec2 | |
var server = require('http').createServer(); | |
var io = require('socket.io')(server); | |
var Web3 = require('web3'); |
This file contains 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
/** | |
* Page layout, reused across multiple Page components | |
* @jsx React.DOM | |
*/ | |
var React = require('react'); | |
var ExecutionEnvironment = require('react/lib/ExecutionEnvironment'); | |
var Navigation = require('../components/Navigation.jsx'); | |
var DefaultLayout = React.createClass({ |