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

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » zMUD General Discussion
DeReP
Adept


Joined: 14 Jun 2003
Posts: 222
Location: Chile

PostPosted: Sat May 07, 2005 7:10 pm   

Simple trigger not firing
 
Ok I'm kinda ashamed to post this but there is one simple trigger that will not fire on my machine, and was wondering if it would on someone elses.
It has to do with Channel capturing.
Sometimes some tells will come right next to the prompt line
Quote:
Ie: 100H 100M 100V 100XP > Player tells you, 'Something'

So I did this trigger to capture it on the special window.
Code:
#TRIGGER {~> %w tells you, '} {#CAP Comm}

What I find odd, is that this trigger wont fire at all sometimes, or any time.
I tryed testing it with #SAY and #SAYP and I seem to be helpless atm. Also, note that I use %w so I dont capture the tells from NPCs. Any thoughts on this?
I used trigger on trigger, prompt and newline with that trigger.
Reply with quote
MattLofton
GURU


Joined: 23 Dec 2000
Posts: 4834
Location: USA

PostPosted: Sat May 07, 2005 7:43 pm   
 
So...not even #SAY/etc shows up?

1)Did you change any of the trigger options?

2)Do you use #WAIT in any other triggers? Doing so will completely stop any trigger processing during the #WAIT duration, possibly preventing a trigger from firing as opposed to storing the results for later.

3)While the lack of any #SAY type of output tells us otherwise, perhaps #CAPTURE/ZMud is getting tripped up by the Ie: at the beginning of your prompt? #Capture sends the entire line, so it's possible something somewhere is seeing the line sent as the window-redirection shortcut of WindowName: and trying to send the output to a non-existent window.

4)do you use any other triggers kept in the same class folder as this one? Assuming one of them turns on/off the class, it's possible that it is simply turning off the class before the tells trigger gets a chance to be matched and processed.
_________________
EDIT: I didn't like my old signature
Reply with quote
DeReP
Adept


Joined: 14 Jun 2003
Posts: 222
Location: Chile

PostPosted: Sun May 08, 2005 3:37 am   
 
Ok thanks for the feedback, I do not use #WAIT but I do have another trigger that sends tells that come at the begginin of a line.
I have another trigger around that was like this
Code:
#TRIGGER {^%w tells you, '} {#CAP Comm}

Now as the other one isas I wrote earlier, I dont think they should be preventing one and another, its just odd that the " > %w tells you, ' " wont fire I know. did you Try it out.
About the #SAY part:
I used #SAY to check if the trigger would fire, it didnt.
So basically what I did was: #SAY something > Player tells you, 'hi'
and it didnt capture to the Comm window, but stayed in the main one.

I do have other triggers in that Class, all for Communications issues, this is the only one that isnt firing, and I think its couse I have to check if its a NPC or an Actual player thats sending the tells (done so I dont capture the tells from shopkeepers, etc)
The last version of the trigger was pretty simple:

Code:
#TRIG {tells you, '} {#CAP Comm}

That worked like a charm, but would capture anything that would sent me a tell, so I thought I would change it to "^%w and > %w " to make sure it was only 1 word sending the tell (most of the NPCs have multi word names). Thats when the problem began, I'll keep looking into this, see if I can find a solution Oo
Thanks for the feedback Matt
Reply with quote
a5hi5m
Beginner


Joined: 04 Mar 2004
Posts: 24
Location: Australia

PostPosted: Sun May 08, 2005 1:19 pm   
 
Do you always receive a tell at the end of your prompt, or can it be on a new line, or line aside from your prompt?
_________________
Smoking@BatMUD
Reply with quote
DeReP
Adept


Joined: 14 Jun 2003
Posts: 222
Location: Chile

PostPosted: Sun May 08, 2005 10:56 pm   
 
I can receive them in a new line, and right next to prompt on ocation
Its CircleMUD code btw.
the funny thing is, it works unless I put the ">" to trigger on
I think thats whats messing the trigger up.
If the trigger goes like this
#TRIGGER {tells you, '} {some command}
it fires
but if I use:
#TRIGGER {~> %w tells you, '} {some command}
it wont. I know its odd, I'm still looking into it, its not a life/death issue, but Its kinda annoying capturing tells from shopkeepers etc.
Reply with quote
Aarlot
Adept


Joined: 30 Dec 2003
Posts: 226

PostPosted: Sun May 08, 2005 11:03 pm   
 
hrmm... do your shopkeepers have more than one word in their name? (IE: Blah the silly shopkeeper tells you). That would make it not work, since you only have a %w there before "tells you,"
_________________
Everyone is entitled to their beliefs - until they die. Then only the truth matters.
Reply with quote
DeReP
Adept


Joined: 14 Jun 2003
Posts: 222
Location: Chile

PostPosted: Sun May 08, 2005 11:34 pm   
 
