Author
Message Post new topic Reply to topic
Ragox
Developer
20 Jul 2013



I'm trying to get a creature say a random greeting from a pool of greetings that I've made for it.

I understand that it'll always pick the first greeting from the top that is valid and therefor it always says the same one.
How can I work around this to get it say a random one of a couple valid greetings?

I've never really worked with the dialogue system before so this is all overwhelming to me.
Does someone know how to do this? I'd really appreciate any help Smile
Post Sat Jan 16, 2016 11:05 pm Send private message             Reply with quote                   up  
Infragris
Developer
10 Mar 2013



You should use the Random100 function. In the Function/Variable fields on the right, first select Global, then Random100: this is a random number generator of some sort. Then, select < (or <=, doesn't matter) and assign each of your greetings a number: if you have five greetings you use something like 20, 40, 60, 80, last one unfiltered. This way, if the generator gives something smaller than 20, it selects the first answer, smaller than 40 is the second, etc. Last answer is unfiltered so that there is always a basic response. This should also work for creatures. If in doubt, check how generic greetings for a town like Khuul are organized.
Post Sun Jan 17, 2016 2:42 am Send private message             Reply with quote                   up  
Ragox
Developer
20 Jul 2013



Thanks a lot Infractis, I got it all working now Smile
Post Sun Jan 17, 2016 9:16 am Send private message             Reply with quote                   up  
Display posts from previous:   
Post new topic Reply to topic

 
The content of this site is © by the Tamriel Rebuilt community. Morrowind, its expansions, and its content is © Bethesda Softworks.
Forums powered by phpBB © 2001, 2005 phpBB Group