|
Dumas Enchanter
Joined: 11 Feb 2003 Posts: 511 Location: USA
|
Posted: Sat Mar 29, 2008 9:34 pm
[2.21] OnConnect event not completing on connection |
I use the OnConnect event to begin logging my session when I connect to a game. Since at least version 2.20 I was noticing that when I was logging out of the game it was asking me for a file to log to. I figured I had maybe disabled the event and thought nothing more of it. But this time I decided to dig in.
My OnConnect event was enabled the whole time, but for some reason it wasn't completing. And it only had an issue when connecting from the session screen. If I disconnected from the game and reconnected, the event fired and processed as it should. But from the sessions screen, I only get this:
Quote: |
0.6084 | a Achaea |Connected to host achaea.com
0.1511 | m Achaea | Event "onConnect" raised
0.0033 | a Achaea #Telnet 200:
0.0029 | a Achaea #Telnet 200: hello |
So the event is getting raised, but the #LOG command inside did not process. |
|
|
|
JQuilici Adept
Joined: 21 Sep 2005 Posts: 250 Location: Austin, TX
|
Posted: Sat Mar 29, 2008 10:14 pm |
This may be related to the context problem in this thread. If the context is wrong for the initial raising of onConnect, it may not be processing your handler at all.
|
|
_________________ Come visit Mozart Mud...and tell an imm that Aerith sent you! |
|
|
|
ReedN Wizard
Joined: 04 Jan 2006 Posts: 1279 Location: Portland, Oregon
|
Posted: Sat Mar 29, 2008 11:05 pm |
I have an onConnect event as well and I experienced this same issue in 2.21.
|
|
|
|
Fang Xianfu GURU
Joined: 26 Jan 2004 Posts: 5155 Location: United Kingdom
|
Posted: Sat Mar 29, 2008 11:29 pm |
What code are these events running?
|
|
|
|
Dumas Enchanter
Joined: 11 Feb 2003 Posts: 511 Location: USA
|
Posted: Sun Mar 30, 2008 12:29 am |
Mine is only running a #LOG command. That is it. Nothing else.
|
|
|
|
ReedN Wizard
Joined: 04 Jan 2006 Posts: 1279 Location: Portland, Oregon
|
Posted: Tue Apr 01, 2008 3:16 pm |
An additional observation. Perhaps it might have something to do with which window is in focus. I've noticed that when starting a session from the session selector it toggles focus between my main window (with the #onConnect event) and my Capture window which has no triggers (except for one to disable triggers) and no connection. The sequence of is on the main window has focus for a brief time, then the focus shifts to my capture window and never returns to my main window again. I have to click on my main window to give it focus.
|
|
|
|
Dumas Enchanter
Joined: 11 Feb 2003 Posts: 511 Location: USA
|
Posted: Sun Apr 06, 2008 9:59 am |
Not certain if this version history comment applies to this problem.
Quote: |
Fixed various context/scope issues with Event firing, especially with onLoad events |
If it was meant to, then I'm still having the same problem in 2.22. If it wasn't meant to mean this was fixed, ignore this post. |
|
|
|
Dumas Enchanter
Joined: 11 Feb 2003 Posts: 511 Location: USA
|
Posted: Sat May 03, 2008 10:07 pm |
This works now, per the version notes. Thanks!
|
|
|
|
|
|