PokéRogue
    Preparing search index...

    Class EventBus

    Extension of Phaser.Events.EventEmitter with custom event names

    Hierarchy (View Summary)

    Index
    • Removes all listeners.

      Returns void

    • Calls each of the listeners registered for a given event.

      Parameters

      • event: AnyEvent

        The event name.

      • ...args: any[]

        Additional arguments that will be passed to the event handler.

      Returns boolean

    • Return an array listing the events for which the emitter has registered listeners.

      Returns (string | symbol)[]

    • Return the number of listeners listening to a given event.

      Parameters

      • event: string | symbol

        The event name.

      Returns number

    • Return the listeners registered for a given event.

      Parameters

      • event: string | symbol

        The event name.

      Returns Function[]

    • Remove the listeners of a given event.

      Type Parameters

      • D = any
      • C = any

      Parameters

      • event: AnyEvent

        The event name.

      • Optionalfn: EventCallbackFn<D>

        Only remove the listeners that match this function.

      • Optionalcontext: C

        Only remove the listeners that have this context.

      • Optionalonce: boolean

        Only remove one-time listeners.

      Returns this

    • Remove the listeners of a given event.

      Type Parameters

      • D = any
      • C = any

      Parameters

      • event: AnyEvent

        The event name.

      • Optionalfn: EventCallbackFn<D>

        Only remove the listeners that match this function.

      • Optionalcontext: C

        Only remove the listeners that have this context.

      • Optionalonce: boolean

        Only remove one-time listeners.

      Returns this

    • Removes all listeners.

      Returns void