Solved My SMAPI has just?? decided to not work anymore?? like excuse me ma'am?

Clarei

Greenhorn
My SMAPI has been working fine until just the other day where it won't open the game because it's apparently not executable, except I haven't done anything different to my game for a while now. Like, no new mods added at all, no tweaking in the files- nothing, and it's just suddenly not opening the game. The game itself opens just fine (the unmodded version), but the SMAPI launcher won't even get as far as loading any mods before it tells me to press any key to close the tab. Here is exactly what it tells me.

Oops! SMAPI couldn't load the game executable. The technical details below may have more info.

Technical details: System.BadImageFormatException: Could not load file or assembly 'Stardew Valley' or one of its dependencies. An attempt was made to load a program with an incorrect format.
File name: 'Stardew Valley'
at System.RuntimeTypeHandle.GetTypeByName(String name, Boolean throwOnError, Boolean ignoreCase, Boolean reflectionOnly, StackCrawlMarkHandle stackMark, IntPtr pPrivHostBinder, Boolean loadTypeFromPartialName, ObjectHandleOnStack type)
at System.RuntimeTypeHandle.GetTypeByName(String name, Boolean throwOnError, Boolean ignoreCase, Boolean reflectionOnly, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean loadTypeFromPartialName)
at System.RuntimeType.GetType(String typeName, Boolean throwOnError, Boolean ignoreCase, Boolean reflectionOnly, StackCrawlMark& stackMark)
at System.Type.GetType(String typeName, Boolean throwOnError)
at StardewModdingAPI.Program.AssertGamePresent() in C:\source\_Stardew\SMAPI\src\SMAPI\Program.cs:line 83

WRN: Assembly binding logging is turned OFF.
To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1.
Note: There is some performance penalty associated with assembly bind failure logging.
To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].


Game has ended. Press any key to exit.


-----
Does anyone know what happened? I don't get it at all and I'm usually pretty good when it comes to modding. I'm wondering if Steam updated Stardew Valley and caused my SMAPI to go out of date or something, though my go-to launcher is curse Overwolf. I did click the 'update all' button for the few mods I got from curse, and it updated my Bookcase mod, but to ne honest I can't see how that would change any .dll files or anything.
 

Clarei

Greenhorn
Hiya. I'm not the most experienced here but if I were in your shoes, I would

1. Verify the game files in Steam/GOG (if GOG has that feature).
2. Reinstall the latest SMAPI: https://www.nexusmods.com/stardewvalley/mods/2400
3. Try running your modded game through SMAPI again. If you can, post a SMAPI log here afterwards using this link: https://smapi.io/log
UPDATE
My SMAPI now successfully opens and runs until I actually click on one of my game files, because then it just stops responding even without any mods loaded onto it. I have the latest version now and I've literally tried everything. :(
 

Clarei

Greenhorn
Hiya. I'm not the most experienced here but if I were in your shoes, I would

1. Verify the game files in Steam/GOG (if GOG has that feature).
2. Reinstall the latest SMAPI: https://www.nexusmods.com/stardewvalley/mods/2400
3. Try running your modded game through SMAPI again. If you can, post a SMAPI log here afterwards using this link: https://smapi.io/log
I can't see any lines of code after the game stops responding unfortunately, which is the problem because I don't know what's going wrong.
 

Clarei

Greenhorn
Hey Guys! Somehow it's sorted itself out? like I didn't even do anything and now my SMAPI is working perfectly :hmph:
But I've noticed that when I'm running around, there's a weird visual glitch. It's kind of like a horizontal line of static moves up the screen and it's so distracting- like kill me. I've checked all of my graphics are toggled right, but I just can't figure out what's causing it to bug out like that. It wasn't this way before the update though. Thanks for all of the help btw!
 

Dragonheardt

Planter
Hey Guys! Somehow it's sorted itself out? like I didn't even do anything and now my SMAPI is working perfectly :hmph:
But I've noticed that when I'm running around, there's a weird visual glitch. It's kind of like a horizontal line of static moves up the screen and it's so distracting- like kill me. I've checked all of my graphics are toggled right, but I just can't figure out what's causing it to bug out like that. It wasn't this way before the update though. Thanks for all of the help btw!
Hiya. Try this:
  1. Toggle V-Sync in the Options menu of Stardew Valley, see if that helps. Turning it on should eliminate screen tearing.
 

IntoxicHeart

Planter
Hi! I just got this exact same error message too, and I tried downloading the updated Smapi but it still isn't working.

Here's my Smapi log that I followed from this thread: https://smapi.io/log/8b1f69bfb1e04d77aa722d084227abc9

If anyone has any ideas on how to fix this, please let me know :,)
You have a few things to update. One moment and I’ll get you the list.

edit;;

20:51:31ALERTSMAPI [CP] Events Expansion 1.2.0: https://www.nexusmods.com/stardewvalley/mods/9042
20:51:31ALERTSMAPI CJB Cheats Menu 1.29.1: https://www.nexusmods.com/stardewvalley/mods/4
20:51:31ALERTSMAPI CJB Item Spawner 2.1.4: https://www.nexusmods.com/stardewvalley/mods/93
20:51:31ALERTSMAPI Content Patcher 1.23.5: https://www.nexusmods.com/stardewvalley/mods/1915
20:51:31ALERTSMAPI CustomMusic 1.8.1: https://www.nexusmods.com/stardewvalley/mods/3043
20:51:31ALERTSMAPI Json Assets 1.10.0: https://www.nexusmods.com/stardewvalley/mods/1720
20:51:31ALERTSMAPI PyTK 1.22.8: https://www.nexusmods.com/stardewvalley/mods/1726
20:51:31ALERTSMAPI SpaceCore 1.7.0: https://www.nexusmods.com/stardewvalley/mods/1348
20:51:31ALERTSMAPI Stardew Valley Expanded 1.13.11: https://www.nexusmods.com/stardewvalley/mods/3753
repeats [1] times.
20:51:31ALERTSMAPI TMXL Map Toolkit 1.22.1: https://www.nexusmods.com/stardewvalley/mods/1820
20:51:31ALERTSMAPI Tractor Mod 4.14.4: https://www.nexusmods.com/stardewvalley/mods/1401


Unofficial updates for PyTK, TMXL, Custom Music found here:

The other mods listed should be updated on their respective pages on nexus mods.

Be sure to delete those mods before you reinstall them.

You also need to update SMAPI.

Edit;; missed your mention about how you tried update SMAPI… sorry about that, my bad ^^;; How did you try it?
 
Last edited:
Top