Restart Game (With Adventure Creator) remembers past choices

Announcements, support questions, and discussion for the Dialogue System.
perezbalen
Posts: 40
Joined: Mon May 24, 2021 7:22 pm

Restart Game (With Adventure Creator) remembers past choices

Post by perezbalen »

Hi

I'm running DS with Adventure creator.
When I want to restart the geme, I use an AC action list that says "Engine->End Game->Restart game"
But the new game starts with the previous run dialogues as seen. My guess is that it's not resetting the database to its default state. How can I do that?

This are my bridge settings:
Image

Thanks.
User avatar
Tony Li
Posts: 22108
Joined: Thu Jul 18, 2013 1:27 pm

Re: Restart Game (With Adventure Creator) remembers past choices

Post by Tony Li »

Hi,

Please import this patch:

DS_ACPatch_2023-07-21.unitypackage

It updates the RememberDialogueSystem script to hook into AC's EventManager.OnRestartGame to reset the DS data when restarting the game.

This addition will also be in DS 2.2.39.
perezbalen
Posts: 40
Joined: Mon May 24, 2021 7:22 pm

Re: Restart Game (With Adventure Creator) remembers past choices

Post by perezbalen »

Thanks. But I'm still having the problem. Is there anything else I need to do other than import the patch to activate it?
User avatar
Tony Li
Posts: 22108
Joined: Thu Jul 18, 2013 1:27 pm

Re: Restart Game (With Adventure Creator) remembers past choices

Post by Tony Li »

Hi,

Make sure your Dialogue Manager GameObject has these components:
  • Dialogue System Controller
  • Instantiate Prefabs (optional)
  • Input Device Manager (optional)
  • Remember Dialogue System
  • Save System
  • Json Data Serializer
  • PlayerPrefs Saved Game Data Storer (not used, but required to silence a warning)
  • Dialogue System Saver (assign a unique key value such as "DS")
perezbalen
Posts: 40
Joined: Mon May 24, 2021 7:22 pm

Re: Restart Game (With Adventure Creator) remembers past choices

Post by perezbalen »

Thanks. I was missing quite a lot of them.
User avatar
Tony Li
Posts: 22108
Joined: Thu Jul 18, 2013 1:27 pm

Re: Restart Game (With Adventure Creator) remembers past choices

Post by Tony Li »

All working now?
perezbalen
Posts: 40
Joined: Mon May 24, 2021 7:22 pm

Re: Restart Game (With Adventure Creator) remembers past choices

Post by perezbalen »

Sorry for the delay (Disk failure meant I had to redo a lot of work).
It works now, when I restart. But when I save the game, then choose some dialogue, then load to that previous stage, the Dialogue system remembers what I did post saving. My guess is I'm missing something in my AC save settings.
User avatar
Tony Li
Posts: 22108
Joined: Thu Jul 18, 2013 1:27 pm

Re: Restart Game (With Adventure Creator) remembers past choices

Post by Tony Li »

Hi,

Does your Dialogue Manager GameObject have a Dialogue System Saver component? And have you assigned a unique key to the Dialogue System Saver? (I usually use something like "ds".)
perezbalen
Posts: 40
Joined: Mon May 24, 2021 7:22 pm

Re: Restart Game (With Adventure Creator) remembers past choices

Post by perezbalen »

Yes

Image

Here are some more details:

Image
User avatar
Tony Li
Posts: 22108
Joined: Thu Jul 18, 2013 1:27 pm

Re: Restart Game (With Adventure Creator) remembers past choices

Post by Tony Li »

When Adventure Creator loads a saved game, the RememberDialogueSystem component will tell the DialogueSystemSaver component to update all Dialogue System variables, quests, etc., from the saved game data. (Also, when Adventure Creator starts a new game, the RememberDialogueSystem component will tell the DialogueSystemSaver to reset all DS variables, etc.)

How are you remembering past choices? What do you mean by remembering past choices? In DS variables? Using SimStatus?
Post Reply