diff options
author | ghoulslash <41651341+ghoulslash@users.noreply.github.com> | 2020-07-15 18:24:11 -0600 |
---|---|---|
committer | ghoulslash <41651341+ghoulslash@users.noreply.github.com> | 2020-07-15 18:24:11 -0600 |
commit | 3d799499760a8242b8762a89019cdb2e4e51bda5 (patch) | |
tree | 6a7965664cc0d56a459eeb9ad2a8584f3fdb8fb0 | |
parent | a2a172495aca1abed5b38e926b09814cf79e837b (diff) |
Created Fix Snow Weather (markdown)
-rw-r--r-- | Fix-Snow-Weather.md | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/Fix-Snow-Weather.md b/Fix-Snow-Weather.md new file mode 100644 index 0000000..a479394 --- /dev/null +++ b/Fix-Snow-Weather.md @@ -0,0 +1,38 @@ +## Fix Snow Weather + +In vanilla emerald (and Fire Red!) the WEATHER_SNOW is broken and will only emit a few snowflakes before stopping. Let's fix it! + +For starters, open [src/field_weather_effects.c](../blob/master/src/field_weather_effect.c) + +### Increase the number of snowflakes (optional) +If you want to have the snow be heavier (or lighter), find `Snow_InitVars` and edit the line `gWeatherPtr->targetSnowflakeSpriteCount = 16;` to a value of your choosing. + +### Stop the snow from disappearing +Find the function `UpdateSnowflakeSprite`, and delete the following code (lines 974-998): +```c + y = (sprite->pos1.y + sprite->centerToCornerVecY + gSpriteCoordOffsetY) & 0xFF; + if (y > 163 && y < 171) + { + sprite->pos1.y = 250 - (gSpriteCoordOffsetY + sprite->centerToCornerVecY); + sprite->tPosY = sprite->pos1.y * 128; + sprite->tFallCounter = 0; + sprite->tFallDuration = 220; + } + else if (y > 242 && y < 250) + { + sprite->pos1.y = 163; + sprite->tPosY = sprite->pos1.y * 128; + sprite->tFallCounter = 0; + sprite->tFallDuration = 220; + sprite->invisible = TRUE; + sprite->callback = WaitSnowflakeSprite; + } + + if (++sprite->tFallCounter == sprite->tFallDuration) + { + InitSnowflakeSpriteMovement(sprite); + sprite->pos1.y = 250; + sprite->invisible = TRUE; + sprite->callback = WaitSnowflakeSprite; + } +```
\ No newline at end of file |