Absolutely! We're here to help. Use these steps:
All customer files are handled confidentially.
Set the Dialogue Manager's Debug Level to Info. This will log almost everything that's happening under the hood.
Use the Dialogue Editor's Watches tab or a Lua Console component.
Conversations in two databases probably have the same ID number. Use the Unique ID Tool to make IDs unique.
By default, Git ignores DLL files and doesn't upload them to Unity Cloud. If you're using the evaluation version, enable DLL versioning by removing .dll from your project's .gitignore file and your global gitignore file ([user].gitignore_global in Windows, ~/.gitignore_global in Mac and Linux).
Your assets (such as scene files and dialogue databases) may have been created in Unity 4 in binary serialization mode. Unity 5 and Unity 2017+ cannot properly ready Unity 4's 32-bit binary serialization. You must open the assets in Unity 4, change to text serialization, export the assets, and then import them into your project.
If a Selector component isn't detecting your Usable, check the following:
See TextMesh Pro Support.
In your menu text and dialogue text, use the [var=varName]
or [lua(
code)]
Markup Tags. During conversations, the [var=varName]
tag will be replaced with the value of the named variable. The [lua(
code)]
tag will be replaced by the return value of the lua code. For example, to reference the player's age, you could use this Dialogue Text:
You're [lua(Actor["Player"].Age)]? You don't look a day over [lua(Actor["Player"].Age - 1)]!
Tick Show PCSubtitles During Line in the Dialogue Manager's Display Settings. If only one dialogue entry is valid each turn and it has no force tag ([f]
), then the Dialogue System will go through them without displaying the menu.
In this case, the Dialogue System automatically selects the first valid NPC entry and does not display a PC response menu.
Yes, but you must tick Use Rich Text.
Yes. See Lipsync.
Yes. You can either use the [var=?varName]
tag as described in Markup Tags or the TextInput().
Call DialogueManager.UpdateResponses()
or use the equivalent PlayMaker or plyGame action.
Add a script that listens for OnConversationLine (see Script Messages & Events), and record the line's dialogue entry ID. Examine ConversationLogger.cs
for an example of listening for OnConversationLine. To go back, call DialogueManager.ConversationController.GotoState() to jump to a previous dialogue entry. See the Dialogue System Extras page for a Backtracking Example. Alternatively, tick the Standard UI Subtitle Panel's Accumulate Text checkbox to support scrollback.
Add a Dialogue Actor component.
No. You can use the Dialogue System's Dialogue Editor inside Unity.
You can set multiple Dialogue System Trigger components to listen for OnBarkEnd to string them together, or run it as a conversation using a Bark Dialogue UI component.
Yes. Tick Allow During Conversations.
If you're using Unity 2017.3 or higher, you may need to tick the Force Module Active checkbox on your Event System's input module.
See these instructions: https://pixelcrushers.com/phpbb/viewtopic.php?f=3&t=2284
Untick the Dialogue System's Display Settings > Input Settings > Always Force Response Menu checkbox, and tick Display Settings > Subtitle Settings > Show PC Subtitle During Line.
Untick the Dialogue System's Display Settings > Input Settings > Always Force Response Menu checkbox, or use the [f] markup tag. Also make sure that Is Player is true for the player actor.
Make sure your dialogue UI has continue buttons, and that they're assigned to the dialogue UI component.
Add the SafeArea script provided by Unity in this article to your dialogue UI's main Dialogue Panel: https://connect.unity.com/p/updating-your-gui-for-the-iphone-x-and-other-notched-devices
You can create a subclass of the dialogue UI class, or handle them in Script Messages & Events. If that's not enough, you can always write your own UI that implements IDialogueUI.
Yes. The Dialogue System Extras page has example scenes using the Oculus integration and
SteamVR integration assets for Unity.
In general, the only things to keep in mind for VR are to use Unity UI canvases that appear in VR (such as World Space or Screen Space Camera) and set up your project so the VR player can interact with Unity UI. This video covers the basics of interactiong with UI in VR: https://youtu.be/4tW7XpAiuDg
Make sure to render in Screen Space - Camera or World Space.
See How do I pause the Dialogue System?.
Locate the offending Scroll Rect and set its Vertical and/or Horizontal scroll bar Visibility dropdowns to Auto Hide.
Inspect the Dialogue Manager's Input Device Manager component. Untick Control Cursor State. The Input Device Manager is an optional component that you can remove. However, it detects whether the player is using joystick or mouse (if Detect Mouse Control is ticked). If using joystick, it keeps the cursor hidden if Control Cursor State is ticked, and when Dialogue System UIs are visible it ensures that a UI element is always focused so the player can navigate using the joystick. If it detects mouse movement, it shows the cursor, and it does not keep a UI element focused since this isn't needed for mouse selection. If you want to ensure that a UI element is focused even in mouse mode, tick Always Auto Focus.
Yes. See the Input Device Manager's separate manual in Assets / Plugins / Pixel Crushers / Common / Documentation for setup instructions.
If the camera moves into the specified position then immediately swings back to "gameplay mode," your gameplay camera controller is probably taking control of the camera. Use Dialogue System Events or Dialogue System Trigger to disable control during conversations. Also make sure the camera angle name is correct.
Use Fade(stay) instead to keep the screen faded out when the command is done.
Normally, conversations use the Dialogue Manager's Default Sequence. To specify a different default sequence for a specific conversation, inspect the conversation's properties and tick Override Display Settings.
The user script runs first. This way, your user script can set up variables that your sequence might need to reference.
Use the entrytag
keyword in your default sequence. See Entrytags.
See How do I pause the Dialogue System?.
Make sure you're not moving 2D rigidbodies manually (e.g., changing transform.position
). This breaks Unity's collision detection. Use Rigidbody2D.MovePosition
or AddForce
. Also see Enable Physics2D Support.
Use Dialogue System Events or Dialogue System Trigger configured to work OnConversationStart and OnConversationEnd. Or add a script that listens for OnConversationStart and OnConversationEnd Script Messages & Events.
Use Dialogue System Events or Dialogue System Trigger or Script Messages & Events to set the actor's animator.
Yes. Use Dialogue System Events or add a script that listens for OnConversationEnd (see Script Messages & Events).
Yes.
Yes. See the Save System page.
Yes. Assign a delegate method to PersistentDataManager.GetCustomSaveData.
See Easy Save Support.
Yes, with some scripting. Due to NDAs, asset publishers aren't allowed to share code that uses console SDKs such as Nintendo Switch. This is the process to implement saves on consoles: Set up the save system as usual so you can test to make sure everything works correctly. For example, add a DiskSavedGameDataStorer to the Save System GameObject. Then make a new subclass of SavedGameDataStorer. Implement the methods (StoreSavedGameDataAsync, RetrieveSavedGameData, etc.). Then remove the original data storer (e.g., DiskSavedGameDataStorer) from the Save System GameObject and add your subclass in its place. You will probably want to implement StoreSavedGameDataAsync, and not StoreSavedGameData, because most consoles require that you save data asynchronously – that is, you let it save in the background while allowing the player to continue playing the game.
Check the syntax differences under How to Write Lua Code.
By default, the Dialogue System catches any exceptions raised by Lua code in Conditions and Script and simply logs that an exception occurred. If you're calling an external C# function in Lua, you may find it useful to allow the exception to filter up to aid in debugging. To do this, set DialogueManager.AllowLuaExceptions = true
.
Register C# methods with Lua. See Registering Functions.
Yes. Add a custom sequencer command or register a C# method with Lua. See Registering Functions.
Issues with Visual Studio, including VS Code, are not specific to the Dialogue System. However, although very rare, issues are more likely to happen with precompiled DLLs such as those included with the Dialogue System's evaluation version. Try updating Visual Studio, or upgrading or downgrading the Unity plugin.
If you tick a support checkbox in the Welcome Window to enable an optional Dialogue System feature, it should set it for all currently-installed build platforms. But if you install a new build platform after the fact, that one won't have the checkbox ticked. In this case, you'll need to tick the checkbox again.
Unity is probably using code stripping. Move link.xml from the Templates folder to the root Assets folder.
Yes! The Dialogue System includes a link.xml in the Templates folder. Move it to the root Assets folder.
The Dialogue System includes some optional networking utility scripts. If your game doesn't use networking, you can remove the requirement for full network permissions in your builds by deleting these two files:
Yes, several multiplayer solutions are supported for player-NPC conversations. (For player-player interaction, use a chat client instead.). Which solutions you use depend on the design of your game. You can use different dialogue databases for different players, or dynamically assign roles in a shared dialogue database at runtime, or conditionally run different dialogue trees (or different branches of the same tree) based on a variety of conditions including quest states, game objects and tags, and even complex Lua expressions. Although this may sound complicated at first because the Dialogue System supports many different methods, each one is actually very simple to use. And you're always welcome to contact us for support if any questions come up.
Every multiplayer game has different needs, and there are many different networking libraries – UNET, Photon, etc. – so there's no one-size-fits-all answer. Here's a brief description of a few approaches other developers have implemented.
To pause the Dialogue System, call DialogueManager.Pause()
. To unpause, call DialogueManager.Unpause().
This will pause conversations, sequences, and barks. The sequencer commands AudioWait() and Voice() will also pause. Other than this, it won't pause AudioSource, Animation, or Animator components; you must do this on your own. Your scripts can listen for OnDialogueSystemPause
messages to pause these components. (See Other Messages for more details.)
If DialogueTime is set to Realtime (the default), pausing will only affect the Dialogue System. If DialogueTime is set to Gameplay, pausing will set Time.timeScale
to 0, and unpausing will set it to 1.
Please see Assembly Definition Files.
You can remove these three folders:
Make sure you have imported any third party support packages that you need first.
If you've imported third party support packages, you can move Assets/Pixel Crushers into another folder except not into the Plugins folder. Assets/Pixel Crushers contains third party support files that depend on third party assets that are not in the Plugins folder. Unity compiles everything in Plugins first. Then it compiles everything outside of Plugins. If you move this folder into Plugins, your project won't be able to compile because the third party support files will not be able to find the third party assets since they haven't been compiled yet.
Optional:
You may want to keep the Templates folders if you expect to use them. They're tiny, and the template scripts are commented out so they won't have any impact compile times or build sizes.
Keep the Dialogue Manager prefab which is located in the Prefabs folder. You may also want to keep the Basic Standard Dialogue UI prefab locaited in the Standard UI Prefabs/Templates/Basic folder to use as a reference when designing your own dialogue UI.
Do NOT move or rename anything in these folders:
They are special Unity folders. Unity requires that they have this exact name.
As long as you remember that Plugins, Editor Default Resources, and Gizmos are special folders with special meaning in Unity, you can otherwise move the Dialogue System's folders around. It's well behaved in that regard. For example, you can move Assets/Pixel Crushers to, say, Assets/Addons/Pixel Crushers. Or you can move Assets/Plugins/Pixel Crushers/Dialogue System to Assets/Plugins/Dialogue System.
However, it may be easiest to leave Asset Store assets in their original locations. Not all assets are as well behaved as the Dialogue System. Some rely on hard-coded paths and can break if you move them. Instead, you can create a folder named something like "__Game" to hold your own files. This way your files will be organized separately from Asset Store assets.