diff --git a/index.html b/index.html
index 3c3554ae1..cdd8323f7 100644
--- a/index.html
+++ b/index.html
@@ -60,6 +60,7 @@
+
@@ -130,9 +131,12 @@
});
function buttonScreenshotTock() {
- AFRAME.scenes[0].setAttribute('screentock', 'type', 'jpg');
- AFRAME.scenes[0].setAttribute('screentock', 'takeScreenshot', true);
+ const screenshotEl = document.getElementById('screenshot');
+ screenshotEl.play(); // double check playing in case we're in editor mode
+ screenshotEl.setAttribute('screentock', 'type', 'jpg');
+ screenshotEl.setAttribute('screentock', 'takeScreenshot', true);
}
+
function startEditor() {
var sceneEl = document.querySelector('a-scene');
sceneEl.components.inspector.openInspector();