Multiplayer Server: General Multiplayer Server

The basic multiplayer server code that comes with this plugin is a basic bounce server that connects two players to the same room and allows them to send public and private messages to each other or everyone connected to the room. There are a number of server events that you can listen to for some important information. The official server type name for this server type is "DefaultMPGameServer".

Event Descriptions

"RoomEntered" - This event is fired once the player connecting to the room as successfully entered the room and it also returns the current logged in players' username. This is great for knowing which player is the current player when looking through the player list that is returned from the server.

"PlayerList" - This event will return a list of all the players currently connected to the room. Every time a player enters or leaves the room this event gets fired from the server. Use a List Data component to store the list of player usernames that gets returned with this event.

"PlayerJoined" - This event gets fired to all the other players already connected to a room when a new player joins. This is how you will know if you need to create a new object on all the other players' screen if a new player joins, for example a poker table with a new player that joins. The new players username is passed with this event. Keep in mind that only the other players in the room will receive this event not the new player connecting. You will notice in multiplayer tile demo that this event is listened to so that all existing player pieces can tell the new player that they already exist and pass the new player their current state. This is a good way to update the new player of the current state of the game.

"PlayerLeft" - This event gets fired when a player leaves the room.

Room Type name - "DefaultMPGameServer"

Listening For Events


All you have to do is add a Multiplayer Receive Message action and put the message name in quotes to receive the message. Make sure to specify a Data or ListData Container component to store the returned values from a server event if there are any.

Follow Us For Updates