Assets/Scripts/System/EventProcessor.cs
/// <summary>
/// Removes the passed in listener from the specified event.
/// </summary>
/// <param name="eventName">The event being referenced.</param>
/// <param name="listener">The listener method you would like to unsubscribe.</param>
Removes the passed in listener from the specified event.
Removes the passed in listener from the specified event .
public void StopListening(string eventName, UnityAction<object> listener)
    {
        UnityEvent<object> newEvent = null;
        if (eventDictionary.TryGetValue(eventName, out newEvent))
        {
            newEvent.RemoveListener(listener);
        }
    }
public void StopListening ( string eventName , UnityAction < object > listener ) { UnityEvent < object > newEvent = null ; if ( eventDictionary . TryGetValue ( eventName , out newEvent ) ) { newEvent . RemoveListener ( listener ) ; } }
Removes the passed in listener from the specified event.
Removes the passed in listener from the specified event .
eventName
string
The event being referenced.
The event being referenced .
listener
UnityAction<object>
The listener method you would like to unsubscribe.
The listener method you would like to unsubscribe .