[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Need help indexing C userdata
- From: Scott Morgan <blumf@...>
- Date: Wed, 12 Feb 2020 17:06:11 +0000
On 12/02/2020 16:23, Lee Shallis wrote:
> I doubt the problem is anywhere but where I create the data so I'll add
> that below
>
> int lua_proc_glance_grab( lua_State *L ) {
> proc_glance_t *glance =
> (proc_glance_t*)lua_newuserdata(L,sizeof(proc_glance_t));
> if ( glance ) return 1;
> luaL_setmetatable(L,PROC_GLANCE_CLASS);
> return 1;
> }
Follow the flow of that function, you're not calling luaL_setmetatable.
Scott