Setting up a Pong match is as easy as initializing PubNub, publishing actions, and subscribing to messages. And use PubNub Presence to detect when users start engaging with your Pong app.
PubNub Presence allows you to detect when users enter or leave your app. With PongNub,
presence is called within the subscribe call. And that subscribe selects a unique channel name by using a randomly generated ID, so that multiple users do not subscribe to the same channel and try to play Pong on top of one another!