From fc3a700357cfca61a452fbf21ba7a04d3ceddd14 Mon Sep 17 00:00:00 2001 From: Greenphx9 <55181320+Greenphx9@users.noreply.github.com> Date: Sun, 25 Aug 2024 18:01:23 +1000 Subject: [PATCH] Fix up some auto merge stuff --- include/global.h | 2 ++ include/overworld.h | 4 ++++ src/decompress.c | 4 ++-- src/field_weather_effect.c | 1 - 4 files changed, 8 insertions(+), 3 deletions(-) diff --git a/include/global.h b/include/global.h index 88892bd60e..c09f8af779 100644 --- a/include/global.h +++ b/include/global.h @@ -536,6 +536,8 @@ struct SaveBlock2 extern struct SaveBlock2 *gSaveBlock2Ptr; +extern u8 UpdateSpritePaletteWithTime(u8); + struct SecretBaseParty { u32 personality[PARTY_SIZE]; diff --git a/include/overworld.h b/include/overworld.h index 0cc0ab5dce..06b8cf1ee8 100644 --- a/include/overworld.h +++ b/include/overworld.h @@ -25,6 +25,10 @@ #define MOVEMENT_MODE_SCRIPTED 2 #define SKIP_OBJECT_EVENT_LOAD 1 +#define TIME_OF_DAY_NIGHT 0 +#define TIME_OF_DAY_TWILIGHT 1 +#define TIME_OF_DAY_DAY 2 +#define TIME_OF_DAY_MAX TIME_OF_DAY_DAY struct InitialPlayerAvatarState { diff --git a/src/decompress.c b/src/decompress.c index 30337f5a8d..d9ad044ebb 100644 --- a/src/decompress.c +++ b/src/decompress.c @@ -60,7 +60,7 @@ u16 LoadCompressedSpriteSheetByTemplate(const struct SpriteTemplate *template, s // Check for LZ77 header and read uncompressed size, or fallback if not compressed (zero size) if ((size = IsLZ77Data(template->images->data, TILE_SIZE_4BPP, sizeof(gDecompressionBuffer))) == 0) - return LoadSpriteSheetByTemplate(template, 0, offset); + return LoadSpriteSheetByTemplateWithOffset(template, 0, offset); LZ77UnCompWram(template->images->data, gDecompressionBuffer); myImage.data = gDecompressionBuffer; @@ -68,7 +68,7 @@ u16 LoadCompressedSpriteSheetByTemplate(const struct SpriteTemplate *template, s myTemplate.images = &myImage; myTemplate.tileTag = template->tileTag; - return LoadSpriteSheetByTemplate(&myTemplate, 0, offset); + return LoadSpriteSheetByTemplateWithOffset(&myTemplate, 0, offset); } void LoadCompressedSpriteSheetOverrideBuffer(const struct CompressedSpriteSheet *src, void *buffer) diff --git a/src/field_weather_effect.c b/src/field_weather_effect.c index efd80a7178..9810cdfcaa 100644 --- a/src/field_weather_effect.c +++ b/src/field_weather_effect.c @@ -1410,7 +1410,6 @@ void FogHorizontal_Main(void) case 0: CreateFogHorizontalSprites(); if (gWeatherPtr->currWeather == WEATHER_FOG_HORIZONTAL) { - u8 paletteNum = IndexOfSpritePaletteTag(TAG_WEATHER_START); Weather_SetTargetBlendCoeffs(12, 8, 3); UpdateShadowColor(0x3DEF); // Gray } else