LanguageEnglish
  • C#
  • JS

Script language

Select your preferred scripting language. All code snippets will be displayed in this language.

This version of Unity is unsupported.

NetworkTransport.ReceiveRelayEventFromHost

public static Networking.NetworkEventType ReceiveRelayEventFromHost(int hostId, out byte error);

Parameters

hostIdThe host ID to check for events.
errorError (can be cast to NetworkError for more information).

Returns

NetworkEventType Type of event returned.

Description

Polls the host for the following events: NetworkEventType.ConnectEvent and NetworkEventType.DisconnectEvent. Can only be called by the relay group owner.