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
qdly
Beginner


Joined: 26 Jun 2009
Posts: 13

PostPosted: Fri Nov 26, 2010 11:43 am   

disabling special characters from script (2.37)
 
hi again,

i'm looking for some way to disable/edit special characters via alias/trigger (menu bar -> options -> general -> scripting -> special characters). so i could start parsing text starting with #, ~. is it possible? semi example:

Code:
<trigger priority="10600" id="1060">
  <pattern>qwe</pattern>
  <value>disable_special_characters_or_set_command_char_from_#_to_@</value>
</trigger>


Code:
<trigger priority="10601" id="1061">
  <pattern>asd</pattern>
  <value>enable_special_characters_or_set_command_char_from_@_to_#</value>
</trigger>


i need it for sth like:

Code:
<trigger type="Command Input" priority="10590" id="1059">
  <pattern>~#{#;%d}</pattern>
  <value>#echo works</value>
</trigger>



thanks
Reply with quote
Fizgar
Magician


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

PostPosted: Fri Nov 26, 2010 6:01 pm   
 
Not sure if this will work in 2.37 or not. To enable or disable a special character you can use %pref() combined with one of the 11 id's below and either 0 for disabled or 1 for enabled.
ComCharEn
SepCharEn
VarCharEn
ParamCharEn
FocusCharEn
ClassCharEn
MoveCharEn
HistCharEn
QuoteCharEn
MapDirCharEn
DBCharEn

Code:
%pref(HistCharEN,0)
would disable the history character
%pref(HistCharEN,1)
would enable the history character


*edit*
Hit submit instead of preview. :(

Also the #default and #nodef commands can be used to change the characters.
_________________
Windows Vista Home Premium SP2 32-bit
AMD Athlon Dual Core 4400+ 2.31 GHz
3 GB RAM
CMUD 3.34
Reply with quote
qdly
Beginner


Joined: 26 Jun 2009
Posts: 13

PostPosted: Sat Nov 27, 2010 1:34 pm   
 
works like a charm, thanks a lot XD
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