lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]

Okay, here's what I use:
tolua_pushuserdata(Script, WalkLayer);
lua_setglobal(Script, "WalkLayer");

It gives me this:
PANIC: unprotected error in call to Lua API (./Maps/ attempt to index global 'WalkLayer' (a nil value))

And I don't even know why this is... WalkLayer is initialized. :-/

Help? Thanks!

Wesley Smith wrote:
lua_pushuserdata(L, class);


On 8/16/07, L-28C <> wrote:
Hello everyone!

Okay, how would I push an element of a custom type (it's a class object)
into the Lua stack? Said custom type has been binded (erm, bound?) with

Hawlp? Thanks!