Twine Version: 2.3.5
I’ve just come back to my Twine project after an absence of about a year and discovered a bug that wasn’t there before.
I have a passage where the player enters a pub and clicks a link to play a song on the jukebox. This opens an external window using a bit of javascript to play a video from youtube. - This bit still works.
But now when you click the link to close the window nothing happens?
I know this isn’t a Twine question but hoping someone familiar with javascript might know if something has changed with Chrome/Edge permissions that could break it?
I’ve tried Chrome Version 122.0.6261.129 (Official Build) (64-bit) on Windows 10 and 11.
Many thanks!
<script>
var openedWindowMoney;
function openWindowMoney() {
openedWindowMoney = window.open('https://www.youtube.com/watch?v=TC1Vfoq3PvU&ab_channel=Historyboy87','_blank', 'location=yes,height=400,width=400,scrollbars=yes,status=yes');
}
function closeOpenedWindowMoney() {
openedWindowMoney.close();
}
</script>
(link:"Play song on jukebox")[<script> openWindowMoney(); </script>]
(link: "Stop song")[<script> closeOpenedWindowMoney(); </script>]