So, I am trying to make a program in Java that opens a JFrame window and displays images. these images are part of a Tile map/Sprite sheet.
g2.drawImage(image, screenX, screenY, gp.tileSize, gp.tileSize, null);
image is the whole image and ScreenX/Y is the location, and the tileSize is the size of the image - this is displaying the whole image, how would i display at the same size but only part of the image. If this is unclear please tell me so.