AddCustomEventListener

Method

Add a listener for a custom visual scripting event.

Definition

public static Delegate AddCustomEventListener(GameObject gameObject, Action<string, object[]> handler)
public static Delegate AddCustomEventListener(GameObject gameObject, Action<string, object[]> handler)

Returns Delegate

Parameters

ParameterDescription
GameObject gameObject

The gameobject that we are listening on. This should be the object we expect to trigger the event.

Action<string, object[]> handler

The callback that will be handling any events raised.