LittleRaskol
Greenhorn
Note: I have contacted the mod author about what I'll talk about in this post, but have not heard back after several days. So I figured I would throw it to the forums.
TL,DR: What's up with this error about what appears to be a normal part of the SMAPI?
The version number will change based on what version of SMAPI is installed, and this is mysterious since IManifest is just a normal part of SMAPI. Attempting to add "using StardewModdingAPI.Toolkit.CoreInterfaces;" fails with a "directive is unneeded" error.
Longer story:
I like the way Stardew Config Menu adds a tab to the in-game menu and wanted to use it for updates to my Stardew Valley mods. Since it was open source, I figured I might be able to just follow the update guides to bring the mod up to date with the most recent SMAPI. Everything was smooth (just followed the update guide, you can see a comparison here) except for two things:
So I went to do the same thing on the StardewConfigFramework code. I didn't realize that the default page in github would be for the development branch, though. So I was able to get a working DLL out of it by just updating the SMAPI version in the project, but if you compare to the master branch (here), it has a bunch of changes the author I guess was working on and that I don't know if they work yet. (You can see just the things I changed here.)
Since I couldn't be sure the dev branch was ready to be used, I switched to master and tried the same thing... and eventually got the same strange error:
The type 'IManifest' is defined in an assembly that is not referenced. You must add a reference to assembly 'SMAPI.Toolkit.CoreInterfaces, Version=3.6.2.0, Culture=neutral, PublicKeyToken=null'. This was paired with this error on any reference to IManifest: The type or namespace name 'IManifest' could not be found (are you missing a using directive or an assembly reference?)
So I don't understand what's going on here. IManifest seems to be a part of SMAPI, so why do I need some special reference? Attempting to add "using StardewModdingAPI.Toolkit.CoreInterfaces;" fails with a "directive is unneeded" error. What's up here, does anyone know? And does anyone have any idea whether I can use the DLL that I created from the dev branch code?
TL,DR: What's up with this error about what appears to be a normal part of the SMAPI?
Code:
The type 'IManifest' is defined in an assembly that is not referenced. You must add a reference to assembly 'StardewModdingAPI.Toolkit.CoreInterfaces, Version=2.6.0.0, Culture=neutral, PublicKeyToken=null'.
Longer story:
I like the way Stardew Config Menu adds a tab to the in-game menu and wanted to use it for updates to my Stardew Valley mods. Since it was open source, I figured I might be able to just follow the update guides to bring the mod up to date with the most recent SMAPI. Everything was smooth (just followed the update guide, you can see a comparison here) except for two things:
- I had to just comment out everything related to "HandleJunimo" because it relied on looking for something in Stardew Valley's GameMenu code that no longer exists (junimoNoteIcon). I therefore figured this was obsolete as of the most recent game version. If someone has a better idea what's going on here I am all ears!
- One thing I could not fix was any reference to an IManifest object in IOptionsPackage. It threw the following odd error: The type 'IManifest' is defined in an assembly that is not referenced. You must add a reference to assembly 'StardewModdingAPI.Toolkit.CoreInterfaces, Version=2.6.0.0, Culture=neutral, PublicKeyToken=null'.
So I went to do the same thing on the StardewConfigFramework code. I didn't realize that the default page in github would be for the development branch, though. So I was able to get a working DLL out of it by just updating the SMAPI version in the project, but if you compare to the master branch (here), it has a bunch of changes the author I guess was working on and that I don't know if they work yet. (You can see just the things I changed here.)
Since I couldn't be sure the dev branch was ready to be used, I switched to master and tried the same thing... and eventually got the same strange error:
The type 'IManifest' is defined in an assembly that is not referenced. You must add a reference to assembly 'SMAPI.Toolkit.CoreInterfaces, Version=3.6.2.0, Culture=neutral, PublicKeyToken=null'. This was paired with this error on any reference to IManifest: The type or namespace name 'IManifest' could not be found (are you missing a using directive or an assembly reference?)
So I don't understand what's going on here. IManifest seems to be a part of SMAPI, so why do I need some special reference? Attempting to add "using StardewModdingAPI.Toolkit.CoreInterfaces;" fails with a "directive is unneeded" error. What's up here, does anyone know? And does anyone have any idea whether I can use the DLL that I created from the dev branch code?