Skip to content


Subversion checkout URL

You can clone with
Download ZIP
tree: 02d6a26ec4

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.

README - PubNub - realtime push service in the cloud

PubNub Game Lobby Room 

Use PubNub to build a Game Lobby Room! It is simple.  PubNub allows for state
sharing between users.  This can be used to create game lobby rooms. 
"Real time gossip" communication is the method used to talk with a group.

Communication Strategy with Real Time:
presume the user is constantly void of all information.
Therefore the strategy becomes clear,
alsways send same set of data to all users.
This is helpful as a user may have lost connection, closed the browser or refreshed the page accidettnly.

Follow the code in game-lobby-room.js
to see how to build a Game Lobby Room.  No need for private servers to host
game room state.

The Plan:
    -Subscribe to "lobby" Channel.
    -Pick name or read from local storage.
    -Ping "lobby" with "update" Request.
    -Respond with { uuid : "", name : "", room : "" }
    -Populate UI with Responding Users.

PubNub Client APIs! 
Visit the Pubnub website for more details at
Pubnub is a client-to-client push service in the cloud.

This public repository hosts client APIs for Pubnub.
PHP, Ruby, Python and more.

The API is SO FAST that iPhone, Android and Blackberry phones zip!
The JavaScript Payload is less than 3KB.
It's a breeze for mobile phones.

Something went wrong with that request. Please try again.