Embedding - Hmm..
No matter what layout im trying to do this with, I simply cant get it to work. The layout will throw a lua error (as if oUF wasn't there(which it isn't, I wanna embed it))
Any idea what I am doing wrong? I know it's not a hella' lotta' info, but I'm doing exactly as you are instructing me to |
Quote:
To me it just sounds like you aren't loading the oUF core files before the layout in your embed setup. That's really all the help I can give you based on the information you've posted. |
The guide is very helpfull, so if you followed the instructions, you should be fine...
I simply added Code:
## X-oUF: PSoUF Code:
local oUF = ns.oUF or oUF The folder PSoUF is a copy of the original oUF-folder, only renamed it, nothing changed in the sources (k, I have changed something in there, otherwise there would be no need to embed oUF, but it has nothing to do with the embedding itsself). |
Quote:
|
Releasing a layout with a nice feature is pointless, if the feature is not working due to a known bug in oUF... So I embedded it for the current release and will thankfully remove the embedded oUF once the bug is fixed.
|
Oh, sorry for assuming the worst. :o
|
Tried your tut and the one in the forums
All it gives is this
attempt to index global 'ns' (a nil value) |
Quote:
Code:
local ADDON_NAME, ns = ... |
I still cant get this to work, here my code in the top of the layout...
local للللللل, ns = ...
print("[Debug] UF's loaded") local oUF = ns.oUF or oUF assert(oUF, "<name> was unable to locate oUF install.") |
Quote:
How does your TOC look? How does the folder and file structure look? |
Ok, let's start from the beginning:
1.create the folder structure(should look like this) Code:
Word of Warcraft Code:
## Interface: 30300 3. Edit your layout.lua-file, so it will use the embedded oUF-version or looking for a globally visible one. Start your layout.lua with Code:
local ADDON_NAME, ns = ... -- get the addons namespace to exchange functions between core and layout The second line will look for oUF (it may be found in the addon's namespace, if it is embedded, or it may be globally visible, if you have a "normal" oUF-installation) and make it locally visible, so you will use the right one, when calling oUF:Spawn (for example). Now it should work with the embedded oUF-installation. |
Quote:
That way you can be sure that the error originated within your layout, rather than some other oUF layout/plugin that happens to use the same message. |
*hust* fixed...
|
Quote:
|
Quote:
Thank you very much for taking your time to do this :) However, it still doesn't work! :( - I made a new addons *just* with the UF's to be sure nothing else is interfering with it. Appereantly, theres a problem with loading oUF since it throws this: Message: Interface\AddOns\Test\layout.lua:3: Test was unable to locate oUF install. Time: Mon Jul 26 16:56:05 2010 Count: 1 Stack: [C]: in function `assert' Interface\AddOns\Test\layout.lua:3: in main chunk Locals: (*temporary) = nil (*temporary) = "Test was unable to locate oUF install." |
Quote:
|
Quote:
To your problem: I pretty much copied my current setup for you, so, if I didn't make any copy/paste-failures, it should work. Pls give us a) your .toc, b) your layout.lua (first lines should be sufficient) and c) describe your folder-structure. Another workaround to get you started: Go grab my layout, install it, and 1) edit oUF_PredatorSimple.toc (insert your name and so on, delete all listed files and keep just the reference to PSoUF/oUF.xml and then set a reference to your layout-file (layout.lua). Rename the file to "YOURADDON.toc" 2) delete the "media"-folder 3) delete "settings.lua", "lib.lua" and "core.lua" 4) KEEP the folder "PSoUF"! 5) Open up MY layout.lua, delete everything from line 14 to EOF (so keep the oUF-embedding-stuff) and paste your own layout-code. |
You wont believe this...
I found the reason myself and... be ready for a full-facedesk. I USED AN ANCIENT VERSION OF oUF! :mad: - Gawd...
That was the reason the lua errors arose -.-' Thanks for your help ^^ |
All times are GMT -6. The time now is 07:00 PM. |
vBulletin © 2024, Jelsoft Enterprises Ltd
© 2004 - 2022 MMOUI