From 0d7cc66ffd054683a3add04a750b3031cb1803e5 Mon Sep 17 00:00:00 2001 From: Snowy Date: Sun, 24 Oct 2021 11:15:28 -0500 Subject: [PATCH] Change y to a signed value --- Core/display.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Core/display.c b/Core/display.c index ef1dde6f..aa958de4 100644 --- a/Core/display.c +++ b/Core/display.c @@ -1526,7 +1526,7 @@ uint8_t GB_get_oam_info(GB_gameboy_t *gb, GB_oam_info_t *dest, uint8_t *sprite_h uint8_t count = 0; *sprite_height = (gb->io_registers[GB_IO_LCDC] & 4) ? 16:8; uint8_t oam_to_dest_index[40] = {0,}; - for (unsigned y = 0; y < LINES; y++) { + for (signed y = 0; y < LINES; y++) { GB_object_t *sprite = (GB_object_t *) &gb->oam; uint8_t sprites_in_line = 0; for (uint8_t i = 0; i < 40; i++, sprite++) {