JVRL5TWLBTWMTHJDZSDN5XQDMEIIPVAZBKUP75HMO7JHURAYWG5QC
L5USRTY2TF4F63CJZQ24QJXI2TZ4JJO324EVFXJKFMFJF2VQRWJQC
MNWHXPBL23TOI45LPF7ZECXSURCD2TRLM2EOFNBKFNHIWWKDQWCQC
3XD6M3CFKZJR365MHXUWJ4HGSDTPYO6WYZ4RGW7ECBBITKVQX24QC
2C7CTIQYDDYVQJNKX2OSHZ6VMAMPOGNUVTSFAUV7HQCPMZR2YRUAC
YHQC72JXDNMLVZ2KBFI6HZY6EDDVK4RJ5I2KOK7LEW6LJDLPV7JAC
IZZVOCLB7KB4ZNQ35OL466MHWOK3XZMOS7ZPFLHUFQ47LJLQQQ3QC
OTIBCAUJ3KDQJLVDN3A536DLZGNRYMGJLORZVR3WLCGXGO6UGO6AC
XX7G2FFJ4QCGQGD4REAW5QFHVYAKCFUPGZCK7L6DFGS5ISVBYBQQC
G77XIN7MLX465AXLXDUJDGEHXXCMR2Q7K25UAMKQERBJGNJPNW6AC
TRCAEE2ASBJJCFFJYP2DGPLDOE4R2ACSY37PZSJSKOPQLATFO2EAC
POT3XFCTWLQJ5EJ6OUXYTFWSXEX37WUMQZ6PEHO3RRDNOEQIJRXQC
EFMLTMZG5TUEGLSYLVKOKDSTGVSVWSKOMS7CJWOUGK5LADSH4YTQC
-- All drawings span 100% of some conceptual 'page width' and divide it up
-- into 256 parts. `drawingw` describes their width in pixels.
drawingw = 400 -- pixels
function pixels(n) -- parts to pixels
return n*drawingw/256
end
function coord(n) -- pixels to parts
return math.floor(n*256/drawingw)
end
if y >= drawing.y and y < drawing.y + drawing.h and x >= 12 and x < 12+drawing.w then
table.insert(drawing.pending, {x=love.mouse.getX(), y=love.mouse.getY()})
if y >= drawing.y and y < drawing.y + pixels(drawing.h) and x >= 12 and x < 12+drawingw then
table.insert(drawing.pending, {x=coord(love.mouse.getX()-12), y=coord(love.mouse.getY()-drawing.y)})