|
ShadowWind Newbie
Joined: 21 Feb 2007 Posts: 8
|
Posted: Wed Feb 21, 2007 10:30 am
Completely Confused |
Ok, I'm trying to figure out how to make string lists and I really don't get it. I have this line of text {You finish mixing up your * potion} and I want to make it so I can have a number of different responses. I was told I should make a string list of all the different responses, but I'm not sure it that will work since the responses are not just one word. An example of the responses would be {say done mixing potion} and {emote admires a perfect potion} So, how would I set it up so I could have the same line of text with these responses randomly selected one at a time?
|
|
|
|
Guinn Wizard
Joined: 03 Mar 2001 Posts: 1127 Location: London
|
Posted: Wed Feb 21, 2007 11:38 am |
A stringlist doesn't have to be single word items.
If there are no special characters then you can just create them as below.
myList = {say done mixing potion|emote admires a perfect potion|emote dances about, waving a potion bottle in the air|say Yup, that's done}
If there are then just put each string in quotes.
myList = {"say {done} mixing potion"|"emote (admires a) perfect potion"|"emote dances about, +-*waving a potion bottle in the air"|"say Yup, that's done"}
Then to pick a random one
#say %item(@myList,%random(1, %numitems(@myList))) |
|
_________________ CMUD Pro, Windows Vista x64
Core2 Q6600, 4GB RAM, GeForce 8800GT
Because you need it for text... ;) |
|
|
|
ShadowWind Newbie
Joined: 21 Feb 2007 Posts: 8
|
Posted: Thu Feb 22, 2007 7:38 am |
That worked perfectly, thank you!!!
|
|
|
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|