Remote preview now uses TURN server

0 favourites
  • 9 posts
From the Asset Store
With this template you will learn how to use the GooglePlay Games native plugin
  • tl;dr - if you previously had connection problems using Remote Preview, it should work now.

    We're now running a TURN server for Remote Preview. Since Remote Preview uses peer-to-peer WebRTC connections (much like the multiplayer engine), due to the architecture of the Internet, about ~10% of the time peers cannot directly reach each other. The solution is to use a TURN server which acts as a relay: both peers connect to the TURN server, and that relays data between the two peers.

    This means if you previously had trouble connecting with Remote Preview (particularly likely over cell data connections like 3G/4G), it ought to now work, since the TURN server will act as a relay.

    I did briefly test this myself: before the change I could not host a remote preview on my phone using a 4G cell data connection; once I set up the TURN server, it then worked. So you can host remote previews even over cell data now! (although Wifi is probably better to avoid running up your bandwidth bills )

    However it's kind of a tricky thing to test since it depends on finding peers that can't connect and then seeing if the TURN server resolves that. So I'd be interested to hear from anyone who's had trouble connecting with Remote Preview. If it failed previously, does it work now?

  • I tested the remote preview with five friends today and it worked really well. Just to let you know.

  • Works fine on a 3G connection, although I didn't really test it before so it might also have worked before.

    Sorry to be "that guy" but would it be possible to also use this TURN server inside the multiplayer plugin?

    I'd guess that this would/could solve a lot of multiplayer issues that our mobile dev's have to deal with fairly often.

  • Sorry to be "that guy" but would it be possible to also use this TURN server inside the multiplayer plugin?

    We won't permanently run a high-bandwidth server for a free service. You can always run your own TURN server if you are so inclined.

  • Hello everyone! When I update a project on computer with remote preview activated, nothing happens on mobile devices (I have to rescan QR code again and again to see changes). Is it normal? It's really nice to have this new functionality with C3 but I hope we will have, like with C2, an additional and more instantaneous localhost preview in a future release and the standalone version.

  • Hello everyone! When I update a project on computer with remote preview activated, nothing happens on mobile devices (I have to rescan QR code again and again to see changes). Is it normal?

    In this case the mobile device should show a notification saying "host updated project". Once you see that, just hit refresh and you should get the latest project. You need to leave the remote preview window open though, you can carry on editing the project while it's open.

  • Today i tried to make remote preview and it did not work, from my end i saw him tring to connect for 5-10 sec then connection dropped, just like before TURN server. Could there be a way from my end or other, to see why the connection drop?

  • Thanks Ashley, but there is actually and for me no message after updating/saving changes (Chrome updated, only messages for host disconnected). Nothing too when relaunching the preview (ok URL is different, but it will be perhaps an alternative). The only thing I can do is indeed to refresh the page (and it's in any case a slow reload of everything, time consuming and a pain for testing, please come back with localhost/ip preview again, it was automatic and very fast).

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Ashley, I don't know why, or perhaps I was too distracted with this furtive notification (however I tried again before answering), but now it works on mobile devices (phone+tablet)! I have to click again on the remote preview button to see appear the "host updated project" message. Do we have a keyboard shortcut on the host to relaunch a preview again? And can we have an automated refresh option for clients? Thanks. SnipG: I don't know what is really your issue but previously I had to update Chrome on all mobile devices and setup this browser by default too, since it works better.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)