Thread Tools Display Modes
09-13-05, 04:50 PM   #1
guice
A Cobalt Mageweaver
Join Date: Jan 2005
Posts: 236
AddOn dymanic loading whoes :(

You can no longer manage your AddOns by simplely adding/removing their folder from the AddOn folder.

Found this out today as I was trying to trouble shoot a few things and WoW wouldn't even *SEE* the addons until I completely quit and restarted WoW (just logging out or going to login screen did not work).

This is a HUGE problem and a massive oversight if this is was intentional. How is one suppose to work on AddOns now? I very well refuse to restart my entire game just so I can load a single new AddOn cause now WoW cannot load AddOns like it once did.
  Reply With Quote
09-13-05, 05:17 PM   #2
Kasheen
A Wyrmkin Dreamwalker
 
Kasheen's Avatar
AddOn Author - Click to view addons
Join Date: Sep 2005
Posts: 58
Its intentional, while I was working on getting my mod compliant with 1.7 though I was able to just take the files inside the folder and dump them into the folder in the addons direction, reloadui and it was fine. . . .
  Reply With Quote
09-13-05, 08:55 PM   #3
njordin
A Defias Bandit
Join Date: Sep 2005
Posts: 2
Yeah, that does it for me...

Originally Posted by guice
This is a HUGE problem and a massive oversight if this is was intentional. How is one suppose to work on AddOns now? I very well refuse to restart my entire game just so I can load a single new AddOn cause now WoW cannot load AddOns like it once did.
There's little doubt that this was intentional. The betas didn't have it, and I refuse to believe Blizzard would allow a regression this huge to fall back into the release candidate if it wasn't in the betas. Which also begs the question if Blizz intentionally left it out of the beta versions to stem the tide of protests of us AddOn coders...

For me, this is a deal breaker. I've long stopped playing actively and more or less started to code for the public and my guild most of the time. Debugging an app isn't possible unless I have a chance to do so quickly, and I refuse to wait as long as I'd have to, simply to find out that I forgot to initialize some helper var.

There's more to this move, though. If this was intentional, it's one more proof of Blizzard's anti-UI-mod stance, and let's face it, most classes are almost unplayable without some creative modding to make things a bit more obvious (cooldown timers come to mind, or totem lists for Shaman).
  Reply With Quote
09-13-05, 10:00 PM   #4
Iriel
Super Moderator
WoWInterface Super Mod
Featured
Join Date: Jun 2005
Posts: 578
Come on people, stop being such dramatic whiners -- Why not read the existing forum sticky threads and understand the issue before complaining about it.

1.7 introduced a lot of dynamic addon support -- on-demand loading being the main one. This meant that WoW needed to hang onto the .toc information more, and (probably to avoid data import exploits) this information is scanned at client launch, and cached until client shutdown.

Beyond the .toc file, everything is loaded as needed, and re-loads as needed, as a developer you're not really affected, you just have to log out and in when you start off, and from that point on you can do what you've always done unless you have a big .toc change -- in which case yes, you do have to restart the client, and it's mildly annoying.

STOP THE INSANITY - THE SKY IS NOT FALLING
  Reply With Quote
09-13-05, 10:53 PM   #5
Cairenn
Credendo Vides
 
Cairenn's Avatar
Premium Member
WoWInterface Admin
Join Date: Mar 2004
Posts: 7,134
Easy sweetie, deep breath now.

*hugs Iriel*
__________________
“Do what you feel in your heart to be right — for you’ll be criticized anyway.” ~ Eleanor Roosevelt
~~~~~~~~~~~~~~~~~~~
Co-Founder & Admin: MMOUI
FaceBook Profile, Page, Group
Avatar Image by RaffaeleMarinetti
  Reply With Quote
09-13-05, 10:55 PM   #6
guice
A Cobalt Mageweaver
Join Date: Jan 2005
Posts: 236
No whining (much) here. I wouldn't go and say it's a deal breaker, you can still use /console reloadui to reload your currently loaded files with no problem.

The problem I have is that you can no longer Add an AddOn while in game, which *seriously* blows. That's something they seriously need to fix.
  Reply With Quote
09-13-05, 11:05 PM   #7
guice
A Cobalt Mageweaver
Join Date: Jan 2005
Posts: 236
Oh yeah, let me add I've tried UIParentLoadAddOn("NameOfFOlder") with error saying AddOn missing.

They also don't appear to have an UnLoadAddOn function, which would also be quite bad...They add 'LoadAddOn' but don't add an 'UnLoadAddOn'. /boggle UI's full of oversights.
  Reply With Quote
09-14-05, 12:53 AM   #8
Iriel
Super Moderator
WoWInterface Super Mod
Featured
Join Date: Jun 2005
Posts: 578
Originally Posted by guice
No whining (much) here. I wouldn't go and say it's a deal breaker, you can still use /console reloadui to reload your currently loaded files with no problem.

The problem I have is that you can no longer Add an AddOn while in game, which *seriously* blows. That's something they seriously need to fix.
You can, but it needs to have been installed BEFORE you start the game..

Install addon - but leave it disabled.

When in game, use the API to enable then load it (NOTE: Not all addons will work if you do this, depending on what assumptions they make/resources they use).. Or you can use the API to enable the addon then just do a /script ReloadUI().
  Reply With Quote
09-14-05, 12:55 AM   #9
Iriel
Super Moderator
WoWInterface Super Mod
Featured
Join Date: Jun 2005
Posts: 578
Originally Posted by guice
They also don't appear to have an UnLoadAddOn function, which would also be quite bad...They add 'LoadAddOn' but don't add an 'UnLoadAddOn'. /boggle UI's full of oversights.
Unloading an addon is logically infeasible given the environment in which addons are developed - you cannot necessarily undo whatever an addon has done. It's not that they 'forgot', it's that it's not possible.

You CAN however Disable an addon using the API then /script ReloadUI() to get rid of it.
  Reply With Quote
09-14-05, 01:20 AM   #10
Gello
A Molten Giant
AddOn Author - Click to view addons
Join Date: Jan 2005
Posts: 521
I think for many the real frustration is you can't try different addons easily anymore. Quitting the game is not worth the hassle when a guildmate says 'try this one.' You have to remember it before logging back in the next day. The little addons aren't going to be tried. They'll be scribbled on post-it notes and forgotten.

It's not a really bad thing. It is inconvenient now to try different addons, to the point that if the on-demand addons necessitated this change, it may be worth taking the on-demand loading out and perhaps implementing it later when it can be launched with an in-game addon manager or something to make on-demand useful to the users.

But if we imagine it had been like this since release, there wouldn't be too much grumbling about it. So it's no crisis, just a major inconvience to those who like to try different addons while they're in game.
  Reply With Quote
09-14-05, 08:39 AM   #11
guice
A Cobalt Mageweaver
Join Date: Jan 2005
Posts: 236
Unloading an addon is logically infeasible given the environment in which addons are developed - you cannot necessarily undo whatever an addon has done. It's not that they 'forgot', it's that it's not possible.
It's very technicaloggically possible. Being a programmer, I know this quite well. To load an AddOn dynamically, it was just a matter of calling the load script of the AddOn in question.

When that's called an object is created with everything for that AddOn. To unload the AddOn, set that object variable to null. Tada!

Although, depending on how they did the code, it might be slightly more difficult; however, this change of the Dynamic loading of AddOns should have opened the possability to unload them, too.

You CAN however Disable an addon using the API then /script ReloadUI() to get rid of it.
Which API? The AddOn screen still requires you to log out. I've tried everything I knew to "unload" and AddOn only to get LUA errors. The only way I was able to Unload them on the fly is by deleting their folder and running /console reloadui.


So it's no crisis, just a major inconvience to those who like to try different addons while they're in game.
And that's my biggest grip about this. However, I will disagree with you that we wouldn't be complaining if this had be this way since release. AddOns have became a critical piece of the game and having to stop and restart the game everytime you want to load in a new AddOn would make things too convoluted. AddOn authors *would* have complained since beta if this were the requirement. However, it was just a simple ` and 'reloadui' to reload the UI in beta, /console reloadui or /script ReloadUI() on release.

Last edited by guice : 09-14-05 at 08:42 AM.
  Reply With Quote
09-14-05, 10:47 AM   #12
Gello
A Molten Giant
AddOn Author - Click to view addons
Join Date: Jan 2005
Posts: 521
Addons can't be dynamically removed (without a reload) because they can alter the UI and UI doesn't keep track of its default state. Their payload was done and the game wouldn't know how to rollback the change.

If a mod changes the position of a window, the UI doesn't keep track of the "default" position. It moves the window and moves on.

Letting things be and unloading anyway can't be done due to function hooks which are extremely common in mods. A mod can hook a UI function to insert its own code. And other functions can hook and hook until you get a long chain that eventually reaches the original code. (Tooltip and chat messages are common hooks)

The UI wouldn't know how to restore those hooks. It could keep a list of all functions and restore them to original on demand to jettison the addons, but it couldn't do it for specific ones.

It's unlikely we'll see an on-demand unload unless both the UI and mods support an "unload" sequence, and that would require getting function handles "upstream" to close function hook chains. Which may be doable but a mod would need to be coded explicitly to clean up after itself.
  Reply With Quote
09-15-05, 03:29 AM   #13
farang
A Deviate Faerie Dragon
 
farang's Avatar
AddOn Author - Click to view addons
Join Date: Aug 2005
Posts: 19
Now i understand why my last edit yesterday night didn't worked

I've added first an entry to the .toc file ,believing that it's now possible to acutally add the .lua additional files directly into the .toc file. Seemed not to work (need to try that with complete restart tonight).

Strangely the old method, to include a <Script> element into the main XML file didn't work also. Possible those are "cached" as well ,so any change there needs a full restart as well...

However it's surely okay, to have those anoying effects, in addition to the new dynamic loading possibilities.

Especially for Addons that use alot of Memory, but are not always used.
  Reply With Quote
09-15-05, 03:31 AM   #14
farang
A Deviate Faerie Dragon
 
farang's Avatar
AddOn Author - Click to view addons
Join Date: Aug 2005
Posts: 19
about the /console reloadui to add new Addons "on the fly": i didn't know about that possibility until recently (and most users still don't know that).

When i tested/installed new Addons i did always do that before i loaded WoW.

That wasn't such a big problem at all.
  Reply With Quote
09-15-05, 08:32 AM   #15
guice
A Cobalt Mageweaver
Join Date: Jan 2005
Posts: 236
Originally Posted by farang
about the /console reloadui to add new Addons "on the fly": i didn't know about that possibility until recently (and most users still don't know that).

When i tested/installed new Addons i did always do that before i loaded WoW.

That wasn't such a big problem at all.
Back from the days of beta when ` was turned on by default to pop open a console window which allowed you to do all sorts of things with WoW. /console is now the slash command to what ` does. I figured most authors used /script ReloadUI() these days, which is the same thing.

It's just an annoyance to have to restart WoW now just to install a quick "lets check this out" AddOn.

To be honest, this is gonna hurt all your little AddOn writers. People will be using small addons less and less now cause they can't just pop it into a folder and reload. And some people just don't want to shut completely down just to install a small addon....
  Reply With Quote
09-15-05, 08:37 AM   #16
farang
A Deviate Faerie Dragon
 
farang's Avatar
AddOn Author - Click to view addons
Join Date: Aug 2005
Posts: 19
so let's make the addons bigger

i'm working on it *g*
  Reply With Quote
09-15-05, 08:53 AM   #17
guice
A Cobalt Mageweaver
Join Date: Jan 2005
Posts: 236
Originally Posted by farang
so let's make the addons bigger

i'm working on it *g*
bah, you know what I mean! It discourages new addon writers as it will be more convoluted for people to play around with their small AddOns. Not everybody can jump on the tredmill at full speed.
  Reply With Quote
09-15-05, 03:34 PM   #18
farang
A Deviate Faerie Dragon
 
farang's Avatar
AddOn Author - Click to view addons
Join Date: Aug 2005
Posts: 19
I understand.

For developing there is no big deal ,i just tested it tonight.

I added a couple of empty lua files and xml files to the toc, than i could perfectly work with them (if you add new ones a reload ui won't be enough).

I think it's acceptable like that (it was better before).
  Reply With Quote
09-24-05, 06:43 AM   #19
Gello
A Molten Giant
AddOn Author - Click to view addons
Join Date: Jan 2005
Posts: 521
I take back my indifference to the new method. I often write very small mods to post on forums when someone asks for a mod that's too big to make a macro and too small to merit posting on a site. It's a hassle to do them now :(

It's not the end of the world and my opinion counts for 1/3millionth, but load-on-demand certainly doesn't justify this inconvenience.
  Reply With Quote
09-24-05, 08:52 AM   #20
Beladona
A Molten Giant
 
Beladona's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2005
Posts: 539
if anything I see this as a more secure method. You just have to have more planning before you start developing. Make your addon directory, your TOC, and some starting scripts (maybe design a template that you can use on all mods when first starting) and go from there.

I know everyone does it differently, but this problem has not really affected me, as I have always started development before ever launching the game, that way I can actually test something when I first get in. If you load the game, THEN start scripting, it has to know something new is there. People that do it that way are going to have problems, but I see it as a "seat of the pants" approach versus careful pre-planning.

This WILL help reduce the possibility for after client-launch exploits and issues to take place. Beyond that, the benefits for dynamic loading of addons and other features that are are working so hard to get in, are MUCH more worthwhile than this annoyance that simply requires you to change your coding habits...

Last edited by Beladona : 09-24-05 at 08:56 AM.
  Reply With Quote

WoWInterface » Developer Discussions » General Authoring Discussion » AddOn dymanic loading whoes :(


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