Solved Game crashing when attempting to enter a town festival?

Hey all!

Been having a new issue where whenever I try to enter the Stardew Valley Fair the game crashes. I updated all my mods and everything else runs smoothly, it's just the festival that causes the game to crash. Here's the log from SMAPI: https://smapi.io/log/36a2ec58f3d54deaaa65ed043a155c59

I play on Windows 11 64-bit, my game is fully updated. Thanks in advance!
 
Last edited by a moderator:
Thanks for the log.
This is the important section:
Code:
21:31:30    TRACE    Content Patcher    [CP] Stardew Valley Reimagined 2 loaded Maps/Town-Fair.
21:31:31    TRACE    SMAPI    Content Patcher loaded asset 'Maps/Town-Fair'.
21:31:31    WARN    Content Patcher    SMAPI found an issue with 'Maps/Town-Fair' map load: mod reordered the original tilesheets, which often causes crashes.
Technical details for mod author: Expected order: characters, Landscape, Paths, Town, untitled tile sheet. See https://stardewvalleywiki.com/Modding:Maps#Tilesheet_order for help.
...
21:31:31    ERROR    game    An error occurred in the base update loop: DivideByZeroException: Attempted to divide by zero.
   at StardewValley.GameLocation.UpdateMapSeats() in stardewvalley\Farmer\Farmer\Locations\GameLocation.cs:line 1583
   at StardewValley.Locations.Town.UpdateMapSeats() in stardewvalley\Farmer\Farmer\Locations\Town.cs:line 51
   at StardewValley.GameLocation.UpdateWhenCurrentLocation(GameTime time) in stardewvalley\Farmer\Farmer\Locations\GameLocation.cs:line 3268
   at StardewValley.Locations.Town.UpdateWhenCurrentLocation(GameTime time) in stardewvalley\Farmer\Farmer\Locations\Town.cs:line 1154
   at StardewValley.Game1.UpdateLocations(GameTime time) in stardewvalley\Farmer\Farmer\Game1.cs:line 6463
   at StardewValley.Game1._update(GameTime gameTime) in stardewvalley\Farmer\Farmer\Game1.cs:line 4867
   at StardewValley.Game1.Update(GameTime gameTime) in stardewvalley\Farmer\Farmer\Game1.cs:line 3974
   at StardewModdingAPI.Framework.SCore.OnPlayerInstanceUpdating(SGame instance, GameTime gameTime, Action runUpdate) in SMAPI\Framework\SCore.cs:line 1003
...
21:31:31    ERROR    SMAPI    An error occurred in the overridden draw loop: DivideByZeroException: Attempted to divide by zero.
   at xTile.Tiles.TileSheet.GetTileImageBounds(Int32 tileIndex) in stardewvalley\Farmer\xTileSource\xTile\Tiles\TileSheet.cs:line 254
   at PyTK.Types.PyDisplayDevice.DrawTile(Tile tile, Location location, Single layerDepth) in H:\Modding\Stardew-Valley\Stardew-Valley-Mods\Stardew-Valley-Mods\PyTK\Types\PyDisplayDevice.cs:line 82
   at xTile.Layers.Layer.DrawNormal(IDisplayDevice displayDevice, Rectangle mapViewport, Location displayOffset, Int32 pixelZoom) in stardewvalley\Farmer\xTileSource\xTile\Layers\Layer.cs:line 426
   at StardewModdingAPI.Framework.SGame.DrawImpl(GameTime gameTime, RenderTarget2D target_screen) in SMAPI\Framework\SGame.cs:line 517
   at StardewModdingAPI.Framework.SGame._draw(GameTime gameTime, RenderTarget2D target_screen) in SMAPI\Framework\SGame.cs:line 216
You mentioned the festival was having issues; usually it's pulled from data "Content/Data/Festivals/fall16.*". And, while I see some mods that do edit the festival data; this error seems to show a map bug.
And one of the last active mods was "SDV Reimagined 2". Can you try disabling the whole mod, or at the very least editing the config file it generates to disable the "Town" edits.
Then give it a retry.

