World Events in Plugins

Posted by Winter on Mon 24 Nov 2003 07:55 PM — 4 posts, 19,373 views.

#0
Hey Folks;

I'm currently building a complex plugin for my MUD, maily for the purpose of a statusline. I could simply use 'SetStatus', but there are problems at some users with the width of that line. So I decided to use the InfoBar. The Problem is, that it does not change between different worlds. Now i tried to solve this problem using OnWorld(Get|Lose)Focus. Goes well. But I don't see a possibility to built this within a plugin, cause the Events of a world can't be save in.
What do you suggest?
Australia Forum Administrator #1
Version 3.44 of MUSHclient now supports plugin callbacks: OnPluginGetFocus and OnPluginLoseFocus.
USA #2
Could someone show me an example of how to use OnPluginGetFocus and OnPluginLoseFocus? I haven't been able to get it to work and there is no example in the help files.
Australia Forum Administrator #3
Well, you would put something like this in your plugin script:


sub OnPluginGetFocus 

' do something here

end sub

sub OnPluginLoseFocus

' do something here

end sub