Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
Tags
(+1)

Hello Leafo,

I have deployed the 1.04 update to the beast as a PWA application (to Itch and my own website) . On my own domain it works, on Itch it does not.

To see how the PWA should act (if not served via Itch's wrapper), I have hosted the game here:

https://adventuron.io/games/thebeast

For the purposes of testing, use Chrome, and you should see the button as presented here:

The purpose of PWAs is to be able to ask the player / user if they wish to install the game locally, then for the player / user to be able to use the app/game offline, via a shortcut in the host operating system.  

I suspect the problem is with the Itch wrapper.

Itch also provides me with a URL to directly go to my game. Using the link shown here ALSO does not present the PWA installation button (on Chrome):

I think the problem is that the Itch wrapper (which places the contents into an embedded iframe) is somehow playing havok with the following code (which must intercept the 'beforeinstallprompt' event on the Window object):

Possible solutions:

* The "game" does not start inside an iFrame, the "Run Game" button (from the main page) redirects to the index.html that I deployed inside the zipfile.

* OR fix the wrapper to see why the wrapper is suppressing the 'beforeinstallprompt' event.

Long term, it would be convenient to be able to place PWA content (not the beast - which is free) behind a paywall, as with other types of "for pay" content on Itch. 

Chris