The engine has functionality for creating and saving a screenshot of the game on the player’s device; it works for desktop operating systems Windows/macOS/Linux (example).
I would like to implement the ability to save for other devices as well (Web, Android, iOS).
- For mobile devices, there are plugins for Cordova, using which you can save an image to the gallery. For example, the saveImageGallery plugin saves a Base64 png/jpg image on the device. Such a plugin must be connected to build the application and assembled by hand (I think online assembly will not help here).
- For the web version of the game, I have not yet found information on whether this can be done. To download the image, you must first place it somewhere. Therefore, I believe that a server is needed that will save the screenshot and provide the user with a download link.
Can I get a screenshot (or sprite) from the Base64 code?
I would like to be prompted if I think correctly and if there are no other solutions (maybe someone has already done this), or am I wrong?