From cb4ac81cae7f197856b29bb8961cc8df67317ef2 Mon Sep 17 00:00:00 2001 From: nutbuster Date: Sun, 11 Jul 2021 11:39:48 +1000 Subject: [PATCH] Extra Spaces fix --- game/src/cg_gallery.rpy | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/game/src/cg_gallery.rpy b/game/src/cg_gallery.rpy index 44baf9c..9bdc135 100644 --- a/game/src/cg_gallery.rpy +++ b/game/src/cg_gallery.rpy @@ -85,6 +85,7 @@ init python: def loadGallery(): cgPath = "images/cgs/" + lazy_counter = 0 # Reset gallery galleryItems = [] @@ -100,9 +101,10 @@ init python: unlocked = renpy.seen_image(str) image = renpy.image_size(Image(_str)) addGalleryItem(str, ACCEPTED_EXTENSIONS[0], image[0], image[1], unlocked) + lazy_counter += 1 # Add empty items to fill grid after last cg button - extraSpaces = GALLERY_COLS - (len(galleryItems) % GALLERY_COLS) + extraSpaces = GALLERY_COLS - (lazy_counter % GALLERY_COLS) for i in range(0, extraSpaces): galleryItems.append({ "item": None,