Building a game in the browser is one thing. Building a multiplayer game with no server is harder. These games are a testing ground for the RTCDataChannel.
Why Games?
These games push the WebRTC SCTP stack to its limit. If a peer-to-peer data channel can handle the 60Hz physics of a multiplayer Worms game without crashing, it can handle a production chat application.
The games
Each game below demonstrates a specific State Synchronization strategy. As you play, pay attention to the latency and how the game handles dropped packets or a player disconnecting.
PongAuthoritative-host paddle physics. 2 players.
Tic-Tac-ToeTurn-based state over a reliable, ordered channel. 2 players.
BattleshipHidden-state play: only fire/result events cross the wire. 2 players.
WormsDestructible terrain over a three-peer host at 60 Hz. 2 to 4 players.
Duck HuntSynchronizing fast, one-off events across peers. 2 players.
Gartic PhoneSharing a canvas as binary chunks over the data channel.
Want to build your own? Read the P2P Multiplayer State Sync guide.