-
Notifications
You must be signed in to change notification settings - Fork 68
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
Save command will use JS.saveGame online #1372
Conversation
When saving progress online, the text from `#divOutput` is not retained when using `request`. In 5.8, we changed it to use the game object attribute set by `JS.whereAmi()`, which ended up being unused (due to issues when run from the init script). This script initially included a call to whereAmI if the attribute was not set, which was also problematic, and it devolved into its current state -- which does not work on its own. This will not use JS to check the platform and will still use JS to save when online.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure why we should have separate code for desktop and web within an ASLX file. Shouldn't RequestSave
do the right thing instead?
else { | ||
JS.saveGame () | ||
} | ||
if (IsDesktop()){} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The open and close braces here looks like an error?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The open and close braces here looks like an error?
This is proof that I should switch back to Notepad++. I like VS Code, but I apparently need to "practice" with it before using it for important things.
I just fixed this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure why we should have separate code for desktop and web within an ASLX file. Shouldn't
RequestSave
do the right thing instead?
I agree.
I looked at that code a few times before doing it this way, and I don't know what that C# code is doing. If you can make RequestSave
handle it, that sounds much better than this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there an Issue for this one?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
10-4
When saving progress online, the text from
#divOutput
is not retained when calling therequest
script.In 5.8, we changed it to use the game object attribute set by
JS.whereAmi()
, which ended up being unused (due to issues when run from the init script). This script initially included a call to whereAmI if the attribute was not set, which was also problematic, and it devolved into its current state -- which does not work on its own.This will not use JS to check the platform and will still use JS to save when online.