local sx, sy = guiGetScreenSize() local zoom = 1920/sx function scaleX(type, value) if type == 'center' then return math.floor(sx/2 - value/zoom) elseif type == 'left' then return math.floor(sx - value/zoom) elseif type == 'right' then return math.floor(value/zoom) end end function scaleY(type, value) if type == 'center' then return math.floor(sy/2 - value/zoom) elseif type == 'top' then return math.floor(value/zoom) elseif type == 'down' then return math.floor(sy - value/zoom) end end