-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
using Javascript on a browser causes local saving problems. #25
Comments
I think you're overcomplicating localStorage. See here for an example. |
That's fine if you just want a short-lived temp save. The problem is that localStorage is not permanent. If we wanted data that existed between plays there is a chance that the data would be gone. |
In the way of creating an actual save file, this looks promising. |
With that, you wouldn't be able to automatically load a file. Browsers have a lot of security restrictions. That's why, pretty much, either localStorage or an actual server is the way to go. Firebase offers free "server" options for apps of our overhead. I'm using it right now for work -- it's pretty solid. We could also export the game to a JavaScript desktop framework such as Electron. With that, you would have access to the file system. |
Autoloading would be nice but I do not like the idea of storing save files on a server. |
Due to internet security, Javascript is not allowed to save a file to the users system (could be a virus). The only way I can find to allow local saving is using a browsers "localStorage". The problem with this is that the file is stored in a rather hard to get to area and don't get me started on ipads either. Any kind of mobile device would be a monster to deal with.
Basically local saving is kind of spotty
The text was updated successfully, but these errors were encountered: