Is there any way of hosting multiplayer not from a peer?

Get help using Construct 2

Post » Wed Jun 28, 2017 4:18 pm

Some people who join the game have a really bad connection. This makes it a trouble for others to join that person. Is there any way I could host the multiplayer game form a certain server?
Posts: 1
Reputation: 152

Post » Wed Jun 28, 2017 7:11 pm ... onstruct-2

There are a number of links to tutorials under the "Learn how to make multiplayer games" section. I'm not sure if they specifically explain how to set up a dedicated server, but they do talk about it in at least one of them. Have you already read over them?
Posts: 49
Reputation: 3,975

Post » Sat Jul 22, 2017 3:40 pm

What I have done is prevent the ability of a peer to create a room depending a hash value in the URL. For example, if my game URL is "", to be a host the peer would need to enter a URL with a "secret" hash similar to "" or ""

Here is how to use it:
After logging in, but before joining a room, add a System condition to compare two values. Compare Browser.Hash to whatever you want the "secret" to be. Compare: Browser.Hash Equal to #mysecret

If the user is allowed to be host, create a new room with a unique name. For testing I simply used the Multiplayer.MyID for the room name.

If the user is not allowed to be host, get a list of rooms. If no rooms are joinable, tell the user that there are no Hosts or servers, or whatever message you want to say... or tell them to send you an angry email :)
Posts: 21
Reputation: 4,602

Return to How do I....?

Who is online

Users browsing this forum: No registered users and 5 guests