Forum rules - please read before posting.

[Solved]Game stays in Cutscene state after save

edited April 2021 in Technical Q&A

Hi !
I'm having an issue on nintendo Switch where the save system seems to not let the game go back to normal mode.
I implemented the iSaveFileHandler and correctly replaced the regular one with mine, everything seems to work as i can load the saves (the screenshots work, etc.).
However, after the save, the cursor is hidden and the game is in "Cutscene" state according to the AC log.
Gameplay is blocked.

I've added debug to both my own implementation and also the SaveSystem.cs file.
The game calls the
StartCoroutine (PrepareSaveCoroutine (saveID, overwriteLabel, newLabel));
line but doesn't reach the end of the function right after that (i added a Debug.Log right after that).
It does reach the end of the PrepareSaveCoroutine function (i added a Debug after the yield return null; line).

Any idea what might cause that to happen ? The save system works on PC and does not hang like this.
Thanks!

Comments

  • edited April 2021

    What is your AC version? There is no "yield return null;" line in the current release's PrepareSaveCoroutine.

    How are you saving the game? Directly via a SavesList menu element, or through use of the "Save: Save or load" Action?

    By "the AC log", are you referring to the AC Status box? If not, enable it from the bottom of the Settings Manager. If the game is in a Cutscene state due to an ActionList being run, it should list the ActionList in question.

  • Yes i meant the AC status box.
    The ActionList calling the save is indeed still running but i don't know why.

    To save, it's directly from a SavesList menu element.

    The AdventureCreator version is 1.71.4

  • edited April 2021

    The SavesList element can either save a game directly (with "Save when click on?" is checked), or indirectly (by running an ActionList that handles the saving).

    Which are you using? Can you share screenshots of both the SavesList element, and the ActionList you're running?

    The SaveFileHandler's Save function needs to invoke the SaveSystem's OnFinishSaveRequest function once its complete. Is your custom handler doing this, and what is it setting that function's "wasSuccesful" parameter to?

    The Save Action will wait until the EventManager's Call_OnSave function is triggered with a FileAccessState.After parameter. If the Action isn't ending, it's likely this isn't being called. Try placing a Debug.Log statement in Call_OnSave to see what's being called and when.

  • edited April 2021

    I found my mistake...
    I forgot to add this call:
    KickStarter.saveSystem.OnFinishSaveRequest (saveFile, isSuccessful);

    Sorry to bother you xD

    edit: you mentionned it as well ^^ thanks again. Edited to show it's solved.

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Welcome to the official forum for Adventure Creator.