mirror of
https://github.com/love2d/love.git
synced 2026-08-12 08:30:56 +02:00
Improve the error message when a type other than a table is given as the 3rd arg to newCanvas.
--HG-- branch : minor
This commit is contained in:
@@ -1144,6 +1144,8 @@ int w_newCanvas(lua_State *L)
|
||||
|
||||
if (!lua_isnoneornil(L, startidx))
|
||||
{
|
||||
luaL_checktype(L, startidx, LUA_TTABLE);
|
||||
|
||||
settings.pixeldensity = (float) luax_numberflag(L, startidx, "pixeldensity", settings.pixeldensity);
|
||||
settings.msaa = luax_intflag(L, startidx, "msaa", settings.msaa);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user