how about more than 14 wildcards for a trigger

Posted by Faolong on Tue 22 Oct 2002 05:20 PM — 4 posts, 22,023 views.

USA #0
this is kinda weird to ask because who would be expecting a mud to have like 16 wildcards!!!! so i was just asking if it was possible to have like 16 or more wildcards for a trigger... and the wildcards array should work right because after the 9th (wildcards[8]), wildcards[9] will just give the trigger line match.... and anything after wildcards[9] is just undefined....
Canada #1
This situation is so rare, I think it's best that you just use the current workaround the few times you need to.

There was another thread on this, some time ago. I'm sorry, I don't recall the subject line or anything.

Currently, you can build multiple triggers. Each trigger will use regular expressions. Use ?: to indicate which expressions should be matched, but NOT returned as a wildcard. IE: You may match on the first 9, then use ?: on the rest. In your second trigger, you would use ?: on the first 9 elements, and then match normally on the rest.

Read "RegularExpressions.txt" in your MUSHclient directory for detailed instructions.
Australia Forum Administrator #2
This post is pretty relevant: Doing your own regular expression matching.

It describes how you can take a trigger match and re-match inside it to pull out more than 10 wildcards. Using the method Magnum describes you can set up a regular expression with more than 10 wildcards (not all will be returned) and then re-match using the technique described above to get the values for all of them.

#3
Also check out this entry:

http://www.gammon.com.au/forum/bbshowpost.php?bbsubject_id=1766#7429

It is a self-contained function to pull out a regexp and return the data to an array.