In localhost, the video plays perfectly.
However, after uploading all my files to CPanel and running my website, all the videos become still images, as they are not playing at all.
No related console error I guess, except for “Uncaught (in promise) DOMException”. It may actually be related, as I have five “Uncaught (in promise) DOMException”, and I have five videos in total. If so, why would the videos cause errors in promise requests, as the videos are all stored within my server?
Anyone knows how to tackle this issue? It will be super helpful.
this.gameVid = this.game.add.video(this.gameName);
this.gameVid.volume = 0;
this.gameVid.loop = true;
I knew it… friggin COG web security blocked the autoplay functionality. Fortunately, my vids can use inputs to disable it. But then, I would still like to figure out the appropriate way to enable autoplay without ‘hardcoding’ the autoplay.