View Source Ecspanse.System.WithEventSubscriptions behaviour (ECSpanse v0.9.0)

Systems that run only if specific events are triggered.

Summary

Callbacks

Runs only if the system is subscribed to the triggering event. The return value is ignored.

Callbacks

@callback run(event :: struct(), Ecspanse.Frame.t()) :: any()

Runs only if the system is subscribed to the triggering event. The return value is ignored.

It recives the triggering event struct as the first argument and the current Ecspanse.Frame.t/0 struct as the second argument.