From 2ec573c84a2e59c8c3c5bc0e6bb07f80a47d4656 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 ef1dde6..aa958de 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++) {