yeah thats the idea, not to capture shopkeeper tells
It doesnt capture them so far, but it doesnt capture incoming text like this either:

100H 100M 100V 100XP > Player tells you, 'hello'

Thats whats odd about it.
Reply with quote
Private
Adept


Joined: 10 Jan 2002
Posts: 264
Location: USA

PostPosted: Mon May 09, 2005 12:20 am   
 
instead of anchoring at the beginning with:
#TRIGGER {^%w tells you, '} {#CAP Comm}

have you considered anchoring at the end?

#TRIGGER {%w tells you, '%*'$} {#CAP Comm}

%* wont be an issue as you dont take any action on %2
Reply with quote
MattLofton
GURU


Joined: 23 Dec 2000
Posts: 4834
Location: USA

PostPosted: Mon May 09, 2005 12:35 am   
 
Private, he wasn't even using anchoring at all in the problem trigger. Also, if he anchors to the end of the line, then the trigger will start matching NPC tells and he doesn't want that.

If it's working when you remove the >, perhaps you forgot you changed the quote character from ~ to something else? If the zmud quote character has changed, then using ~ to quote characters will simply cause zmud to look for a ~ in the pattern and thus failing to match.
_________________
EDIT: I didn't like my old signature
Reply with quote
DeReP
Adept


Joined: 14 Jun 2003
Posts: 222
Location: Chile

PostPosted: Mon May 09, 2005 12:36 am   
 
yeah, thing is, It will capture the NPCs tells as well,
ie:
The Balduvian Shopkeeper tells you, 'We do not deal the imaginary'
Will capture
Shopkeeper tells you, 'We do not deal the imaginary'
Thing is I want to capture tells that are sent by 1 word character names, sort of speaking, to insure its a player, so $ doesnt really fit in right now.
Reply with quote
DeReP
Adept


Joined: 14 Jun 2003
Posts: 222
Location: Chile

PostPosted: Mon May 09, 2005 12:40 am   
 
Matt:
Yeah special characters are default. Have any of you guys tried this on your Zmud?
ie:
#TRIGGER {~> %w tells you, '} {#ECHO Works}

I keep trying to test it with

#SAY > Player tells you, 'Hi'

and it wont get captured...
Reply with quote
Aarlot
Adept


Joined: 30 Dec 2003
Posts: 226

PostPosted: Mon May 09, 2005 12:45 am   
 
Hrmm... that exact trigger and test worked for me...
_________________
Everyone is entitled to their beliefs - until they die. Then only the truth matters.
Reply with quote
DeReP
Adept


Joined: 14 Jun 2003
Posts: 222
Location: Chile

PostPosted: Mon May 09, 2005 12:47 am   
 
Ok I'll look into it here, It obviously has to be some other trigger messing stuff up, thanks for the time though.
Reply with quote
DeReP
Adept


Joined: 14 Jun 2003
Posts: 222
Location: Chile

PostPosted: Mon May 09, 2005 1:04 am   
 
Right, after a little search around, I found nothing interfiering with the trigger itself, so decided to delete the class folder, and redo them.
To my surprise, the trigger now does fire and works like a charm, I'm sorry for any inconveniences this caused, but it did have me on the edge of a nervous breakdown.
Thanks everyone.
Reply with quote
Private
Adept


Joined: 10 Jan 2002
Posts: 264
Location: USA

PostPosted: Mon May 09, 2005 9:10 am   
 
I played around with it and came up with a single trigger that seems to work for all instances:

#TRIGGER {{^~> }(*) tells you, '(%*)'$} {#IF (%numwords( %1) = 1) {:Chat: #SAY {%1 tells you, '%2'}}}

this worked for:

Captured:
#SAY Jimbob tells you, 'testing 1 2 3'
#SAY ~> Jimbob tells you, 'testing 1 2 3'

Not Captured:
#SAY Shopkeeper Jimbob tells you, 'testing 1 2 3'

The reason for the ":Chat: #say" instead of #CAP is on #SAY ~> Jimbob tells you, 'testing 1 2 3' the > is captured with #CAP

Little more then a simple trigger, i just dont like having 2 triggers when 1 works :)
Reply with quote
DeReP
Adept


Joined: 14 Jun 2003
Posts: 222
Location: Chile

PostPosted: Mon May 09, 2005 3:16 pm   
 
Hehehe, yeah I know the feeling, I actually had 1 trigger as well, with the %numwords function on it, pretty much the same as yours, just couldnt figure out a good way to put the > or ^ part, since the > comes after prompt, it cant be "^~>", I'm not sure if theres a way to put that in the pattern within brackets, ie: Having it trigger at the start of a line, or followed by a ">". I guess it would some something like "{^| > }" but i'm not sure that works either. About the #Say instead of capture, I use capture, then in the Comm window I strip away the prompt, wich includes the ">". Thanks for the feedback Private.
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » zMUD 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