The 2nd error that repeats is PyTK; it's crashing on something. But, I'm not too sure which mod; it may be related to the first error, or stumbling on something else.
We may have to test disabling this one as well, but first try disabling the Reimagined mod.
 
Thanks for the log.
This is the important section:
Code:
21:31:30    TRACE    Content Patcher    [CP] Stardew Valley Reimagined 2 loaded Maps/Town-Fair.
21:31:31    TRACE    SMAPI    Content Patcher loaded asset 'Maps/Town-Fair'.
21:31:31    WARN    Content Patcher    SMAPI found an issue with 'Maps/Town-Fair' map load: mod reordered the original tilesheets, which often causes crashes.
Technical details for mod author: Expected order: characters, Landscape, Paths, Town, untitled tile sheet. See https://stardewvalleywiki.com/Modding:Maps#Tilesheet_order for help.
...
21:31:31    ERROR    game    An error occurred in the base update loop: DivideByZeroException: Attempted to divide by zero.
   at StardewValley.GameLocation.UpdateMapSeats() in stardewvalley\Farmer\Farmer\Locations\GameLocation.cs:line 1583
   at StardewValley.Locations.Town.UpdateMapSeats() in stardewvalley\Farmer\Farmer\Locations\Town.cs:line 51
   at StardewValley.GameLocation.UpdateWhenCurrentLocation(GameTime time) in stardewvalley\Farmer\Farmer\Locations\GameLocation.cs:line 3268
   at StardewValley.Locations.Town.UpdateWhenCurrentLocation(GameTime time) in stardewvalley\Farmer\Farmer\Locations\Town.cs:line 1154
   at StardewValley.Game1.UpdateLocations(GameTime time) in stardewvalley\Farmer\Farmer\Game1.cs:line 6463
   at StardewValley.Game1._update(GameTime gameTime) in stardewvalley\Farmer\Farmer\Game1.cs:line 4867
   at StardewValley.Game1.Update(GameTime gameTime) in stardewvalley\Farmer\Farmer\Game1.cs:line 3974
   at StardewModdingAPI.Framework.SCore.OnPlayerInstanceUpdating(SGame instance, GameTime gameTime, Action runUpdate) in SMAPI\Framework\SCore.cs:line 1003
...
21:31:31    ERROR    SMAPI    An error occurred in the overridden draw loop: DivideByZeroException: Attempted to divide by zero.
   at xTile.Tiles.TileSheet.GetTileImageBounds(Int32 tileIndex) in stardewvalley\Farmer\xTileSource\xTile\Tiles\TileSheet.cs:line 254
   at PyTK.Types.PyDisplayDevice.DrawTile(Tile tile, Location location, Single layerDepth) in H:\Modding\Stardew-Valley\Stardew-Valley-Mods\Stardew-Valley-Mods\PyTK\Types\PyDisplayDevice.cs:line 82
   at xTile.Layers.Layer.DrawNormal(IDisplayDevice displayDevice, Rectangle mapViewport, Location displayOffset, Int32 pixelZoom) in stardewvalley\Farmer\xTileSource\xTile\Layers\Layer.cs:line 426
   at StardewModdingAPI.Framework.SGame.DrawImpl(GameTime gameTime, RenderTarget2D target_screen) in SMAPI\Framework\SGame.cs:line 517
   at StardewModdingAPI.Framework.SGame._draw(GameTime gameTime, RenderTarget2D target_screen) in SMAPI\Framework\SGame.cs:line 216
You mentioned the festival was having issues; usually it's pulled from data "Content/Data/Festivals/fall16.*". And, while I see some mods that do edit the festival data; this error seems to show a map bug.
And one of the last active mods was "SDV Reimagined 2". Can you try disabling the whole mod, or at the very least editing the config file it generates to disable the "Town" edits.
Then give it a retry.

The 2nd error that repeats is PyTK; it's crashing on something. But, I'm not too sure which mod; it may be related to the first error, or stumbling on something else.
We may have to test disabling this one as well, but first try disabling the Reimagined mod.
Thank you for the help; I disabled the Town edits (and removed another map editing mod I had - Karmylla's Immersive Maps for anyone who might have the same problem as me) and it works now! Thank you so much!
 
Top