Window Hook

Need help running MacroQuest2? Ask your questions about how to get things to work on your computer.

Moderator: MacroQuest Developers

Skye
a lesser mummy
a lesser mummy
Posts: 33
Joined: Thu Jan 08, 2004 10:17 pm

Window Hook

Post by Skye » Tue May 04, 2004 11:56 pm

Looking for a piece of information on the startup sequence of events/hooks.

BACKGROUND
I spiraled into debugging a previously working script today - going out of my mind - a very simple macro was breaking: ${Window[blahblah]} was always returning NULL.

OBSERVATION
After some black-box debugging (I was just looking for the "Adding WndNotification target '%s'" message being sent to my log file), it seems to me that the MQ2Windows.cpp:SetScreenHook.SetScreen_Detour is only called if MQ2 is started before EQ. Voila, the macro would respond again once I started them in the right sequence.

Is this true?

User avatar
dont_know_at_all
Developer
Developer
Posts: 5450
Joined: Sun Dec 01, 2002 4:15 am
Location: Florida, USA
Contact:

Post by dont_know_at_all » Wed May 05, 2004 12:07 am

No. MQ2 hooks the functions but they are not called from EQ if UI is already initialized. /loadskin or restart will fix your problems.

Skye
a lesser mummy
a lesser mummy
Posts: 33
Joined: Thu Jan 08, 2004 10:17 pm

Post by Skye » Wed May 05, 2004 12:57 am

Thank you for the quick response, DKAA. I could tell that the hooks were being called only at initialization ... since I have never used different skins, using /loadskin never occurred to me! I do appreciate the pointer.

Lax
We're not worthy!
We're not worthy!
Posts: 3524
Joined: Thu Oct 17, 2002 1:01 pm
Location: ISBoxer
Contact:

Post by Lax » Wed May 05, 2004 1:22 am

yes what is happening is, MQ2 hooks the initialization of the windows. If it doesnt catch the initializations, it doesnt know what windows are open. Currently we dont have a way around that, but one might pop up soon.
Lax Lacks
Master of MQ2 Disaster
Purveyor of premium, EULA-safe MMORPG Multiboxing Software
* Multiboxing with ISBoxer: Quick Start Video
* EQPlayNice, WinEQ 2.0