eventBus

package
v1.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 28, 2024 License: MulanPSL-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func On

func On(ev string, f func(i ...interface{}))

On is to register callback on events Only allowed to be executed during initialization

func Trigger

func Trigger(ev string, i ...interface{})

Trigger is to trigger an event with args

func TriggerCross

func TriggerCross(ev string, uID int64, i ...interface{})

TriggerCross is to trigger an event with args across player

func TriggerCrossWait

func TriggerCrossWait(ev string, uID int64, i ...interface{})

TriggerCrossWait is to trigger an event with args across player and waiting for the result

Types

type EventCallback

type EventCallback func(...interface{})

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL