Does using CanvasSnapshot work offline?

Get help using Construct 2

Post » Sun Nov 20, 2016 7:39 am

Hi everyone,

I had no trouble taking a screenshot with "take snapshot of canvas" and loading it later in my game, but I'm wondering if this will work (in NW.js) if the user is offline.

I'm asking this because the manual entry says: "The expression returns a data URI of the image file. This can be loaded in to a Sprite or Tiled Background object via Load image from URL" ( https://www.scirra.com/manual/126/system-expressions )

In my mind, an URL implies that the user is online, but I may be very wrong.

Thanks for any help!
B
23
S
5
G
1
Posts: 335
Reputation: 2,406

Post » Sun Nov 20, 2016 8:27 am

a data URI is a sort of URI that contains by itself all of the infos, without needing an internet connexion (It is like having your picture in a url format), but I'll test that real quick

EDIT:Just tested it offline in a webbrowser, it works
Game design is all about decomposing the core of your game so it becomes simple instructions.
B
52
S
22
G
18
Posts: 2,122
Reputation: 17,093

Post » Sun Nov 20, 2016 8:47 am

Thanks a lot! I actually thought there was a typo, and URI was URL with a low case L... ^^'
Learned something.
B
23
S
5
G
1
Posts: 335
Reputation: 2,406


Return to How do I....?

Who is online

Users browsing this forum: Baidu [Spider], marc254 and 5 guests