You Laugh You Lose
Recently I won a trip to NodeConf (a conference about nodeJS) by making a cool little game called "You Laugh You Lose". It was created in 17 hours at NodeJitsu's "Hack Nodeconf Hackathon". After a full days work my friend Mike and myself wandered over to Pivotal Lab's awesome offices near union square and proceeded to stay up for the next 24 hours. This blog post is about how that went.
First off get a cool browser and play the game!
Inception
Me: Hey @koudelka want to help me win a ticket to nodeconf?
Mike: Sure @voidburger has a funny idea, we show funny pictures and do smile detection and if you laugh you lose.
Me: We should totally plan this out!
Mike: Lets goto the beach and do it there!
Me: That sounds perfect.
There was no planning. But who cares?
Libraries
- Backbone JS for the "client game" application.
- Socket.IO for sending game events.
- express for serving the single static page.
- Face.js for detecting faces and smiles.
Basic Plan
We used express to render our one index template and serve static files. So far so good. We used socket.io to connect people to the game. A socket connection is a game connection. A socket disconnection is a game disconnection. What? No disconnect events? (we were doing it wrong) ok.. we'll ignore that. What about the webcam?
Flash - every webcam library sucks.
WEB RTC - Never heard of it.
getUserMedia() oOOo what's this? (It's web rtc.)
https://github.com/maxogden/domnode-usermedia did not yet exist
This post was never finished but we had a great time!
Powered by ⚡️ and 🤖.