I just published some WebRTC blocks that enables two Snap!s to send strings and lists to each other. It relies upon WebRTC a peer-to-peer communication standard supported by many browsers (tested in Chrome and FireFox). Because it doesn't use a server to create a connection it is a bit clumsy in that the two collaborators need to exchange some keys (e.g. via email or memory keys) and paste them into the appropriate blocks to create a connection.
The same connection can be used to create audio or video links but I haven't explored this.
It should be possible to build upon these blocks to support collaborative programming as in NetsBlox. Perhaps a better job for someone more familiar with the innards of Snap!
It isn't working for me. The start connection block doesn't open an ask box. Is there any way to connect two clients by only moving a key one way, and the other key is transferred by this protocol?
Thanks for reporting this. I just did some testing and I did have troubles getting Chrome and FireFox to communicate but I got it working with two Chrome instances.
But your problem seems to happen when loading the WebRTC code since once it is loaded the ask is run. Did you look at the browser's console to see if there is an error message when loading the code?
iceConnectionState is checking [webrtc.js:38:19](https://ecraft2learn.github.io/ai/js/webrtc.js)
iceConnectionState is failed [webrtc.js:38:19](https://ecraft2learn.github.io/ai/js/webrtc.js)
WebRTC: ICE failed, add a TURN server and see about:webrtc for more details
I'm not an expert why the ICE may have failed but it is configured to go to stun:stun.l.google.com:19302 which should be reliable and reachable. Here's a stackoverflow discussion of this.