[lua] Fix Color.index to return an integer instead of a number (fix #3159)

This commit is contained in:
David Capello 2022-02-04 13:44:13 -03:00
parent 8d4941d86c
commit 9cf2ff782f

View File

@ -295,7 +295,7 @@ int Color_get_gray(lua_State* L)
int Color_get_index(lua_State* L)
{
auto color = get_obj<app::Color>(L, 1);
lua_pushnumber(L, color->getIndex());
lua_pushinteger(L, color->getIndex());
return 1;
}