Skip to content

Instantly share code, notes, and snippets.

View kapodamy's full-sized avatar

kapodamy kapodamy

  • Argentina
View GitHub Profile
@SONIC3D
SONIC3D / Push_MultiDimArray.c
Created April 10, 2014 14:26
Return a multidimensional table from C function to lua
/*
Return an array in this structure
http://stackoverflow.com/questions/20173954/how-to-return-a-multidimensional-table-from-c-function-to-lua
In Lua array values usually starts at 1.
{
[1] = { ["field1"] = "1", ["field2"] = "2" , ["field3"] = "3" },
[2] = { ["field1"] = "10" , ["field2"] = "20", ["field3"] = "30" }
}
*/