Closed Descent098 closed 3 years ago
You're loading the game directly from disk (i.e. by just double clicking the index.html). When using the file:///
protocol many DOM operations are not permitted. This is one of them. Loading MP3/OGG files this way has similar problems if I recall correctly. Generally loading through file:///
is not supported by Impact and I don't think there's much we can do about it.
The fix is to load the game through an HTTP Server: Upload it somewhere or start a local server in this directory. If you have php installed you can for instance start php -S localhost:8080
in this directory and then access the game through http://localhost:8080
in the browser. Python and NodeJS have similar HTTP Servers built in for testing and development.
@phoboslab Makes sense, thanks for the explanation and your work maintaining this project. Is it possible to chuck that up on the site just as a note for other people like me?
It's in the Getting Started guide, right in the first paragraph :)
I don't know if this repo is associated with the website with the demos, but one of the examples on the site (pong) has a bug that keeps the game from loading.. The error seems to be coming from this line and reads:
This keeps the loading bar from progressing, and causes the game not to load. Here is a screenshot:
I am not familiar enough with the codebase, or these low level DOM operations enough to submit a patch, but thought it was worth flagging.