/ critline landscape scaling
This commit is contained in:
parent
42874906c8
commit
d9c1664f66
|
@ -8,10 +8,22 @@ local CRITBAR_H = 348
|
||||||
|
|
||||||
local scale;
|
local scale;
|
||||||
|
|
||||||
|
local isLandscape = false;
|
||||||
|
|
||||||
local setUpTransforms = function (x,y,rotation)
|
local setUpTransforms = function (x,y,rotation)
|
||||||
local resx, resy = game.GetResolution()
|
local resx, resy = game.GetResolution();
|
||||||
local desw = 1080
|
isLandscape = resx > resy;
|
||||||
local desh = 1920
|
|
||||||
|
local desw, desh;
|
||||||
|
|
||||||
|
if (isLandscape) then
|
||||||
|
desw = 1920;
|
||||||
|
desh = 1080;
|
||||||
|
else
|
||||||
|
desw = 1080;
|
||||||
|
desh = 1920;
|
||||||
|
end
|
||||||
|
|
||||||
scale = resx / desw
|
scale = resx / desw
|
||||||
|
|
||||||
gfx.Translate(x, y)
|
gfx.Translate(x, y)
|
||||||
|
|
Loading…
Reference in New Issue