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
Badmonster
Wanderer


Joined: 06 Feb 2010
Posts: 81

PostPosted: Sun Oct 10, 2010 2:42 pm   

Autolog event/trigger will not fire in new version
 
Since upgrading (I'm not sure whether it happened in this update or the one before, my last log is from 9/25 and I play daily) my client has not logged on connect. I entered the event again when I realized but ... nope. The client no longer logs on connect. I suppose I could set it up manually each time but I really liked not having to. Is there a fix? Is it possible to downgrade back to 3.26?
Reply with quote
Tech
GURU


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

PostPosted: Sun Oct 10, 2010 3:47 pm   
 
You should *not* downgrade BETA clients. Plus they have a fixed expiration time of 30 days. That said, post the code for the autolog event so what we can test it out.
_________________
Asati di tempari!
Reply with quote
Badmonster
Wanderer


Joined: 06 Feb 2010
Posts: 81

PostPosted: Sun Oct 10, 2010 4:13 pm   
 
Name: Logfile
Type: Auto Type
Value: C:\LogDirectory\Log 2010-09-25_16-32 cmud

And I don't know if this helps you, but I created the trigger by adding new event -on connect- Logfile = "C:\LogDirectory\Log "%time(yyyy-mm-dd_hh-nn)" cmud";#log @Logfile
Reply with quote
chamenas
Wizard


Joined: 26 Mar 2008
Posts: 1547

PostPosted: Mon Oct 11, 2010 1:12 am   
 
Mine is autologging just fine, so it's likely something script specific.

Try using %concat() instead of implicit concatation.

Logfile = %concat( "C:\LogDirectory\Log ", %time(yyyy-mm-dd_hh-nn), " cmud")
_________________
Listen to my Guitar - If you like it, listen to more
Reply with quote
Badmonster
Wanderer


Joined: 06 Feb 2010
Posts: 81

PostPosted: Mon Oct 11, 2010 3:33 am   
 
I'm not sure what a concotation is.
_________________
I play at www.armageddon.org. Murder Corruption Betrayal. We play hard.
Reply with quote
Tech
GURU


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

PostPosted: Mon Oct 11, 2010 7:24 am   
 
Concatenation. Instead of
Code:
Logfile = "C:\LogDirectory\Log "%time(yyyy-mm-dd_hh-nn)" cmud"

Try
Code:
Logfile = %concat( "C:\LogDirectory\Log ", %time(yyyy-mm-dd_hh-nn), " cmud")
_________________
Asati di tempari!
Reply with quote
chamenas
Wizard


Joined: 26 Mar 2008
Posts: 1547

PostPosted: Mon Oct 11, 2010 12:52 pm   
 
Sorry, yes, concatenation. It's basically putting things together. Implicit concatenation forces the program to assume you're trying to put things together without actually telling it to do that. This takes longer and so it has become less and less acceptable in the parser so that scripts can run more efficiently, thus we've been trying to move people into a direction of explicit concatenation, which tells the script parser that it definitely should be putting things together.
_________________
Listen to my Guitar - If you like it, listen to more
Reply with quote
Badmonster
Wanderer


Joined: 06 Feb 2010
Posts: 81

PostPosted: Mon Oct 11, 2010 10:58 pm   
 
Thanks. Going to try that out.
_________________
I play at www.armageddon.org. Murder Corruption Betrayal. We play hard.
Reply with quote
Badmonster
Wanderer


Joined: 06 Feb 2010
Posts: 81

PostPosted: Mon Oct 11, 2010 11:05 pm   
 
Thanks for the help. And thanks for explaining. I'm apologizing in advance if I'm giving too much information.

I went into the event.
I highlighted the value
I pasted Logfile = %concat( "C:\LogDirectory\Log ", %time(yyyy-mm-dd_hh-nn), " cmud")
The logging still does not begin on connect.
_________________
I play at www.armageddon.org. Murder Corruption Betrayal. We play hard.
Reply with quote
Tech
GURU


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

PostPosted: Tue Oct 12, 2010 3:05 am   
 
Can you post the code for you event? In CMUD, highlight the event by clicking on it, type Ctrl-C to copy and paste it into the forums in [code] tags. Also go to the compiled tab for the event to make sure it's compiling correctly.
_________________
Asati di tempari!
Reply with quote
Badmonster
Wanderer


Joined: 06 Feb 2010
Posts: 81

PostPosted: Tue Oct 12, 2010 11:36 am   
 
<?xml version="1.0" encoding="ISO-8859-1" ?>
<cmud>
<event event="onConnect" priority="60" copy="yes">
<value>Logfile = %concat("C:\LogDirectory\Log ", %time(yyyy-mm-dd_hh-nn), " cmud")</value>
</event>
</cmud>


I can't find the compiled tab. But the final bracket in the script text is highlighted in red.
_________________
I play at www.armageddon.org. Murder Corruption Betrayal. We play hard.
Reply with quote
hogarius
Adept


Joined: 29 Jan 2003
Posts: 221
Location: islands.genesismuds.org

PostPosted: Tue Oct 12, 2010 6:01 pm   
 
Badmonster, I see where you set the Logfile variable, but do you have a #LOG command to actually start logging?
Reply with quote
Tech
GURU


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

PostPosted: Tue Oct 12, 2010 7:56 pm   
 
One obvious thing to check on is to make sure the "LogDirectory" directory exists. CMUD will not a create a directory for you when attempting to create a log file.
_________________
Asati di tempari!
Reply with quote
MattLofton
GURU


Joined: 23 Dec 2000
Posts: 4834
Location: USA

PostPosted: Tue Oct 12, 2010 9:48 pm   
 
[quote]
I can't find the compiled tab
[quote]

The Compiled Code and Compiled Pattern tabs are considered Advanced tabs and are turned off by default. You can turn them on via the View menu in the Package Editor.
_________________
EDIT: I didn't like my old signature
Reply with quote
Badmonster
Wanderer


Joined: 06 Feb 2010
Posts: 81

PostPosted: Tue Oct 12, 2010 11:39 pm   
 
hogarius wrote:
Badmonster, I see where you set the Logfile variable, but do you have a #LOG command to actually start logging?

I'm not sure what you mean by this.
_________________
I play at www.armageddon.org. Murder Corruption Betrayal. We play hard.
Reply with quote
Badmonster
Wanderer


Joined: 06 Feb 2010
Posts: 81

PostPosted: Tue Oct 12, 2010 11:59 pm   
 
Tech wrote:
One obvious thing to check on is to make sure the "LogDirectory" directory exists. CMUD will not a create a directory for you when attempting to create a log file.

Yes, the directory does exist.
_________________
I play at www.armageddon.org. Murder Corruption Betrayal. We play hard.
Reply with quote
Badmonster
Wanderer


Joined: 06 Feb 2010
Posts: 81

PostPosted: Tue Oct 12, 2010 11:59 pm   
 
The complier says
Error compiling script:
illegal character in expression: (
_________________
I play at www.armageddon.org. Murder Corruption Betrayal. We play hard.
Reply with quote
Tech
GURU


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

PostPosted: Wed Oct 13, 2010 12:40 am   
 
If it's not compiling, then somewhere in your log script there's an error. When that happens, that script won't run. Go back to the script and type Ctrl-K. That should lead you to where the error is. Chances there are some unmatched braces somewhere. If you are calling a function, make sure there's no space between the function name and the open parenthesis "(".
_________________
Asati di tempari!
Reply with quote
hogarius
Adept


Joined: 29 Jan 2003
Posts: 221
Location: islands.genesismuds.org

PostPosted: Wed Oct 13, 2010 2:27 am   
 
Badmonster wrote:
hogarius wrote:
Badmonster, I see where you set the Logfile variable, but do you have a #LOG command to actually start logging?

I'm not sure what you mean by this.


The script for my onConnect event is as follows:

Code:
Logfile = "C:\MO\MO "%time(yyyy-mm-dd_hh-nn)" cmud";#log @Logfile;#reset


Note the #LOG command near the end. I set the Logfile variable, and then use the #LOG command to actually start logging.
Reply with quote
Badmonster
Wanderer


Joined: 06 Feb 2010
Posts: 81

PostPosted: Wed Oct 13, 2010 4:21 pm   
 
It doesn't like those parenthesis apparently.
_________________
I play at www.armageddon.org. Murder Corruption Betrayal. We play hard.
Reply with quote
Badmonster
Wanderer


Joined: 06 Feb 2010
Posts: 81

PostPosted: Wed Oct 13, 2010 4:25 pm   
 
At the risk of sounding like an idiot, maybe we could start from scratch with step by step directions?

And again, I very much appreciate all the help.
_________________
I play at www.armageddon.org. Murder Corruption Betrayal. We play hard.
Reply with quote
Badmonster
Wanderer


Joined: 06 Feb 2010
Posts: 81

PostPosted: Wed Oct 13, 2010 5:04 pm   
 
Ok, figured it out. Special characters issues
I'll try a new thread for asking ab out that.
_________________
I play at www.armageddon.org. Murder Corruption Betrayal. We play hard.
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