Playmaker save/load

Announcements, support questions, and discussion for the Dialogue System.
Post Reply
pewldo
Posts: 8
Joined: Thu May 13, 2021 5:22 am

Playmaker save/load

Post by pewldo »

Hi.

I am trying to save/load dialogue system related data by using playmaker functions. Everything is working fine when I save and load while the scene is playing. However it does not store the string variable. When trying to load data that was saved during an earlier playthrough I get this message; Save : FSM : load : LoadGame : Saved game data is an empty string

Can anyone attempt to explain how I store this data?

I was a bit unsure where to post this question, is it better posted on playmakers forums?

Thank you
User avatar
Tony Li
Posts: 21681
Joined: Thu Jul 18, 2013 1:27 pm

Re: Playmaker save/load

Post by Tony Li »

Hi,

If you set up the Dialogue System's Save System, the Dialogue System's Save Game action will save the game to a storage destination such as disk or PlayerPrefs.

If you don't want to set up the Save System, you must store the string yourself. You can use PlayMaker's PlayerPrefs actions to store it in PlayerPrefs.
pewldo
Posts: 8
Joined: Thu May 13, 2021 5:22 am

Re: Playmaker save/load

Post by pewldo »

Hi

Thank you for your answer.

I have set up the save dialogue system and using the Demo UI it does indeed work flawlessly. It is when I try to load the game with the load game action in playmaker that I get the error.
User avatar
Tony Li
Posts: 21681
Joined: Thu Jul 18, 2013 1:27 pm

Re: Playmaker save/load

Post by Tony Li »

Hi,
pewldo wrote: Thu May 13, 2021 9:07 amI have set up the save dialogue system and using the Demo UI it does indeed work flawlessly. It is when I try to load the game with the load game action in playmaker that I get the error.
Do you get the error in the demo when loading?
pewldo
Posts: 8
Joined: Thu May 13, 2021 5:22 am

Re: Playmaker save/load

Post by pewldo »

I am speaking here of the Demo Menu script that can be attached to the Dialogue Manager.

When using that Demo Menu to save/load it works. It is only when I attempt to save and load through playmaker actions that I get the error.
saveload.png
saveload.png (273.99 KiB) Viewed 905 times
User avatar
Tony Li
Posts: 21681
Joined: Thu Jul 18, 2013 1:27 pm

Re: Playmaker save/load

Post by Tony Li »

Hi,

Thanks for the screenshot. Use the Pixel Crushers Common > Save Game To Slot and Load Game From Slot actions. These will save the data to storage. (The Dialogue System > Save Game and Load Game actions, on the other hand, only save and load strings, which you can store on your own.)
pewldo
Posts: 8
Joined: Thu May 13, 2021 5:22 am

Re: Playmaker save/load

Post by pewldo »

Hi

That did it:)

Thank you for your time!
User avatar
Tony Li
Posts: 21681
Joined: Thu Jul 18, 2013 1:27 pm

Re: Playmaker save/load

Post by Tony Li »

Glad to help!
Post Reply