Search Unity

[Released] Dialogue Chains - Branching Interaction Editor using Triggers/Inventory/Stats or Input

Discussion in 'Assets and Asset Store' started by RobotDestroyer, Aug 29, 2017.

  1. RobotDestroyer

    RobotDestroyer

    Joined:
    Aug 29, 2017
    Posts:
    3
    DIALOGUE CHAINS - Visual Editor for branching Game or NPC Interactions

    Say you want an NPC to check if the player has the "Mystical War Hammer of Magnificent Death", and if so, you want him to tell the player that he doesn't like the hammer, so he takes it from the player, but only if that player's strength stat is below six, otherwise he fails to take it and tells the player how humiliated he is. Also you want a sound effect to be played when he fails, and you want your game to remember he already tried to take it so he'll never try again.

    I would first say that you're awesome! Because that sounds like a sweet game. But I also would ask that you check out my Dialogue Chains - Branching Dialogue Editor, because I made that editor to handle situations exactly like that.



    Get it on the asset store: www.assetstore.unity3d.com/en/#!/content/97528

    Dialogue Chains handles branching dialogue like you would expect, user input decides which path the dialogue takes. However, with my editor you can branch dialogue depending on all of these values:
    • Triggers
    • Inventory
    • Integer Variables
    • AND User Input
    You can also set the triggers and integer variables, add to your inventory, give player experience, play sound effects, change music and pause the dialogue for the player to return to the NPC and continue from the same point.

    The asset has a few Tutorials to cover getting started and using the features. I'd love to add more if there seems to be demand for them. Check them out at: www.youtube.com/channel/UC90oJE2eLYLbt7znn6eyFVQ
     
  2. Winston-Smith

    Winston-Smith

    Joined:
    Sep 2, 2013
    Posts:
    3
    @RobotDestroyer I'm loving this plugin, it was very easy to write some simple dialogues for my prototype!

    Quick question, is there a built-in mechanism to advance to the next dialogue without waiting for the user to advance? otherwise I can add it myself...
     
  3. RobotDestroyer

    RobotDestroyer

    Joined:
    Aug 29, 2017
    Posts:
    3
    @Winston-Smith
    Thank you!
    Unfortunately there isn't a method to do that. Well there is, but it'd be complicated. You'd have to know the next event to call, and you'd probably want to know exactly when the text is done writing.

    I can point you in the right direction! In the DialogueController script, there is an IEnumerator method called RunNextEventAfterUserConfirms. That method does the following in order:
    1) waits until the dialogue in no longer fading in.
    2) while the dialogue is writing to the screen, it checks to see if a button to complete the dialogue is pressed and completes it if so.
    3) finally, it constantly just waits for an advancement button to be pressed.
    4) when pressed, it moves on and calls two methods. CloseDialogue() and chain.RunEvent(cEvent) which runs the next node.

    What you should do is go to that IEnumerator and add/replace with your code to wait a certain amount of time once isWriting is no longer true. Calling those last two methods will move on, so just call them when you want. And isWriting is a bool that returns false once all of text has been written to the screen. You also need to wait for isFading and isWaiting to be false. In case the node uses fading or waiting.

    So very simply, you could make that IEnumerator just have a while(isWriting || isFading || isWaiting) loop and wait for end of frame over and over. Then wait for a bit once it's done writing. Then call the last two methods from step 4 and you'll have what you want.

    Hope this helps!
     
    Last edited: May 10, 2018
  4. Winston-Smith

    Winston-Smith

    Joined:
    Sep 2, 2013
    Posts:
    3
    Thanks for the quick reply, I'll give that a go!
     
  5. Lord-Kiyo

    Lord-Kiyo

    Joined:
    Jun 30, 2018
    Posts:
    20
    This sounds like an awesome tool. I am new to Unity, and have been looking up best ways to do branching dialogue. And it all seems to be overly complicated. Would it be hard to install this tool? and would it stop working with later versions of Unity?

    I will need to read about this thing and look up the tutorials when I can. But it sounds like an awesome tool.
     
  6. Lord-Kiyo

    Lord-Kiyo

    Joined:
    Jun 30, 2018
    Posts:
    20
    Okay I purchased it. However I am having trouble getting it to work for me. I'm wondering if I can get some hands on help, and I can pay for your time if you like.
     
    Last edited: Aug 25, 2018
  7. CelticKnight

    CelticKnight

    Joined:
    Jan 12, 2015
    Posts:
    378
    I have been looking at getting this product but I'm also worried about using this package - I have purchased a couple of assets only to have them not work as advertised, how are you finding the product? Were you able to get any help? Would you recommend this product to someone like me?

    Warmest Regards.
     
    Last edited: Sep 10, 2018
  8. Lord-Kiyo

    Lord-Kiyo

    Joined:
    Jun 30, 2018
    Posts:
    20
    I at first had a bit of trouble trying to get it all set up. But this can be due to me being new to Unity. I was eventually able to get in contact with the creator of this tool, and he helped me get it fixed up and got it working. And it works very well and I love it. It is very easy to make branching dialogue, and make triggers that can make the characters remember what was said in the past. So I would recommend this one for sure. So far it seems to do everything that was shown in the tutorials. However there is one thing that is not working right at the moment. Being able to flip the the containers. However the creator is aware of this and says he will look into it.
     
    CelticKnight likes this.
  9. CelticKnight

    CelticKnight

    Joined:
    Jan 12, 2015
    Posts:
    378
    I didn't think you were going to respond so I went ahead and bought another dialogue product which is giving me some real headaches. Trying to get it sorted out now with the developer. But thanks for responding it's great that you got most of the problems sorted, it's given me an avenue to try out if I can't get the problems sorted with the product I bought. I am not all that new to Unity, but, trying to use any asset free or otherwise has always caused me problems. This product was a little more expensive than Dialogue Chains and feeling a little disappointed at the moment :(.
     
    Last edited: Sep 16, 2018
  10. RobotDestroyer

    RobotDestroyer

    Joined:
    Aug 29, 2017
    Posts:
    3
    Whoa sorry everyone, I don't check this thread very much at all. I'm happy to help but I think you need the @RobotDestroyer to alert me when you post. Otherwise I try to check my email pretty frequently!
     
  11. mykillk

    mykillk

    Joined:
    Feb 13, 2017
    Posts:
    59
    Hi @RobotDestroyer

    This is a good asset, but there's one huge issue for me right now. The code isn't placed in a namespace and there are some conflicts with other classes in my project.
     
  12. HenryChinaski

    HenryChinaski

    Joined:
    Jul 9, 2013
    Posts:
    97
    @RobotDestroyer

    Since there is no public documentation I need to ask if it is easily possible to use your asset together with our Super Text Mesh component that needs a function to play text and a function to unplay text.
     
unityunity