function tappedRect:touch(event)
if (boxSize:setFillColor(255,255,255)) then
boxSize:setFillColor(0,255,0)
end
end
boxSize:addEventListener(“touch”, tappedRect)
I don’t know why but it won’t work with a grid I have made, but it does work on a single rectangle in a seperate programme.