Simple Example:
Code: Select all
#Persistent ; Ensure script keeps running until our timmer is fired
#include <AEE>
Hello(words)
{
Msgbox, % "Hello " words "!"
; we need exit script by ourselves,
; when use #Persistent
ExitApp
}
emitter := new AEEmitter()
emitter.On("say", Func("Hello")) ; register a event
; A msgbox will show with "Hello World!"
emitter.emit("say", "World") ; fire it
Github