|
alaric Novice
Joined: 13 Aug 2005 Posts: 32 Location: Cherry Point, NC
|
Posted: Sun Oct 09, 2005 3:18 pm
trigger pattern w/changing words |
Is there any way to have a trigger capture something when it can change words? For instance....if I wanted to capture a word into a database when identifying an object, but the word could change with each item. I tried using the {var1|var2} thing. But I am not sure if I did it right...
Any ideas? |
|
|
|
MattLofton GURU
Joined: 23 Dec 2000 Posts: 4834 Location: USA
|
Posted: Sun Oct 09, 2005 4:23 pm |
Sounds like you want *, or [%w%s] if there's more than one.
|
|
_________________ EDIT: I didn't like my old signature |
|
|
|
alaric Novice
Joined: 13 Aug 2005 Posts: 32 Location: Cherry Point, NC
|
Posted: Sun Oct 09, 2005 4:38 pm |
no, thats not going to work....I should have mentioned it or explained better....there is a lot more in the identify info that comes up...I want it to catch the right thing, if I just used (*) it would catch the first word that pop'd up....I can make a list of words for it to catch...thats not a problem, I just don't know how to make it catch it and throw it into a variable and all...I have never had much luck with the {var1|var2} thing...
|
|
|
|
Insomniac Wanderer
Joined: 25 Mar 2004 Posts: 78 Location: United Kingdom
|
Posted: Sun Oct 09, 2005 5:50 pm |
You'd just want to surround it with () to capture the variable, something like:
#TRIGGER {^You have a broken ({arm|hand|leg|foot})} {#VAR VarName %1}
Then all your DB stuff too. |
|
_________________
No-one ever gets flamed for posting too much information. Conform to the PPP (Preferred Posting Protocol) and give as much information as possible, including MUD output where needed. |
|
|
|
Vijilante SubAdmin
Joined: 18 Nov 2001 Posts: 5182
|
Posted: Mon Oct 10, 2005 1:57 am |
There is no substitute for actual MUD output. If you search these forums for appropiate words I am sure you will find numerous examples that are very close to your MUD's output. Failing that, you should post actual outputs of a number of varieties and then we may be able to offer better then vague suggestions.
|
|
_________________ The only good questions are the ones we have never answered before.
Search the Forums |
|
|
|
|
|