0

I am trying to listen to a an event that is fired by a game when it is fully loaded.

window.addEventListener('gameReady', function(event) {
            console.log(event.data);

});

I know that the gameReady is fired when it is ready to play. IS the above code correct and is there anyway way I can view NON CLICK/INTERFACE events in the Chrome console?

Thanks

2 Answers 2

1

Use ExternalInterface to call javascript functions.

if (ExternalInterface.available)
{
    ExternalInterface.call('console.log', event.data);
}

Just remember that console.log might not be able to process flash objects.

Sign up to request clarification or add additional context in comments.

Comments

0

You must listen to the event on the flash object.

More info here.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.