Load/unload a plugin when you open/close a window?

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

Moderator: MacroQuest Developers

notadruid
a ghoul
a ghoul
Posts: 143
Joined: Mon Dec 08, 2003 6:02 pm

Load/unload a plugin when you open/close a window?

Post by notadruid » Sat Aug 28, 2004 1:16 pm

I'd like to make it so MQ2Map loads when I open the cartography window and unloads when I close it. Is this possible?

magictiger
a snow griffon
a snow griffon
Posts: 450
Joined: Sun Mar 21, 2004 2:24 pm

Post by magictiger » Sat Aug 28, 2004 3:07 pm

Using the custom binds and aliases, you should be able to do this no problem. Interesting idea, by the way.

User avatar
Fippy
a snow griffon
a snow griffon
Posts: 499
Joined: Tue Jul 16, 2002 10:42 am

Post by Fippy » Sat Aug 28, 2004 4:28 pm

What a cool idea.

/custombind add mapplugin
/custombind set mapplugin /docommand ${If[${Window[MapViewWnd].Open},/plugin mq2map,/plugin mq2map unload]}
/bind mapplugin Backspace

Works like a charm
Fippy

This is my girl. But Rizwank had her first :-)
[img]http://www.btinternet.com/~artanor/images/fairy_bounce09.gif[/img]