Skip to main content
namespace ML.SDK
Class | Sealed

MLEvents


namespace ML.SDK
{
sealed class MLEvents
}

Summary

Manages events in Runtime.

Static Methods

MethodDescription
AddHandler(string, Action<Object[]>)Registers a global event handler for given name with given hander function.
RemoveHandler(EventToken)Removes the handler defined by its token.
Invoke(string, Object[])Invoke a global event within this client with given event name and parameter.Because this event is invoked locally, the parameters can be any type.
InvokeNetwork(string, EventTarget, MLPlayer[], Object[])Invoke global event though network with given name and parameters.Because this event is invoked through the network, the parameters must be serialize-able type.
SetSyncVar(string, MonoBehaviour)