Newb Alert! Help please.

Announcements, support questions, and discussion for the Dialogue System.
Post Reply
scorpio66
Posts: 6
Joined: Tue Sep 08, 2020 8:58 am

Newb Alert! Help please.

Post by scorpio66 »

Hi all.
Nice to be here

I installed DS successfully yesterday, and had a look around here and there as you do.
Seems like a great asset, but I am going to ask a newb question anyway!
(This will also test the forum for replies lol)

I have searched for the question I have and there are some replies from Tony to these posts.
However, as a noob, I need a basic explanation... :(

Starting off with a basic converstation, (New Conversation 1)and the NPC and player can have several responses, how and where do I set up a variable that guides the dialogue to a certain node? Where do I input the variable?
Say, I have 3 possible responses. Need a variable. Set it where?
And when its set where do I tell the node to check this variable?

My apologies for such a basic question, but I have tried to do this from the other post replies, but I'm obviously doing something wrong!

Regards Chris
User avatar
Tony Li
Posts: 22054
Joined: Thu Jul 18, 2013 1:27 pm

Re: Newb Alert! Help please.

Post by Tony Li »

Hi Chris,

Thanks for using the Dialogue System!

The Conversation Conditions Tutorial covers this. (That link includes a video version as well as text version.)

There's a bit of fluff at the beginning to set up the actors. Then it gets straight to defining a variable, writing a conversation, and using the variable in the conversation.

Please give the tutorial a try. If you have any questions, let me know.
scorpio66
Posts: 6
Joined: Tue Sep 08, 2020 8:58 am

Re: Newb Alert! Help please.

Post by scorpio66 »

Hi Tony.

Thanks for a great asset and response, it is appreciated.
Just the learning curve and all that... :D

I have already looked at the tuts, but the examples are booleans, which wont help if there are more than 2 options.
So, I guess I'm asking how to set a variable that has 3 or more possibilities.
In the dialogue manager where you add variables, I cannot see a variable type that would accomodate random numbers.
Again my apologies for asking such basic info.
I'm sure when I get all the basics understood, I can work my way around most other problems.

Regards Chris
User avatar
Tony Li
Posts: 22054
Joined: Thu Jul 18, 2013 1:27 pm

Re: Newb Alert! Help please.

Post by Tony Li »

Hi Chris,

You could of course use multiple Booleans, but you're probably looking for the Number type. If you have a question about how to accomplish what you want with the Number type, please let me know. If possible, describe a specific conversation, such as:

Code: Select all

[ring, ring] (Variable["TimesCalled"] = Variable["TimesCalled"] + 1)
   NPC: "Hello?"
       Player: "Is Mr. Smith there?" 
          NPC: "No, there's no Mr. Smith here. Goodbye." (Variable["TimesCalled"] < 3)
          NPC: "For the last time! There's no Mr. Smith! Stop calling!" (Variable["TimesCalled"] >= 3)
I realize the example above uses conditions on the NPC's lines, but the same idea applies for player lines.

Some other things to note:
Post Reply