Message Room

Overview

Sends messages to other players in the same room. The message sender player has to be in a room to use this API.
Methods
Called by players to begin an asynchronous operation to send message to other players in the same room using the specified string messageData.
Called by players to begin an asynchronous operation to send message to other players in the same room using the specified serializable object messageData.
Class
The error that occurred when a lobby API operation failed.
Maximum size of a message data is 4.5KB.

Example

1
NetworkClient.Lobby.MessageRoom("Hello", (bool successful, SWLobbyError error) =>{
2
if (successful){
3
Debug.Log("Sent room message");
4
}
5
else{
6
Debug.Log("Failed to send room message " + error);
7
}
8
});
Copied!
Copy link