Tracking and dialogue systems and quests through scenes

Announcements, support questions, and discussion for the Dialogue System.
Post Reply
SuperSparkplug
Posts: 65
Joined: Fri Feb 06, 2015 3:51 pm

Tracking and dialogue systems and quests through scenes

Post by SuperSparkplug »

HI there,

I was wondering if you could explain how to handle the dialogue manager and quest track through different scenes. I've been attempting to learn how to make more my player spawn in certain places in a scene and carry information over from previous scenes with a DoNotDestroyOnLoad script. That being said, I'm noticing that because I previously made Dialogue Manager and Quest Manager prefabs available and customized individually on every scene, that it's starting to conflict and overlap with each other. However, if I just have ONE dialogue manager that carries through every scene, this makes me unable to switch dialogue databases when needed (At the moment, I have a different dialogue database for one or more conversations in different scenes. Is this alright or was I only supposed to have one with all conversations?).

How do I properly handle the dialogue system through multiple scenes?
User avatar
Tony Li
Posts: 21059
Joined: Thu Jul 18, 2013 1:27 pm

Re: Tracking and dialogue systems and quests through scenes

Post by Tony Li »

Hi,

There are a few ways to handle multiple dialogue databases and multiple scenes. This is my preferred way:

1. Put all the info that you want to carry between scenes and into saved games in your primary dialogue database. Put your temporary, scene-specific data in separate databases. You can use syncing to include data from your primary database in your scene-specific databases. Run all of your databases through the Unique ID Tool to ensure none of them have conflicting internal ID numbers.

2. Use one Dialogue Manager GameObject in a loading or startup scene. Tick Dont Destroy On Load and Allow Only One Instance. Assign the primary database.

3. In each scene, add an Extra Databases component. Set the Add and Remove triggers to OnEnable and OnDisable. Assign your scene-specific database.

For testing, you can add a Dialogue Manager GameObject to each scene. This lets you play the scene directly, without having to come through a startup scene. Just keep in mind that, in regular play, this Dialogue Manager GameObject will be destroyed by the one in the startup scene.


Referring back to step #1 above, the primary database should contain all quests that you want to track through different scenes. If all of this stuff with Unique ID Tool and database syncing is a hassle, you might just want to put everything in a single dialogue database. Since you have multiple databases right now, you can use the Merge Database feature to merge them into a single database.
SuperSparkplug
Posts: 65
Joined: Fri Feb 06, 2015 3:51 pm

Re: Tracking and dialogue systems and quests through scenes

Post by SuperSparkplug »

Okay, I merged all my databases together into one. However, I cannot do Step 3. Your Extra Databases Component does not exist on my end.
User avatar
Tony Li
Posts: 21059
Joined: Thu Jul 18, 2013 1:27 pm

Re: Tracking and dialogue systems and quests through scenes

Post by Tony Li »

Extra Databases is in version 1.5.2. But since you've merged into one database you shouldn't need it.
Post Reply