gui/GuiManager/Misc/InGridY.int
Ryan Ward 76fd457833 Updated to 9.0.0
Love2D 1.11 Support is here! :D
2018-06-09 14:54:54 -04:00

5 lines
143 B
Plaintext

function InGridY(i,w,h,xs,ys)
local xc,yc=math.floor(w/xs),math.floor(h/ys)
local xi,yi=math.floor((i-1)/yc),(i-1)%yc
return xi*xs,yi*ys
end