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
Gunho
Newbie


Joined: 07 Jun 2008
Posts: 4

PostPosted: Sat Jun 07, 2008 5:14 am   

Trigger/Scripting help
 
I don't know if it is me, or if it is Cmud but I'm having a lot of issues with simple triggers. They appear to be firing, but nothing happens, CMUD does notify me when the trigger is recognized, but not fired.

couple examples trigger Character name
script #highlight Red

trigger You have recovered equilibrium
script #beep
I've used simple triggers like this from even crappy java clients with no issues, so is the scripting language different within Cmud? I've read the help files but from what I gather these should be correct. Any input for a new Cmuder?
Reply with quote
Anaristos
Sorcerer


Joined: 17 Jul 2007
Posts: 821
Location: California

PostPosted: Sat Jun 07, 2008 5:56 am   
 
It's hard to tell what you are doing since I assume you are you not actually showing us how you entered the triggers into your settings. When CMUD says that the trigger compiled but did not fire, it is telling you that there is an error in the trigger. So please, post either the xml for the trigger or the #TRIGGER command you used to create the setting. Meanwhile, go into the settings editor, select the trigger setting so that its script appears in the editor box, select check syntax from the Editor menu and you'll probably find the problem, or a way to solve your problem.
_________________
Sic itur ad astra.
Reply with quote
Arminas
Wizard


Joined: 11 Jul 2002
Posts: 1265
Location: USA

PostPosted: Sat Jun 07, 2008 2:34 pm   
 
For the first trigger I'm pretty sure that you want to use #CW MXPRed or #COLOR MXPRed instead of #highlight Red.

MXPRed is a brighter color red, If you like the dark-red then you can use it if you like.

#CW colors only what matched the trigger pattern instead of the whole line.
#COLOR colors the whole line containing the pattern.

#beep plays through your external speakers.
Not the internal speaker that gives you the beep codes if there is a hardware error. So if you don't have your speakers turned on/up you won't hear it.
_________________
Arminas, The Invisible horseman
Windows 7 Pro 32 bit
AMD 64 X2 2.51 Dual Core, 2 GB of Ram
Reply with quote
Gunho
Newbie


Joined: 07 Jun 2008
Posts: 4

PostPosted: Sat Jun 07, 2008 6:04 pm   
 
Anaristos: actually those are exactly how they were entered into the trigger GUI, with the exception of saying Character name here instead of saying the name of the actual character.
xml code
<trigger priority="120" id="12">
<pattern>Alisa</pattern>
<value>#Highlight Red</value>
</trigger>

I got the beep working alright. I just deleted the trigger and created a new one with the exact same syntax.

So I assume #highlight command isn't a valid command? a Syntax check yielded no errors.

Arminas

I've had the #Color command work to highlight a line, so I assume the #CW should work. I'll try it a bit later once I get back to my client and I'll let you know.
Reply with quote
Arminas
Wizard


Joined: 11 Jul 2002
Posts: 1265
Location: USA

PostPosted: Sat Jun 07, 2008 6:24 pm   
 
#highlight IS a valid command. It just doesn't do the same thing that you expected.
It is supposed to make the color of the line that is highlighted a little brighter.

I haven't checked it lately, it is possible that it isn't working properly.
Still, it isn't what you wanted in the first place. I'm pretty sure I have seen it used as the equivalent to #CW somewhere before,
Just not in ZMUD or CMUD.

Edit: I just had a look, #Highlight is indeed working correctly.
If you put something AFTER #Highlight then the command appears to do nothing.
Actually it is creating a trigger on the word, in this case red, to use the highlight command on any line containing the word.
_________________
Arminas, The Invisible horseman
Windows 7 Pro 32 bit
AMD 64 X2 2.51 Dual Core, 2 GB of Ram
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