Using LOVEframes, having some trouble

Questions about the LÖVE API, installing LÖVE and other support related questions go here.
Forum rules
Before you make a thread asking for help, read this.
Post Reply
CheesyNacho
Prole
Posts: 1
Joined: Wed May 01, 2013 8:09 pm
Location: Connecticut, USA

Using LOVEframes, having some trouble

Post by CheesyNacho »

So I'm using the loveframes library to make the GUI for my game. I created a frame and tabs, but when I run the game, I get this error:

Code: Select all

/lib/loveframes/object/frame.lua:203: attempt to index local 'skin' (a nil value)
The code that's at that line in frame.lua is:

Code: Select all

	local children = self.children
	local internals = self.internals
	local skins = loveframes.skins.available
	local skinindex = loveframes.config["ACTIVESKIN"]
	local defaultskin = loveframes.config["DEFAULTSKIN"]
	local selfskin = self.skin
	local skin = skins[selfskin] or skins[skinindex]
	local drawfunc = skin.DrawFrame or skins[defaultskin].DrawFrame <-- line 203
	local draw = self.Draw
	local drawcount = loveframes.drawcount
I called this function with this code:

Code: Select all

function managementTabs()
	local frame = loveframes.Create("frame")
	frame:SetName("Tabs")
	frame:SetSize(1280, 100)
	frame:Center()

	local tabs = loveframes.Create("tabs", frame)
	tabs:SetPos(0, 0)
	tabs:SetSize(1280, 100)

	for i=1, 5 do
		local text1 = loveframes.Create("text")
		text1:SetText("Tab " ..i)
		tabs:AddTab("Tab " ..i, text1, "Tab " ..i)
end
then called that in love.load(). What is going on here? I'm fairly new to Lua, I'm mostly a C# and Javascript programmer, so maybe I'm missing something obvious. I've been hunting around on google and stackoverflow and in the docs all day and I can't figure out what's wrong.
User avatar
Nikolai Resokav
Party member
Posts: 140
Joined: Wed Apr 28, 2010 12:51 am
Location: United States

Re: Using LOVEframes, having some trouble

Post by Nikolai Resokav »

Can you provide a .love of your project?
User avatar
adnzzzzZ
Party member
Posts: 305
Joined: Sun Dec 26, 2010 11:04 pm
Location: Porto Alegre, Brazil

Re: Using LOVEframes, having some trouble

Post by adnzzzzZ »

Did you set it up properly?
Post Reply

Who is online

Users browsing this forum: Google [Bot] and 201 guests