Accessing the HTML5 game from outside

Hello! Is there any way to access the game using postMessage?
I tried to use .addEventListener(‘onmessage’… , but it throws an error. Are there any other ways? And I would like to know what date the 3.5 release is scheduled for?

1 Like

Can you show the error you encountered?

3.5 release may be released in the next week or two.

1 Like

addEventListener is a function on “window” object. Not sure if you are trying to do it on nodes.In you type script file, add the following code.

start(){
const win = (window as any)
win.addEventListener('onmessage', this.onMessage.bind(this))
}

onMessage(msg){
   log('msg:', msg);
}

hope this helps.