hi,
I want to emit an event in the eval function where the name of the event is a variable in a script file.
so I want to do the following :
eval(“cc.systemEvent.emit(EventNames.myEvent, “parameter”);”);
however , I get the error : cannot find EventNames.
can someone tell me how I can trigger the above global event with a string parameter?
thanks!
[Note : EventNames is imported in the script file that contains the eval function and myEvent is a valid member variable of EventNames]