The images for that print out would be on a row(y=115) going from left to right from 31 to 157.
What does the print out look like for when the images do not go where you want them to go?
No need to print values that don't change like Offset and length every time you print. Print them one time before the loop begins.