Chrome offline not playing

Hi, I’ve tried downloading a local version of my build. Works fine on edge and Firefox but on chrome just a black screen, is there any way round this?

thanks,
Matt

Hi @Mattturner2021 and welcome,

How are you opening your local build? Normally it requires a local web server to open correctly.

You can find instructions on how to easily setup one here:

https://developer.playcanvas.com/en/user-manual/publishing/web/self-hosting/#running-a-downloaded-build

thanks for that!

I was just opening and double clicking on the index.html file.

Kinda need a solution that can just work like that. thanks again! :slight_smile:

1 Like

This tool will work for that assuming you don’t use any wasm modules like physics or basis compression.

Use the extern files option for best compatibility.

2 Likes

yeah this looks like it should, thank you… I don’t suppose there is a video tutorial of this going through the steps?

I can’t seem to get it to work

There’s no tutorial as there aren’t that many steps.

What errors / issues are you getting?

ok so apologies, first I’m not a coder so I’m prob doing something daft.

So I have a copy of this in my folder : playcanvas-rest-api-tools. I’ve installed Node JS. Then:

  1. mv .env.template .env and add your PlayCanvas Auth Token in there
  2. mv config.template.json config.json and add your configuration in there (Project name, branch, scenes, CSP rules, etc.
  3. npm install

Then:

  1. npm run one-page

Attached is the error message I get.

thank you!

Can you show me the contents of the folder Desktop\convert please?

There’s no config.json file there. Looks like step was missed or moved to the wrong folder in your case.

thank you, where does the config.json come from ?

It’s a copy of config.template.json but renamed to config.json.

It also looks like you don’t have .env either.

Side note: I find a bug if you are using Node 14 which I’m fixing now.

eg
image

wow it works! thank you!

that the quickest and best help i’ve ever had on a forum! u didn’t even call me an idiot!

1 Like

Glad it works for you :slight_smile:

Fix in progress for Node 14: https://github.com/playcanvas/playcanvas-rest-api-tools/pull/7

1 Like