Multiplayer-Multiple hosts/shards

  • Game scenario:

    8 players are roaming a game world.

    1 of the players enters a dungeon.

    Desired effect:

    This dungeon should now have a separate server.

    When players enter the dungeon they are placed on the new server.

    When players leave the dungeon they are returned to the main server.

    Reasoning:

    This shard behavior. Reduces stress and latency across the main game world.

    This allows more dynamic servers, and could allow for larger player interactions.

  • still interested of peoples thoughts on the subject.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Well, I can't say that I've tried this, but construct does support joining and leaving rooms (while still being connected to the signalling server) And also supports disconnecting and reconnecting to the signalling server. Perhaps you can play around with disconnecting from one room and connecting to a different room in the same game. However be aware that the Construct's multiplayer object automatically makes the first user in each room the "host", and if the host disconnects, all other players in the room are booted.

    And if you play around with it, come back and tell me if it works, so I can know how to do it later.

  • Would I be needing multiple servers running? As in multiple browser tabs, or would it be possible to do this within a single server you think?

    I'm just trying to think of ways that could make the game load in persistent chunks without needing the entire world going at once.

    My theory being that having smaller Shards to deal with would have better performance. Why load an entire world, when players only play in a small "chunk" at a time.

    I run into a wall though, because if a single machine ends up hosting multiple servers constantly. That would almost defeat the purpose of the shards, unless it could be dynamically done.

  • Well if you have instanced dungeons, you could probably write it so that you don't need a server for each of them, just make it so that if any player leaves (especially the host, or just only the host), then all players are booted (and returned to the main server). Alternatively it wouldn't be hard to make single-player instanced dungeons without a need for a server at all.

    But as I said, unless you can find someone with more experience with the multiplayer plugin and/or instancing with it, the best way to learn these things is to try them out yourself. You can simulate multiple players by using different tabs, even while you debug. (you can also do it with different browsers)

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