So in 1.3 there is no automatic reference to the controller available. One way to get around this is to add a start action to the project (Project Tab -> Actions -> Start) and set it to for example
Code:
window.controller = controller;
then you should be able to get to the controller from the parent document using your method (if you name the iframe "sencha_content")
Code:
window.frames.sencha_content.controller.goToNextScene()
or just looking for the iframe on the page (assuming you only have one)
Code:
document.querySelector('iframe').contentWindow.controller.goToNextScene()
A potential issue for both these approaches is that you can only get the controller after the animation has initialized, otherwise it will cause an error. One way to make it safer is to wrap the call in a try catch block like so:
Code:
try {
document.querySelector('iframe').contentWindow.controller.goToNextScene();
} catch (error) {
console.log("Animation likely not loaded yet", error);
}