Feature request: multiplayer room state

0 favourites
  • 6 posts
From the Asset Store
State Machine
$10.99 USD
State Machine is a great tool for managing the state of anything in your game.
  • I would like a feature where the host is able to set a "room state".

    Such as: open, closed. (custom ones would be even better)

    This will aid in making larger multiplayer rooms layout system.

    Right now when I request a list of rooms, its either those locked, or not, or both.

    But when a game has already started, and not locked (due to not having the max amount of players in the room) it also shows up as available game.

    I would like to be able to filter the available rooms on their state.

    ie

    room.state = open >>>> show link to join game

    room.state = closed >>>>> ignore

    If there is already such a mechanic in the multiplayer object, then I am unaware how to set the room to "unavailable" witout the max amount of players.

    Perhaps an easy solution would be the ability to manipulate the room's locking state while in room with peers joined.

    ie Locked, not locked.

    Host starts game, and regardless of the amount of players, lock the room.

    Though, I would prefer the first suggestion, the room state, leaves room for a lot of manipulation while everything runs.

  • Additional requests for the multiplayer object:

    Host and Peers, get a fresh list of current connected peers for peers in current room.

    This for various reasons relating to connecting / reconnecting and checking up on various elements belonging to either of the involved peers.

    Also for layout switching and use of various room / map / other layouts where the players objects are not synched.

    I am doing various ping pong like events now to check up who is in the room.

  • Ashley

    I would really like the feature to set a room state, or some method so people in the lobby, but not in the room can see the current state of the room. (awaiting peers, open, closed, running, over etc etc etc)

    Right now, I have a nice lobby system with selected region options, and once joined the host can select the country (layout) to have the battle in ....

    But, once the game started, it still shows up in the lobby list because I do not have enough players according to the max, which could lock it, and prevent it from being seen in the lobby.

    Now, players can select to join a running game and enter the pre game lobby/room. Which is very undesirable.

    Atm I have no option to indicate whether or not players are allowed to join a game in progress which have less then the maximum allowed number of players.

    Some feedback would be nice ..

    I'm getting to the point where I am going to tell my webserver through ajax the state of a room and store it in a DB, and retrieve that .... but I will have to jump through many loops with room timeouts and none existent rooms in the background this way ...

    Options ? suggestions ?

  • Hey lennaert , did you end up finding a work around for this?

  • Hey lennaert , did you end up finding a work around for this?

    Yeah.

    For both main issues actually.

    Room state:

    When joining an open room to join a game, the "lobby room" is just a room in the lobby, the host can broadcast a message with a new special room name ie From lobby room "Lobby-Pre-game" send out a message : Join room: "Actual-Closed-roomname"

    When filtering the lobby, just not have it show the closed ones derived from the room names

    This solves both issues at once. Namely closed room states and players joining later.

    This solution I applied in a later stage, before that I simply had the host broadcast a room state just once upon starting a game.

    If a player joined in later, the host would not hand out that gamestate again, ie "GameRunning"

    As a side effect, I made the host send out "spectator" game state to players joining after the game had started, of which you can most likely guess its use

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Ahh thanks lennaert,

    While it isn't suitable for me to use in my current project, you did give me an idea. I am skipping the lobby so I now just send a max peer variable to all players connected and get the all to rejoin the game if the host wants to start before the built in max limit has been reached.

    Cheers.

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