mirror of
https://github.com/The-Powder-Toy/The-Powder-Toy.git
synced 2025-08-10 02:16:37 +02:00
fix lua windows to allow -1 for position again (centers the window)
This commit is contained in:
@@ -61,9 +61,9 @@ LuaWindow::LuaWindow(lua_State * l) :
|
|||||||
int sizeY = luaL_optinteger(l, 4, 10);
|
int sizeY = luaL_optinteger(l, 4, 10);
|
||||||
|
|
||||||
// We should replace this with errors
|
// We should replace this with errors
|
||||||
if (posX < 1)
|
if (posX < 1 && posX != -1)
|
||||||
posX = 1;
|
posX = 1;
|
||||||
if (posY < 1)
|
if (posY < 1 && posY != -1)
|
||||||
posY = 1;
|
posY = 1;
|
||||||
if (sizeX < 10)
|
if (sizeX < 10)
|
||||||
sizeX = 10;
|
sizeX = 10;
|
||||||
|
Reference in New Issue
Block a user