Register to post in forums, or Log in to your existing account
 

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » CMUD General Discussion
mesla
Beginner


Joined: 21 Dec 2010
Posts: 11

PostPosted: Wed Mar 16, 2011 7:53 pm   

turning off " "
 
Hello everyone was going to ask if anyone knows how to turn off the "" for trigs. in the mud i play when i name something. as say
name axe as axe1 it looks like A axe named "axe1" but cant use "axe1" in trigs.
Reply with quote
Rahab
Wizard


Joined: 22 Mar 2007
Posts: 2320

PostPosted: Wed Mar 16, 2011 8:22 pm   
 
Are you asking how to trigger on literal on literal quotation marks? If so, you preceed it with Cmud's quote character (by default, this is "\" ). In other words, to fire on the literal string:
Quote:
A axe named "axe1"

you would use a trigger pattern of:
Quote:
A axe named \"axe1\"
Reply with quote
mesla
Beginner


Joined: 21 Dec 2010
Posts: 11

PostPosted: Wed Mar 16, 2011 8:43 pm   
 
say i have the axe named "axe1" and i want to put it to a bag i would put "axe1" to bag but it removes the "" form axe1 so it does not work if its a trig.
Reply with quote
Fizgar
Magician


Joined: 07 Feb 2002
Posts: 333
Location: Central Virginia

PostPosted: Wed Mar 16, 2011 9:16 pm   
 
Like Rahab said you need to quote the double quotes in the trigger pattern to get CMUD to match them. However ~ is really the default quote character in CMUD so unless you are using a regex pattern use that instead of the \ he suggested. The same goes for sending the quotes to the mud you will need to quote them.

An example trigger that sends put "axe1" bag

Code:
<?xml version="1.0" encoding="ISO-8859-1" ?>
<cmud>
  <trigger priority="20" copy="yes">
    <pattern>^An axe named ~"axe1~"</pattern>
    <value>#send put ~"axe1~" bag</value>
  </trigger>
</cmud>
_________________
Windows Vista Home Premium SP2 32-bit
AMD Athlon Dual Core 4400+ 2.31 GHz
3 GB RAM
CMUD 3.34
Reply with quote
mesla
Beginner


Joined: 21 Dec 2010
Posts: 11

PostPosted: Wed Mar 16, 2011 9:27 pm   
 
Ok thanks for the help that worked great. Very Happy
Reply with quote
Rahab
Wizard


Joined: 22 Mar 2007
Posts: 2320

PostPosted: Thu Mar 17, 2011 12:09 am   
 
Bleh, guess I'm tired today. Right, the quote character is ~. Sorry.
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » CMUD General Discussion All times are GMT
Page 1 of 1

 
Jump to:  
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

© 2009 Zugg Software. Hosted by Wolfpaw.net