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

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » CMUD Beta Forum
Palek
Wanderer


Joined: 28 Sep 2005
Posts: 55

PostPosted: Fri Aug 20, 2010 3:25 am   

[3.22a] Looping Trigger
 
I have the following type of triggers setup to capture comm line data to another window:

Code:
<trigger priority="1780" enabled="false" id="139">
  <pattern> *</pattern>
  <value>#GAG
#CAPTURE "Pilot"</value>
</trigger>


If the trigger is in the main package of my session it fires and captures fine, if it is in a seperate package it goes into a loop and must be disabled.

Any ideas would be appreciated.

Palek
Reply with quote
Tech
GURU


Joined: 18 Oct 2000
Posts: 2733
Location: Atlanta, USA

PostPosted: Fri Aug 20, 2010 5:13 am   
 
It sounds like there is a conflict for the scope of the package. Can you say what you package layout is?

For example:

MudWindow
-- Trigger
-- Trigger
-- Alias
-- Alias
Package (Local)
-- Alias
-- Trigger
Package (Global)
-- Alias
_________________
Asati di tempari!
Reply with quote
Palek
Wanderer


Joined: 28 Sep 2005
Posts: 55

PostPosted: Fri Aug 20, 2010 5:38 am   
 
Yeah, it is like this:

MudWindow (Main Package)
CommsPackage (Global)
--Trigger
--PilotWindow

When it is set like this the trigger gives a loop error, if I set it like this:

MudWindow (Main Package)
--Trigger
CommsPackage (Global)
--PilotWindow

It works fine, but I want to distribute this package to others without having to have them move the triggers into their main package.

Thanks
Reply with quote
Tech
GURU


Joined: 18 Oct 2000
Posts: 2733
Location: Atlanta, USA

PostPosted: Fri Aug 20, 2010 5:51 am   
 
That's why it's a problem. When it's in a global Package it is accessible in both Main Window and the Child Window so it will fire in both... since it's being put into the child window and will then again trigger from the child window you will get the infinite loop.

You're original set up is the best way. Alternatively you can put CommsPackage in a separate Package and not just a separate module and only enable that package for the main window. Read more on Packages for more information.
_________________
Asati di tempari!
Reply with quote
Palek
Wanderer


Joined: 28 Sep 2005
Posts: 55

PostPosted: Fri Aug 20, 2010 6:03 am   
 
I may not have explained this right. I have 2 packages here:

MainSession Package - This contains the main mud window.
Comms - This contains the Windows for all comm channels and is set to a global package with only the MainSession as enabled.

You stated:
Quote:

Alternatively you can put CommsPackage in a separate Package and not just a separate module and only enable that package for the main window.


This is already done, but if the trigger is in Comms it loops. If the trigger is in MainSession it does not.

Thanks.
Reply with quote
Tech
GURU


Joined: 18 Oct 2000
Posts: 2733
Location: Atlanta, USA

PostPosted: Fri Aug 20, 2010 2:39 pm   
 
What I would recommend is to keep all your windows in your main package and your CommTriggers in their current package. That way you can enable the CommPackage for only the main window.
_________________
Asati di tempari!
Reply with quote
Palek
Wanderer


Joined: 28 Sep 2005
Posts: 55

PostPosted: Fri Aug 20, 2010 3:01 pm   
 
Done and it corrected the problem, thanks very much for the help.

Palek
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » CMUD Beta Forum 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