View Single Post
06-19-10, 07:51 PM   #204
Dokee
A Deviate Faerie Dragon
AddOn Author - Click to view addons
Join Date: Jun 2010
Posts: 19
Just found about this awesome looking addon, so I went and tried the first tutorial but end up with errors or nothing at all no matter what I do.

This is how my script currently looks like:
Code:
lpanels:CreateLayout("TestCake", { name = "BlackBar",
anchor_to = "BOTTOM",
y_off = 20,
width = "100%",
height = 50,
bg_color = "0 0 0",
bg_alpha = 0,5,
}, { bottom = 20, top = 20 } -- Optional viewport config
)

lpanels:ApplyLayout("n:khantos r:darksorrow", "TestCake", "AnotherLayout")
The error I get looks like this:
Code:
Message: Interface\AddOns\LitePanels\core.lua:328: attempt to index local 'f' (a number value)
Time: 06/20/10 03:35:36
Count: 1
Stack: Interface\AddOns\LitePanels\core.lua:328: in function `Init'
Interface\AddOns\LitePanels\core.lua:364: in function <Interface\AddOns\LitePanels\core.lua:354>

Locals: self = <table> {
 Exit = <function> defined @Interface\AddOns\LitePanels\core.lua:348
 defaults = <table> {
 }
 media = "Interface\AddOns\LitePanels\media\"
 ApplyLayout = <function> defined @Interface\AddOns\LitePanels\core.lua:86
 CreateFrame = <function> defined @Interface\AddOns\LitePanels\core.lua:373
 MakePanel = <function> defined @Interface\AddOns\LitePanels\core.lua:122
 Init = <function> defined @Interface\AddOns\LitePanels\core.lua:323
 RegisterEvent = <function> defined @Interface\AddOns\LitePanels\core.lua:106
 OnEvent = <function> defined @Interface\AddOns\LitePanels\core.lua:354
 profile = <table> {
 }
 MatchProf = <function> defined @Interface\AddOns\LitePanels\core.lua:77
 events = <table> {
 }
 cinfo = <table> {
 }
 defaultv = <table> {
 }
 temp = <table> {
 }
 sides = <table> {
 }
 CreateLayout = <function> defined @Interface\AddOns\LitePanels\core.lua:61
}
(for generator) = <function> defined =[C]:-1
(for state) = <table> {
 1 = 5
 2 = <table> {
 }
 3 = <table> {
 }
 4 = <table> {
 }
 5 = <table> {
 }
 6 = <table> {
 }
 7 = <table> {
 }
 8 = <table> {
 }
 9 = <table> {
 }
 10 = <table> {
 }
 11 = <table> {
 }
 12 = <table> {
 }
 13 = <table> {
 }
 14 = <table> {
 }
 15 = <table> {
 }
 16 = <table> {
 }
 17 = <table> {
 }
 18 = <table> {
 }
 19 = <table> {
 }
 20 = <table> {
 }
 vp = <table> {
 }
 Chat Background = <table> {
 }
 Simple Viewport = <table> {
 }
}
(for control) = 1
i = 1
f = 5
(for generator) = <function> defined =[C]:-1
(for state) = <table> {
 1 = 5
 2 = <table> {
 }
 3 = <table> {
 }
 4 = <table> {
 }
 5 = <table> {
 }
 6 = <table> {
 }
 7 = <table> {
 }
 8 = <table> {
 }
 9 = <table> {
 }
 10 = <table> {
 }
 11 = <table> {
 }
 12 = <table> {
 }
 13 = <table> {
 }
 14 = <table> {
 }
 15 = <table> {
 }
 16 = <table> {
 }
 17 = <table> {
 }
 18 = <table> {
 }
 19 = <table> {
 }
 20 = <table> {
 }
 vp = <table> {
 }
 Chat Background = <table> {
 }
 Simple Viewport = <table> {
 }
}
(for control) = 1
_ = 1
p = 5
(*temporary) = 0
(*temporary) = 1
(*temporary) = "attempt to index local 'f' (a number value)"
ipairs = <function> defined =[C]:-1
is = <function> defined @Interface\AddOns\LitePanels\core.lua:44
Any idea what I'm doing wrong? Tried the AFK and Stat script you posted too, and they worked completely fine. The viewport config works as well but only without the black bar layout. As a newbie to scripting this seriously confuses me >.<
  Reply With Quote