Fix Model:getMesh()

(cherry picked from commit 37fdb39e73)
This commit is contained in:
Josip Miskovic 2024-02-19 23:49:18 +01:00 committed by bjorn
parent c17abe4f24
commit a84385a030
1 changed files with 1 additions and 1 deletions

View File

@ -334,7 +334,7 @@ static int l_lovrModelGetMeshCount(lua_State* L) {
static int l_lovrModelGetMesh(lua_State* L) {
Model* model = luax_checktype(L, 1, Model);
uint32_t index = luax_checku32(L, 3) - 1;
uint32_t index = luax_checku32(L, 2) - 1;
Mesh* mesh = lovrModelGetMesh(model, index);
luax_pushtype(L, Mesh, mesh);
return 1;