Dev Breakthroughs
68.9K views | +0 today
Follow
Dev Breakthroughs
Monitoring innovations in database, PHP, JS, RIA, HTML5, mobile and agile dev strategies & tools
Curated by Nicolas Weil
Your new post is loading...
Your new post is loading...
Scooped by Nicolas Weil
Scoop.it!

Using Node.js and your phone to control a Browser game

Using Node.js and your phone to control a Browser game | Dev Breakthroughs | Scoop.it

This past week I undertook a pretty cool project as the Intern here at Cykod. We were wondering how easily a smart phone –specifically using its gyroscopes and accelerometers– could be used as a controller for a multi-player game on a larger screen. With a bit of Node.js and HTML5 magic, it turned out to be pretty simple.

 

Concept :

We want to use a desktop (laptop, iPad, etc. something with a bigger screen that multiple players can easily look at) connection to act as the common game space. Once that screen is initialized, each player connects to a specific URL in their phone browser that links them to that game instance. We'll follow this basic outline:

- Register new connections to the server and decide if it is a room or mobile user:

- Create a new room,

- Or add the connection to an existing room

- Constantly poll the mobile device for orientation data

- Use said data to update the HTML5 Canvas game

- Handle dropped connections appropriately

 

Result :

The proof-of-concept full game is up at http://bit.ly/G4LSpaceWords

No comment yet.
Scooped by Nicolas Weil
Scoop.it!

Native+Web: The New LinkedIn Apps come with Backbone, Node, and more

Native+Web: The New LinkedIn Apps come with Backbone, Node, and more | Dev Breakthroughs | Scoop.it

Kiran Prasad (running mobile development at LinkedIn), talks about their approach to building hybrid applications:

- Reuse of HTML5 code across all three applications (mobile web, iOS and Android)

- Client framework : Backbone + Zepto + Underscore + Handlebars + Stylus

- Server-side : node + socket.io (WebSockets) + redis + mongo

 

On the specific node.js topic, see : http://venturebeat.com/2011/08/16/linkedin-node/

No comment yet.