lotrointerface.com
Search Downloads


Go Back   LoTROInterface > LotRO > Developer Discussions > Lua Programming Help (L)

Reply
Thread Tools Display Modes
  #1  
Unread 06-23-2011, 05:46 PM
sutt sutt is offline
The Wary
 
Join Date: Jun 2011
Posts: 3
Arrow Plugin unload itself...

Is it possible for a plugin to unload itself?

I'm working on my first pluing ever, and I want it to unload when I close the plugin window. I've tried the following:

Code:
Turbine.PluginManager.UnloadScriptState("Plugin_Name")
But it don't work.

Any suggestions?

Thanks!
Reply With Quote
  #2  
Unread 06-24-2011, 11:07 AM
MrJackdaw's Avatar
MrJackdaw MrJackdaw is offline
The Undying
Interface Author - Click to view interfaces
 
Join Date: Feb 2009
Location: Lancaster, England
Posts: 249
UnloadScriptState doesn't unload a plugin, it unloads that state. Bad explanation, but I am tired.

If in your .plugin you include the line <Configuration Apartment="Whatever" /> then Turbine.PluginManager.UnloadScriptState("Whatever" ) will unload all plugins in that apartment.
__________________
************************************************** ************************************************** **
"Our ideals may never be realised, But they indicate what we are trying to do." Dick Tahta
Reply With Quote
  #3  
Unread 06-24-2011, 12:42 PM
Equendil Equendil is offline
The Undying
Interface Author - Click to view interfaces
 
Join Date: Apr 2011
Posts: 52
In addition to what MrJackdaw wrote, a plugin cannot unload a 'script state' in which it resides.

You can have another plugin in a different 'Configuration Apartment' terminate the first, but then you cannot unload *that* plugin.

Unless you really really need to unload your plugin, as a workaround to bugs in the API, keep your plugin loaded.

Last edited by Equendil : 06-24-2011 at 12:50 PM.
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Save on Unload MrJackdaw Lua Programming Help (L) 1 12-16-2010 02:07 AM


All times are GMT -5. The time now is 09:00 PM.


Our Network
EQInterface | EQ2Interface | Minion | WoWInterface | ESOUI | LoTROInterface | MMOUI | Swtorui