Cloud Lobby Chat !

Hi there,

After lots of reseach about the available options and technical solutions, I just want to make sure about something.
I know that we cant send RPC's between players on Lobby for the Photon Cloud solution ! but if there absolutely no way to go through ? using for exemple the function :
PhotonNetwork.networkingPeer.OpRaiseEvent couldn't be a solution ?

If its possible to send chat messages this way, how should the parameters should be set ?
What are the related risk for a massive use of this function ?

P.S : Having a chat on the Lobby is an absolut need


Thanks for answering.

Comments

  • I think you missunderstood what the lobby is in LoadBalancing

    The lobby is there not a lobby in the realworld sense. Its purpose is only to offer an entry point to make load balancing possible between the game servers which handle the real communication.
    The master server which offers the lobby could technically even be done through a webservice on PHP, but it would be slower and lose some of the current benefits due to the database dependency.

    Its definitely not suitable nor reasonable to try to extend that usage as it will no longer do its primary job in a reasonable form and thats load balancing, anything else it does is just there cause its required to do perform this task.


    If chat on lobby is absolutely needed, then you will have to host it yourself and invent an own architecture thats even able to technically maintain the load (unless you expect your game to be an absolute flop and hence having low load - but then you would not invest the effort I guess :)).
    Traffic costs for what you hope to do there will be between insane or unpayable.

    Actually if you want a lobby with chatting in you should better start with the normal LiteLobby server instance and extend it in the way to have server to server communication for chat exchange, cause if you allow chat in the lobby it can just as well act as game server too.

    if your target is to get chat before the game really starts as in games like League of Legends in the hero selection and RTS for years, then you wouldn't do that in the lobby, you would do it as part of the game logic.
    If your target is to get something like league of legends chat in the standalone launcher, then you would on the other hand use a webservice cloud with websockets or similar with a database cloud cause that is fast and scaleable enough to handle it. A singular server independent of the strength of the hardware stands no chance to maintain a global chat (thats the reason why MMOs don't offer global chat channels. not even blizzard can invent and pay that and WoW has laughable concurrent user numbers in WoW on the whole cluster compared to what the master server / load balancer has to handle to really do its job)
  • actually I m aware about the loadbalancing server implemented in the cloud and why there is no possible RPC communication enabled out there, I m just needing a fast solution to implement for a small number of beta testers (launching closed beta), and for sure a whole independant solution will have to be implemented to handle the "lobby" chat when the game is released !
  • I see
    In this case I would take a totally different and simpler path: There is a free IRC addon on the Unity Asset Store. I would hook that up and either connect to a public or a self hosted IRC server (its pretty simple to get them going nowadays thanks to all in one installers).

    that way you are completely free from all the hazzle related to that and get many more features than you would get from an own implementation
  • We can't support chat (or any event sending) in the lobby. The number of players is unlimited there, so we can't guarantee it to work. Much less, we want to send join and leave events for anyone just looking for a game, so you would never know if the other is still around.

    How about having special "hang out" rooms for chatting? When players want to chat, they obviously don't wait to be matched - matchmaking will be fast and painless, so there would be no time for that anyways. So people obviously take a break anyways.
    You can have many hang outs and join those randomly, too. Just add a custom property when any client creates a room. Example: Key could be "t" (for room Type) and the values: "h" (Hangout) or "b" (Battle). Then make sure "t" is being listed in the lobby (a parameter in CreateRoom allows you to list it) and when players join a room, they either battle or hang out?
  • yeah I already gave a look at that and I saw a large number of people complaining about it ! Thanks for your help and suggestions I will let you know what we did choose at the end.
  • should it fail drop me a PM and I will see to dig up my own IRC plugin I wrote but never finished due to a vanishing interest in such a plugin.
    Its just a barebone one but enough to chat in global rooms and light enough to modify for your needs.
  • that would be great ! thx
  • Tobias:

    Is there anyway to switch rooms with one command?

    I also want players to chat in a sort of staging area. I was thinking of dropping everyone into a default room... then once they are ready to launch into the match, it switches them to a new room.

    But it seems as though I would need to leave the current room (wait for that event) and then join another... and hope nothing gets messed up in there :(

    ... being able to get the players in the lobby and or just being able to send an RPC with just a single string would be so helpful....
  • Tobias
    Slight problem with trying to do a "hang out" or default room where RPCs would work...... you can't call GetRoomList while in a room. So if players wanted to look up rooms to join while chatting or preparing to go into the game room (or whatever) it's impossible :(

    Anyway to enable GetRoomList while in a room?
  • No, it's not possible to get room lists in rooms. They are spread across a range of Game Servers and we don't sync all room names everywhere.
    If you want to hang out while idling and looking for games, you potentially could use a second connection (taking away 2 ccu's per user). One peer would be in a room chatting and one would look for games.

    Do you expect players to hang around looking for games? Our idea is to get them into games asap and then let them play (or chat).
    The time spent on looking for a game should be minimized, not maximized.
  • Tobias,
    Different games call for different things. In my game Quintet (up to 5 people control 1 space ship). Players wanted to talk about who was making the ship, what positions they would use, also which map/scenario they wanted to play. It also helped players to see other people chatting (and makes them not leave the game thinking no one was there).

    I ended up making my text chat system to handle when people are in the lobby. (I wrote my own web service).
  • I was simply missing that info / scenario.
    Not sure if I described this before:

    If you make up your groups in the room while chatting, you could use one special room for that. This one has a bigger player count and is the only visible room in the lobby (which you don't need).
    The players chat and form groups. Once they are ready, one player takes control and sends a room name to his select crew. A room name is easy to make up: Combine the players' names or let them enter a ship name and add a timestamp. Then everyone can join this room and they play outside the crew-searching room.
    If you implement it this way, the crew-searching room still should have a player limit but a higher one. Allow up to ~32 players in it and let everyone just randomly join this. If the current crew-room is full or none exists, create one on the fly.

    An external chat has the benefit that you can make it fully room-independent though. You can implement private messages, groups, etc, so there still is a benefit to this approach.

    On the Master Server we also send statistics events which have the current number of players and rooms, so you can show how active the game is at the moment.
    I would display a message with "low user count at the moment" when there are less than X players. Make sure to point them to some day-time to return like "at 6pm most players are active". Otherwise, I wouldn't mention this.