Modular Architecture V1.0.0
Loading...
Searching...
No Matches
ModularArchitecture.Events.GameEvent Class Reference

GameEvent object, when raised it will trigger responses from all listeners,
Is a scriptable object asset file and thus works on its own without scene dependancy.
Can only contain unique listeners, duplicate listeners will be ignored for performance and scale-ability. More...

Inheritance diagram for ModularArchitecture.Events.GameEvent:

Public Member Functions

void Raise ()
void Subscribe (GameEventListener listener)
void Unsubscribe (GameEventListener listener)

Private Attributes

HashSet< GameEventListener_listeners = new HashSet<GameEventListener>()

Detailed Description

GameEvent object, when raised it will trigger responses from all listeners,
Is a scriptable object asset file and thus works on its own without scene dependancy.
Can only contain unique listeners, duplicate listeners will be ignored for performance and scale-ability.

Member Function Documentation

◆ Raise()

void ModularArchitecture.Events.GameEvent.Raise ( )
inline

◆ Subscribe()

void ModularArchitecture.Events.GameEvent.Subscribe ( GameEventListener listener)
inline

◆ Unsubscribe()

void ModularArchitecture.Events.GameEvent.Unsubscribe ( GameEventListener listener)
inline

Member Data Documentation

◆ _listeners

HashSet<GameEventListener> ModularArchitecture.Events.GameEvent._listeners = new HashSet<GameEventListener>()
private

The documentation for this class was generated from the following file:
  • Runtime/Events/GameEvent.cs