summaryrefslogtreecommitdiff
path: root/src/mesh.c
diff options
context:
space:
mode:
authorsanine-a <sanine.not@pm.me>2020-12-03 02:10:32 -0600
committersanine-a <sanine.not@pm.me>2020-12-03 02:10:32 -0600
commite767e1ff9d81f8a76196caab91d9b6b4bbe0b30e (patch)
tree25a058779bcd4de00ce04ccf6cb0157cfba32611 /src/mesh.c
parentf417d2b047369cac234c471ef37ab8281181d69f (diff)
rewrite demo
Diffstat (limited to 'src/mesh.c')
-rw-r--r--src/mesh.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/mesh.c b/src/mesh.c
index b06fd68..e3b3a43 100644
--- a/src/mesh.c
+++ b/src/mesh.c
@@ -3,18 +3,18 @@
static int honey_mesh_lua_draw(lua_State* L)
{
honey_mesh* mesh;
- int shader;
- honey_lua_parse_arguments(L, 2,
+ int* shader;
+ honey_lua_parse_arguments(L, 1, 2,
HONEY_USERDATA, &mesh,
- HONEY_INTEGER, &shader);
- honey_mesh_draw(*mesh, shader);
+ HONEY_USERDATA, &shader);
+ honey_mesh_draw(*mesh, *shader);
return 0;
}
static int honey_mesh_lua_delete(lua_State* L)
{
honey_mesh* mesh;
- honey_lua_parse_arguments(L, 1, HONEY_USERDATA, &mesh);
+ honey_lua_parse_arguments(L, 1, 1, HONEY_USERDATA, &mesh);
honey_mesh_delete(*mesh);
return 0;
}
@@ -123,7 +123,7 @@ static void process_nodes_recursively(lua_State* L,
int honey_mesh_load(lua_State* L)
{
char* filename;
- honey_lua_parse_arguments(L, 1, HONEY_STRING, &filename);
+ honey_lua_parse_arguments(L, 1, 1, HONEY_STRING, &filename);
int n_meshes = 1;