Search Unity

[RELEASED] Dialogue System for Unity - easy conversations, quests, and more!

Discussion in 'Assets and Asset Store' started by TonyLi, Oct 12, 2013.

  1. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
    Ah, that's the issue. The SceneFaderCanvas is intended to be used by the StandardSceneTransitionManager during scene changes. The Fade() sequencer command, on the other hand, creates its own Screen Space - Overlay canvas for fading. A couple of notes from the manual:
    • Fade() uses a Unity UI Screen Space Overlay canvas with a Sort Order of 32766. This will cover all other canvases except Screen Space Overlay canvases with a Sort Order of the maximum value, 32767.
    • Since Fade() uses a Screen Space Overlay canvas, it doesn't support VR. If you're using VR, you may want to write your own variation of Fade() or use a different fader such as that found in Unity's VR Samples package.
    You could duplicate SequencerCommandFade.cs (e.g., as SequencerCommandVRFade.cs) and modify it slightly to create a VRFade() sequencer command that creates a World Space or Screen Space - Camera canvas instead of Screen Space - Overlay.
     
  2. SI_007

    SI_007

    Joined:
    Aug 10, 2015
    Posts:
    84

    Hi Tony,

    Thank you for your explanation, we're making progress! I modified the script in order to be spawning a Screen Space Camera. Unfortunately, the same issue arrose. Using a world space canvas can work but I am not sure of using that for a fade (as it needs to be constantly repositioned to the camera).

    I tried to modify the SequencerCommandFade script in order to use the SceneFaderCanvas (i.e., referencing the fade canvas, then triggering its animation). However, due to my lack of skills, I wasn't able to make it work after the 1st fade via the sequencer. Would it be possible for you to create a Sequencer script that would work with the SceneFaderCanvas? I think this could also be highly useful for anyone else who use your XR/VR example as a baseline for their Dialogue System setup.

    Thanks!
     
  3. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
    Hi! You can use this script (also attached as a unitypackage):

    Code (csharp):
    1.  
    2. using UnityEngine;
    3.  
    4. namespace PixelCrushers.DialogueSystem.SequencerCommands
    5. {
    6.  
    7.     /// <summary>
    8.     /// Implements sequencer command: "VRFade(in|out)" that uses SceneFaderCanvas.
    9.     /// This command assumes the scene has a GameObject named SceneFaderCanvas
    10.     /// with an Animator that has "Show" and "Hide" trigger parameters.
    11.     [AddComponentMenu("")] // Hide from menu.
    12.     public class SequencerCommandVRFade : SequencerCommand
    13.     {
    14.  
    15.         private static Animator sceneFaderCanvasAnimator;
    16.  
    17.         public void Awake()
    18.         {
    19.             var direction = GetParameter(0);
    20.             if (sceneFaderCanvasAnimator == null)
    21.             {
    22.                 var sceneFaderCanvas = GameObject.Find("SceneFaderCanvas");
    23.                 if (sceneFaderCanvas != null)
    24.                 {
    25.                     sceneFaderCanvasAnimator = sceneFaderCanvas.GetComponent<Animator>();
    26.                 }
    27.             }
    28.             if (sceneFaderCanvasAnimator == null)
    29.             {
    30.                 if (DialogueDebug.logWarnings) Debug.LogWarning($"Dialogue System: Sequencer: VRFade({direction}) can't find SceneFaderCanvas or its Animator.");
    31.             }
    32.             else if (!(direction == "out" || direction == "in"))
    33.             {
    34.                 if (DialogueDebug.logWarnings) Debug.LogWarning($"Dialogue System: Sequencer: VRFade({direction}) direction must be 'out' or 'in'.");
    35.             }
    36.             else
    37.             {
    38.                 if (DialogueDebug.logInfo) Debug.Log($"Dialogue System: Sequencer: VRFade({direction})");
    39.                 if (direction == "out")
    40.                 {
    41.                     sceneFaderCanvasAnimator.SetTrigger("Show");
    42.                 }
    43.                 else
    44.                 {
    45.                     sceneFaderCanvasAnimator.SetTrigger("Hide");
    46.                 }
    47.             }
    48.             Stop();
    49.         }
    50.     }
    51. }
     

    Attached Files:

  4. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
    Plot of the Druid Released In Early Access

    Congratulations to Adventure4Life Studios on releasing Plot of the Druid, made with the Dialogue System for Unity! If you like comedic point-and-click adventure games, check it out on Steam.

     
  5. SI_007

    SI_007

    Joined:
    Aug 10, 2015
    Posts:
    84
    Hi Tony,

    Your fading script works perfectly in VR. I truly appreciate your constant support, as well as your openness in adding these extra functionalities to your assets.

    Thanks again!
     
  6. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
    Happy to help! :)
     
  7. GrassWhooper

    GrassWhooper

    Joined:
    Mar 25, 2016
    Posts:
    109
    hey there
    i am facing a small problem, and thought i'd mention it
    basically, the goal is to achieve the effect where:

    1.Press and Hold Continue Button
    2.Text Speeds Up
    3.If text is completed, move on to next text
    4.if i lift up, return text speed to normal

    i am using the SMS Dialogue

    Code (CSharp):
    1. [SerializeField] protected Button continueButton = null;
    2.     [Tooltip("Dialogue UI that the continue button affects.")]
    3.     [SerializeField] SMSDialogueUI smsDialogueUI = null;
    4.     [Tooltip("Hide the continue button when continuing.")]
    5.     [SerializeField] bool hideContinueButtonOnContinue = false;
    6.     [Tooltip("If subtitle is displaying, continue past it.")]
    7.     [SerializeField] bool continueSubtitlePanel = true;
    8.     [Tooltip("If alert is displaying, continue past it.")]
    9.     [SerializeField] bool continueAlertPanel = true;
    10.  
    11.     [Header("Expansion Settings")]
    12.     [SerializeField] int defSpeed = 20;
    13.     [SerializeField] int fasterSpeed = 150;
    14.  
    15.     TextMeshProTypewriterEffect getLastTypeWriter
    16.     {
    17.         get
    18.         {
    19.             if (smsDialogueUI)
    20.             {
    21.                 if (smsDialogueUI.messagePanel.childCount > 0)
    22.                 {
    23.                     Transform lastChild = smsDialogueUI.messagePanel.GetChild(smsDialogueUI.messagePanel.childCount - 1);
    24.                     if (lastChild.gameObject.activeInHierarchy)
    25.                     {
    26.                         return lastChild.GetComponentInChildren<TextMeshProTypewriterEffect>();
    27.                     }
    28.                 }
    29.             }
    30.             return null;
    31.         }
    32.     }
    33.     public virtual void OnFastForward()
    34.     {
    35.         if (getLastTypeWriter != null && getLastTypeWriter.IsPlaying)
    36.         {
    37.             SetNewSpeed(fasterSpeed);
    38.         }
    39.         else
    40.         {
    41.             if (hideContinueButtonOnContinue && continueButton != null) continueButton.gameObject.SetActive(false);
    42.             if (smsDialogueUI != null)
    43.             {
    44.                 if (continueSubtitlePanel && continueAlertPanel) smsDialogueUI.OnContinue();
    45.                 else if (continueSubtitlePanel) smsDialogueUI.OnContinueConversation();
    46.                 else if (continueAlertPanel) smsDialogueUI.OnContinueAlert();
    47.             }
    48.         }
    49.     }
    50.     public virtual void OnFastForwardStopped()
    51.     {
    52.         SetNewSpeed(defSpeed);
    53.     }
    54.  
    55.     public void OnPointerDown(PointerEventData eventData)
    56.     {
    57.         OnFastForward();
    58.     }
    59.     public void OnPointerUp(PointerEventData eventData)
    60.     {
    61.         OnFastForwardStopped();
    62.     }
    63.  
    64.     private void SetNewSpeed(int speed)
    65.     {
    66.         if (!getLastTypeWriter)
    67.             return;
    68.         getLastTypeWriter.charactersPerSecond = speed;
    69.         var completeText = DialogueManager.currentConversationState.subtitle.formattedText.text;
    70.         var textUI = getLastTypeWriter.GetComponent<TextMeshProUGUI>();
    71.         int i = textUI.text.IndexOf("<color=#00000000>");
    72.         if (i < 0)
    73.             i = textUI.maxVisibleCharacters;
    74.         var textSoFar = textUI.text;
    75.         if (i >= 0)
    76.             textSoFar = Tools.StripRichTextCodes(textUI.text.Substring(0, i));
    77.         var charsSoFar = textSoFar.Length;
    78.  
    79.         getLastTypeWriter.StartTyping(completeText, charsSoFar);
    80.     }
    so i created a customized Continue Button
    it uses the TextMeshPro TypeWriter

    however the issue is that, whenever i press down, text goes faster which is great.
    but, when i lift up the button (on pointer up), what happens is that, the text idles for a while
    and after it finishes idling, it resumes writing for the correct speed
    any ideas how to solve that issue?

    by the way the
    int i = textUI.text.IndexOf("<color=#00000000>");
    this line, fails to find the last letter we wrote in the text mesh pro type writer (saw on forums it worked on the UnityEngine.UI.Text) and after investigating the TextMeshProTypeWriter i found that the maxVisibleCharacters to be very helpful

    Edit:
    for anyone interested, appearently, i needed some more sleep :D

    here is the working code

    Code (CSharp):
    1. private void SetNewSpeed(int speed)
    2.     {
    3.         if (!getLastTypeWriter)
    4.             return;
    5.         getLastTypeWriter.charactersPerSecond = speed;
    6.         var completeText = DialogueManager.currentConversationState.subtitle.formattedText.text;
    7.         var textUI = getLastTypeWriter.GetComponent<TextMeshProUGUI>();
    8.         int i = textUI.text.IndexOf("<color=#00000000>");
    9.         if (i < 0)
    10.             i = textUI.maxVisibleCharacters;
    11.  
    12.         getLastTypeWriter.StartTyping(completeText, i);
    13.     }
    have not tested with rich text yet, will do so later, and report back
     
    Last edited: Nov 3, 2022
  8. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
    Hi @GrassWhooper - Sounds like you already got it. If you run into any issues, please take a look at the example scene in this forum post and/or let me know how I can help.
     
  9. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
    A Walk With Yiayia Out Now On Steam

    Congratulations to Trent Garlipp on the release of A Walk With Yiayia, made with the Dialogue System for Unity, on Steam!

     
  10. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
    The Spirit and the Mouse - Unite 2022 Keynote

    Just caught a glimpse of Alblune's wonderful The Spirit and the Mouse, made with the Dialogue System for Unity, in the Unite 2022 Keynote at 0:24:00:



    upload_2022-11-3_14-31-39.png

    You can play it on Steam and Nintendo Switch.
     
    Last edited: Nov 3, 2022
    Homicide likes this.
  11. SI_007

    SI_007

    Joined:
    Aug 10, 2015
    Posts:
    84
    Hi Toni,

    I'm trying to use a 2nd response menu panel so that in certain circumstances the possible responses would be centered in front of the player (Transform Rect Left:350, Right:350, instead of my default Left:700, Right: 0). This is in VR, using your default world space canvas.

    I added the Override Unity UI Dialogue Controls to the triggering gameobject and inserted my 2nd response menu panel in the Panel reference. However, when the dialogue gets triggered, it is still using the default response menu panel (the 2nd response menu panel is deactivated).

    Are there other requirements for the override to work? Or would there be another way to reposition the response dialogue at runtime?

    Thanks!
     

    Attached Files:

  12. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
    Hi! You can just use a Dialogue Actor component for this. It's much simpler to set up than Override Unity UI Dialogue Controls.

    Let's assume your world space dialogue UI has two response menu panels. Make sure they're both assigned to the Standard Dialogue UI component's Menu Panels list:

    upload_2022-11-8_8-22-46.png

    Make a note of their panel numbers. In the screenshot above, the left menu panel is 0 and the center menu panel is 1.

    Then add a Dialogue Actor to the triggering object. (Remove the Override Unity UI Dialogue Controls.) In the screenshot below, I set the Actor dropdown, and then I set Menu Panel Number to 1 (the center menu panel) and set Use Menu Panel For to "Me And Responses To Me":

    upload_2022-11-8_8-24-51.png

    Whenever this GameObject is involved in a conversation, it will use panel 1 (the center panel) for menus.

    If you want to temporarily override that at any point, you can use the SetMenuPanel() sequencer command in a dialogue entry node's Sequence field.
     
  13. SI_007

    SI_007

    Joined:
    Aug 10, 2015
    Posts:
    84

    Hi Tony,

    Thank you very much for your explanation and guided picture. Using the dialogue actor setting to select my centered response menu panel as you suggested worked perfectly.

    Thanks again!
     
  14. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
    Happy to help!
     
  15. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
    Dialogue System for Unity 2.2.33 Released!

    Version 2.2.33 is now available on the Asset Store!

    This release adds RPG Builder integration and many other improvements, fixes, and updates to third party integrations.

    Release Notes:

    Core:
    • Improved: Dialogue UI response menu autonumber now allows [em] tags.
    • Improved: Added Dialogue Manager checkbox for Sequencer.reportMissingAudioFiles.
    • Improved: Dialogue System Trigger can now specify to start a conversation at a specific entry by Title.
    • Improved: When running simultaneous conversations, special Lua variables "Actor" & "Conversant" are now set to the current conversation.
    • Improved: Selector/Proximity Selector now automatically hide selector UI when disabled.
    • Improved: Added option to export Items in Dialogue Editor Localization Export/Import foldout.
    • Improved: Exposed Dialogue Editor & Unique ID Tool methods for third party script access.
    • Improved: Exposed DialogueManager.databaseManager.loadedDatabases property.
    • Improved: Added ConversationModel.OverrideCharacterCache(actorID, override) method.
    • Improved: ConversationModel.GetState() now catches exceptions from custom OnExecute() events.
    • Improved: Added Variable Name option to Custom Lua Function Info configuration assets.
    • Improved: DialogueManager.LoadAsset() loads addressables by IResourceLocator instead of name to work better with console deployments.
    • Fixed: DialogueManager.lastConversationEnded was not being set.
    • Fixed: If entrytag format is set to VoiceOverFile and entry doesn't have a VoiceOverFile field, no longer reports error.
    • Fixed: When deleting field from items template and assets, would also delete field in quests, and vice versa.
    • Fixed: Adding sequence to dialogue entry didn't instantly update icon on node.
    • Fixed: Focus Template Standard Dialogue UI prefab's Text Field UI > Canvas Group > Block Raycasts was accidentally unticked.
    • Fixed: Removed harmless assert message when entering editor play mode while SaveSystem or Dialogue Manager is hidden in Scene view.
    • Fixed: Lua script wizard no longer add semicolon at end if one is already there.
    • Fixed: Issue with editor play mode testing with Dialogue Manager set to extra warmup and starting conversation manually on scene start.
    • Save System: Changed default Frames To Wait Before Apply Data to 0.
    • Save System: Exposed SavedGameData.Dict.
    • Localization Package: Now assigns valid GUID if Guid field exists but is blank; fixed actor name localization issue.
    • Visual Scripting: Added "Get Lua Result As (type)" methods.
    Third Party Support:
    • Adventure Creator: Lua functions are now publicly accessible to C# code; acGetItemCount() now checks KickStarter.runtimeInventory.localItems.
    • articy:draft: Added Set Display Name option; updated Localization Plugin importer.
    • Arcweave: Added fast import to dialogue database inspector's Reconvert dropdown; exposed import methods for custom C# scripts.
    • Celtx Gem: Now imports breakdown and multi-tag breakdown items; fixed issue with <START> nodes being marked as group nodes; fixed import issue when first node in sequence was deleted and replaced.
    • Chat Mapper: Chat Mapper import no longer sets group nodes' Sequence to Continue().
    • Corgi: Updated for Corgi Platformer Engine 8.1; added easier setup for quest log windows.- Ink: Handles <br> tags; added support for Ink LIST variables.
    • Invector: Added Pause Invector During Conversation checkbox to bridge component.
    • Lively Chat Bubbles: Added support for portrait images.
    • RPG Builder: Added integration.
    • SuperTextMesh: Added built-in support in StandardUIContinueButtonFastForward.
    • TopDown Engine: Improved pause method to better find abilities & stop feedbacks during conversations.
    • Yarn: Fixed custom command processing issue; fixed bug which passed all custom command arguments as strings and didn't process quoted strings; added support for <<seq sequence>> commands.
     
  16. Genghis42

    Genghis42

    Joined:
    Feb 14, 2018
    Posts:
    18
    Hi Tony-

    I'm setting the script field on some entries at runtime, in the OnConversationResponseMenu event -- i.e., "response.destinationEntry.userScript = myScript". Debug logging tells me my runtime script is being called correctly (and the edit-time script is correctly ignored), but the inspector doesn't show the changes.

    I assume this means the inspector isn't reading the runtime/in-memory copy of the database? Is there any workaround to see my changes without spamming the log? Or am I abusing the system too much?
     
  17. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
    Hi - Make sure you've ticked the Dialogue Manager GameObject's Other Settings > Instantiate Database checkbox. To view the runtime database, double-click on the Dialogue Manager's Initial Database field value.
     
    Genghis42 likes this.
  18. Alic

    Alic

    Joined:
    Aug 6, 2013
    Posts:
    137
    Hey Tony! Hope you're well.

    I'm just wondering what the quick/best way is to do something fairly simple.

    I'm using some conversations as barks, and I'm using RandomizeNextEntry in the root node to randomize between different options. This only works if it's an NPC talking. In some cases, I want to use the player object (can be different characters, but dialogue system already correctly tracks which is the player object) but still randomize their choice of bark. (These lines aren't giving the player a choice.) RandomizeNextEntry is only set up to work with NPC lines, I think. How can I get the same behavior to work with entries where the player is the speaker?

    I'm also on a slightly older version, so my bad if this is just an old limitation.

    Thanks!
     
  19. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
    Hi - Try RandomizeNextEntry() in the Script field of a group node that links to the barks:

    upload_2022-11-11_13-56-36.png
     
  20. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
  21. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
    Voodoo Detective Featured in GeekWire

    Congrats to Short Sleeve Studio for the feature in GeekWire!

    Voodoo Detective, made with the Dialogue System for Unity, is a point-and-click adventure with amazing music by Peter McConnell of Grim Fandango, Monkey Island, and Psychonauts fame, and voice talent by actors from Mass Effect, Dragon Age, Final Fantasy, Fallout, Diablo, and many more. Check it out on Steam, where it has a Very Positive rating.




    In case you missed them, some other successful recent releases that use the Dialogue System include two wonderful wholesome games:

    The Spirit and the Mouse


    A Walk With Yiayia


    If you want to use the Dialogue System for Unity in your own games, you can get it for 50% off right now in the Asset Store's Black Friday Sale.
     
  22. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
  23. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
  24. Stickeyd

    Stickeyd

    Joined:
    Mar 26, 2017
    Posts:
    174
    Hello,

    Is there any way to check if StandardDialogueUI's conversationUIElements.mainPanel.panelState == PanelState.Closed before every dialogue? I have a bug where when the Close/Open runs in rapid succession the UI and the game freezes. This is the old bug. You gave me an advice to check this condition before running the dialogue, and it works, however I have a lot of different situations where I use the dialogue trigger and I just want to apply this condition to all of them.
     
  25. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
    Hi - If you can update to a newer version of the Dialogue System, that might be better. For several versions now, the dialogue UI has had "Wait For Close" and "Wait For Open" checkboxes that should resolve your issue. (Tick them on the StandardDialogueUI, StandardUISubtitlePanel, and StandardUIMenuPanel components.)

    If that's not possible, you could make a subclass of Dialogue System Trigger and override the DoConversationAction() metyhod to check DialogueManager.standardDialogueUI.isOpen or DialogueManager.standardDialogueUI.conversationUIElements.mainPanel.isOpen or mainPanel.panelState.
     
  26. Stickeyd

    Stickeyd

    Joined:
    Mar 26, 2017
    Posts:
    174
    Updating seems not ideal since after updating the Dialogue System version I start having new bugs with UI. Like for example after finishing the dialogue the character sprite blinks once before fully disabling
     
  27. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
    You will have to fix something in your custom dialogue UI in either case, whether you use the current Dialogue System version or return to the previous version. I recommend continuing with the current version to keep all of the recent improvements and fixes, but it's up to you. Please feel free to PM me the details of your dialogue UI (or post here if you want) so we can resolve the issue.
     
  28. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
    Dialogue System Extras - Integration Updates for i2 Localization, Localization Package, RPG Builder

    The Dialogue System Extras page has updated integration packages for i2 Localization, Unity's Localization Package, and RPG Builder. The improvements in these integration packages will also be included in the next regular release of the Dialogue System.

    You can also download lots of extras freebies from the Extras page, including HDRP & URP materials for the demo scene, an Excel importer, a free Menu Framework (main menu & pause menu with saving and options screen), and starter projects for various genres.

    Reminder - The Dialogue System and Quest Machine are both 50% off right now in the Asset Store's Black Friday Sale.
     
  29. mickeyband

    mickeyband

    Joined:
    Dec 30, 2018
    Posts:
    16
    Hi I just installed the latest version and on the demo level, the player is falling through the floor


    my unity is 2021.3.3f1
     
  30. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
    Hi - The demo scene uses Unity's standard physics settings. In your project, you physics collision matrix may have disabled collision detection between the Default and Ignore Raycast layers. Re-enable it:

    upload_2022-11-19_9-42-9.png

    Or change the Player GameObject to the Default layer. (It's on the Ignore Raycast layer so the demo's simple gun script can raycast through it to detect bullet hits, but since the player is slightly offset from the camera you can generally avoid the player anyway.)
     
    mickeyband likes this.
  31. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
  32. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
    Lesser Known Dialogue System Features

    The Dialogue System for Unity is 50% off in the Asset Store's Cyber Week Sale!

    upload_2022-11-28_9-0-37.jpeg

    In the latest House of The Dev podcast with Tim Cain (Fallout, Bloodlines, Arcanum), Peter Salnikov asked about the development cost of replayable content (e.g., multiple story branches) that only some players may ever see. Tim Cain replied:
    The Dialogue System has all the features you'd expect in a professional dialogue toolset, including:
    • A very full-featured node-based editor
    • The ability to do advanced conditional logic
    • A powerful runtime UI system
    • Cutscene sequences during conversations, including voiceover
    • Saving & loading conversation state
    • Built-in support for language localization
    • Built from the ground up to support easy integration with other assets and your own code, including lots of inventory and character controller assets.
    You can also import content from many other sources, including articy:draft, Arcweave, Chat Mapper, Twine, and more.

    In this post, I'll share just a few of the lesser-known features available in the Dialogue System.

    • Relationships: Manage actors' relationships using the Relationship Lua Functions.

    • Custom Fields: Your writers can add custom fields to any type. Add an Emotional State field to your actors. Add XP and Reward fields to your quests. Your quest fields could even contain Lua code or sequencer commands that your writers can use to make things happen when quests hit certain states, all without having to work within a Unity scene. You can even define your own custom field types.

    • Position Stack: Use the position stack to dip into a sub-conversation from anywhere and then "pop" back to the previous point in the conversation without having to define link arrows.

    • Random Text: Use the RandomElement() function in your dialogue text to give variety to your text so your NPCs don't always say the same thing in the same node. Or use RandomizeNextEntry() to choose randomly from nodes.

    • Keyboard Shorts: The Dialogue Editor has several keyboard shortcuts to speed up your writing.

    • Arrange Nodes: The Arrange Nodes context menu item can work on an entire conversation -- or just a subset of nodes by lassoing them -- to arrange them in a tidy vertical or horizontal tree.

    • Node Groups: Add node groups to visually organize branches of your conversation tree and move them around as a group:

      upload_2022-11-28_9-19-57.png

    • Outline Editor: Prefer outline mode for compactness or familiarity to users of the Neverwinter Nights and Dragon Age toolsets? It can do that, too:

      upload_2022-11-28_9-22-54.png

    • Customize the Editor: Or you can customize the Dialogue System editors.
      • Add your own menu items to the Conversations tab's Menu.
      • Add your own menu items to the Sequence field's "+" menu.
      • Add your own drag-and-drop handling to the Sequence field.
      • Hook into the node inspector to add your own content.
      • Hook into node drawing. For example, show both the speaker and listener and who's talking:
        upload_2022-11-28_9-34-25.png
    If the list seems overwhelming, know that you can start off easy (I recommend the simple Quick Start tutorial) and be confident that the Dialogue System will be able to handle your future needs as your project grows.
     
    digiwombat likes this.
  33. Stickeyd

    Stickeyd

    Joined:
    Mar 26, 2017
    Posts:
    174
    Ok so I tested a new version a little bit more. The bug when the character sprite blinks for a little bit after the dialogue ended is because the Dialogue Panel Hide animation is never called and its Canvas Group alpha never goes to 0. I also noticed that even though the conversation is not active and in the dialogue manager if I look at conversations I see that no conversation entries is active, and all subtitles panels are not active, StandardDialogueUI.isOpen is set true even after the conversation is over. What could be happening?

    I didn't have this bug before I updated.

    EDIT:

    Okay I can see that this bug only happens when WaitForClose checkbox is ticked on StandardDialogueUI.
     
  34. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
    Hi - Is this issue resolved for you now?

    If not, then since it's not hiding when Wait For Close is ticked, some panel is not closing -- maybe by design in your UI? Wait For Close was added in version 2.2.19, released August 2021. If the issue isn't resolved, you could either review the release notes from 2.2.19 to present, or send a reproduction project to tony (at) pixelcrushers.com along with reproduction steps. I'll be happy to take a look directly and let you know what's going on.
     
  35. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
  36. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
  37. Danibi

    Danibi

    Joined:
    Nov 10, 2012
    Posts:
    36
    Hi!

    We are porting a game to PlayStation, Xbox and Switch.
    We have an issue happening on Switch, PS4, and Xbox One. However, it does not happen on PS5 and Xbox Series.

    Sometimes the game freezes. Sometimes for a few seconds, other times for minutes, sometimes it never recovers.
    It almost always happens when we speed up the time, during a "go to sleep" function, to make the time pass more quickly.
    We didn't develop the game, so we don't know it deeply.
    By connecting the profiler to the consoles, it too remains frozen.
    Around the freeze there always seems to be the garbage collector active.
    It doesn't happen in Unity Editor.
    We are using Unity 2021.3.5, Dialogue System 2.2.14, QuestMachine 1.2.13

    Thanks!
    Daniele
     
  38. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
    Hi Daniele - Can you back up your project and then update to the current versions of the Dialogue System and Quest Machine? This way we will be looking at the same thing and not any possible old bugs that have already been addressed.

    Then attach the profiler to your build, or generate a player log. If you can attach the profiler, identify what methods and/or processes are being run when the issue happens. If you can't attach the profiler, you'll need to make a Development Build and examine the player log after reproducing the issue. If you want more detailed Dialogue System or Quest Machine logging, temporarily set the Dialogue Manager's Other Settings > Debug Level to Info and tick the Quest Machine GameObject's Debug Settings > Debug checkbox. If you're using procedurally-generated quests, you can also tick the Debug Generator checkbox. This should help you identify if the issue is related to the Dialogue System, Quest Machine, or neither.
     
  39. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
    LudoNarraCon Submissions Open

    LudoNarraCon returns May 4-8, 2023!

    Are you using the Dialogue System for Unity to make a story-rich game, or do you have an idea for a panel? Submissions are open until January 10. Many Dialogue System-powered games have been featured in previous years' LudoNarraCons. Maybe yours can be in this year's!

     
  40. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
    Dialogue System for Unity in New Year Sale

    upload_2022-12-19_11-41-23.png

    The Dialogue System is 50% off in the Asset Store's New Year Sale!

    Love/Hate and Quest Machine are also 50% off.

    You've seen the Dialogue System in action in games such as Disco Elysium, Lake, and Dwerve. Games recently added to the games showcase page include Kokopa's Atlas:



    and Age of the Witch:



    (Apologies to the other devs whose games I haven't had time to add to the showcase yet. I'll get to them soon!)
     
  41. Askalot

    Askalot

    Joined:
    Mar 16, 2019
    Posts:
    2
    Hello. I import localizations from csv files. But any importing file rewrites my main language. I can't add any change into the text on my main language (after localization it will be rewriten to old version). How can I load localization from csv files and avoid this problem?
     
  42. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
    Hi - What CSV are you importing? Are you using the Dialogue Editor's Localization Export/Import? If so, UNtick the checkboxes to the right of the languages. When any of these checkboxes are ticked, it will not only import the translation but also update the main text (e.g., Dialogue Text field).

    upload_2022-12-27_13-47-42.png
     
    Askalot likes this.
  43. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
    Dialogue System 50% Off - Sale Ends Soon!

    upload_2023-1-5_9-22-5.png

    The New Year Sale ends in less than 6 hours.

    The Dialogue System for Unity, Quest Machine, and Love/Hate are all 50% off until the sale ends in just a few hours.



    Whether the story you want to tell is epic or small and personal, you can use the Dialogue System to make it happen. Check out Trent Garlipp's short but powerful A Walk With Yiayia, made with the Dialogue System, available on Steam and Nintendo Switch, and included in The Washington Post's curated list of Indie game gems you may have missed in 2022. They write: "I didn’t expect “A Walk With Yiayia” to hit me as hard as it did. It’s only about an hour from start to finish, and it had me in tears probably about half that time. In this bite-sized walking sim, you take a stroll around the neighborhood with your Greek grandmother, who’s lost her confidence after a recent fall."
     
  44. MatrixNew

    MatrixNew

    Joined:
    Apr 16, 2020
    Posts:
    80
    Last edited: Jan 8, 2023
  45. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
    Yes, it supports import of Excel xlsx, as well as formats that better reflect highly branching dialogue such as articy:draft, Arcweave, Chat Mapper, etc. (see Import/Export). Please feel free to try the evaluation version before buying to test the various import formats.
     
  46. MatrixNew

    MatrixNew

    Joined:
    Apr 16, 2020
    Posts:
    80
    show a screenshot where to click export to get the *.xlsx file?
     
  47. DavidRodMad

    DavidRodMad

    Joined:
    Jan 26, 2015
    Posts:
    13
    So this might be quite simple, but I'm stuck and can't figure out the proper search terms to solve it, so here goes.

    How do I have a normal conversation between player and NPC where there are no choices to be made, but the player lines are treated like normal lines that will respect my "always need to click continue" setting? As it is, I'm using the template for VN and when I set an actor as player I either get a "this is a choice, choose it" mode or, if I disable that it's a choice when there is only one option, it goes through automatically without stopping on the line (can't even read it). This is really frustrating and I'm not sure what I'm missing.

    As an extra question since I'm here, is there a tutorial or good resources on advice for how to customize the given templates and modify stuff on those prefabs without breaking stuff and such?
     
  48. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
    The Dialogue System imports xlsx. Example:

    upload_2023-1-10_10-41-11.png

    upload_2023-1-10_10-42-7.png

    upload_2023-1-10_10-42-14.png

    However, I strongly recommend using a better format for branching dialogue such as the built-in editor, articy:draft, Arcweave, Chat Mapper, etc.

    The Dialogue System can export CSV for localization (it's a more portable format than xlsx) if you need to export/import for translators:

    upload_2023-1-10_10-43-48.png

    You can also export to Chat Mapper and then export from Chat Mapper to xlsx if you really need xlsx format, but again it's not a great format for dialogue.
     
  49. TonyLi

    TonyLi

    Joined:
    Apr 10, 2012
    Posts:
    12,697
    Hi - Please see: How To: Bypass Response Menu When Player Has One Choice
    In the same section, you'll also want to set the Continue Button dropdown to Always (if you haven't already) to require the player to click to continue.

    Yes - there's a video tutorial series:
     
  50. EmeralLotus

    EmeralLotus

    Joined:
    Aug 10, 2012
    Posts:
    1,462
    Hi Tony,

    I have a project that is using the ink engine in unity. https://www.inklestudios.com/ink/
    I would like to use it together with the dialogue system at runtime.

    So the use case is that at runtime, I am loading into the game ink files and then populate the Dialogue system with content from that ink file.

    I noticed that Dialogue system has integration support for ink but don't know the extent of the integration support.
     
    Last edited: Jan 10, 2023