SMAPI/README.md

2.3 KiB

SMAPI is an open-source modding API for Stardew Valley. It takes care of loading mods into the game context, and exposes events they can use to interact with the game. It's safely installed alongside the game's executable, and doesn't change any of your game files.

For players

For mod developers

For SMAPI developers

Compiling from source

Using one of the SMAPI releases is recommended for most users.

If you'd like to compile SMAPI from source, you can do that on any platform. SMAPI uses build configuration derived from the crosswiki mod config to detect your current OS automatically and load the correct references.

Preparing a release

  1. Open the project in Visual Studio or MonoDevelop.
  2. Switch to Release build mode.
  3. Update the version number in AssemblyInfo.cs.
  4. Update the version number in Constants::Version. Add the minimum game version and target platform at the end of the version number (like 0.41.0 1.1 for Windows).
  5. Build the solution.
  6. Copy the files for the target platform into the archive structure below.
  7. Repeat for each platform.

The release should consist of three files like this:

SMAPI-1.0-Linux.tar.gz
   Mods/*
   Newtonsoft.Json.dll
   StardewModdingAPI
   StardewModdingAPI.exe
   StardewModdingAPI.mdb
   System.Numerics.dll

SMAPI-1.0-Mac.tar.gz
   Mods/*
   Newtonsoft.Json.dll
   StardewModdingAPI
   StardewModdingAPI.exe
   StardewModdingAPI.mdb
   System.Numerics.dll

SMAPI-1.0-Windows.zip
   Mods/*
   StardewModdingAPI.exe
   StardewModdingAPI.pdb