public void SendClientNotReady() { if (!IsNetworkActive) { return; } Transport.ClientSendPacket(MessageId.ClientNotReady); }
public void SendClientEnterGame() { if (!IsNetworkActive) { return; } Transport.ClientSendPacket(MessageId.ClientEnterGame); }
public void SendClientReady(string userId) { if (!IsNetworkActive) { return; } Transport.ClientSendPacket(MessageId.ClientReady, new StringMessage { value = userId }); }
public void Send <T>(byte messageId, T message) where T : INetSerializable { if (!IsServer) { Transport.ClientSendPacket(messageId, messageData: message); } else { Transport.ServerSendPacketToAll(messageId, messageData: message); } }
public void Send(byte messageId) { if (!IsServer) { Transport.ClientSendPacket(messageId); } else { Transport.ServerSendPacketToAll(messageId); } }