BSchneppe.Sts2.ReferenceAssemblies 0.107.1

There is a newer prerelease version of this package available.
See the version list below for details.
dotnet add package BSchneppe.Sts2.ReferenceAssemblies --version 0.107.1
                    
NuGet\Install-Package BSchneppe.Sts2.ReferenceAssemblies -Version 0.107.1
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="BSchneppe.Sts2.ReferenceAssemblies" Version="0.107.1" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="BSchneppe.Sts2.ReferenceAssemblies" Version="0.107.1" />
                    
Directory.Packages.props
<PackageReference Include="BSchneppe.Sts2.ReferenceAssemblies" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add BSchneppe.Sts2.ReferenceAssemblies --version 0.107.1
                    
#r "nuget: BSchneppe.Sts2.ReferenceAssemblies, 0.107.1"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package BSchneppe.Sts2.ReferenceAssemblies@0.107.1
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=BSchneppe.Sts2.ReferenceAssemblies&version=0.107.1
                    
Install as a Cake Addin
#tool nuget:?package=BSchneppe.Sts2.ReferenceAssemblies&version=0.107.1
                    
Install as a Cake Tool

BSchneppe.Sts2.ReferenceAssemblies

NuGet

Reference-only stubs for Slay the Spire 2 mod development.

Why?

Slay the Spire 2 mods require three game assemblies to compile:

  • sts2.dll
  • 0Harmony.dll
  • GodotSharp.dll

These DLLs only exist in local game installs and cannot be redistributed. This package provides reference-only stubs (type definitions with no implementation code) that allow mods to compile in CI environments without needing a full game installation.

Usage

In your mod's .csproj, add a conditional reference that falls back to the NuGet package when the game is not installed locally:

<PropertyGroup>
  
  <STS2GameDir Condition="'$(STS2GameDir)' == ''">C:/Program Files (x86)/Steam/steamapps/common/Slay the Spire 2/data/</STS2GameDir>
</PropertyGroup>

<ItemGroup>
  
  <PackageReference Include="BSchneppe.Sts2.ReferenceAssemblies" Version="0.100.*"
                    Condition="!Exists('$(STS2GameDir)/sts2.dll')"
                    PrivateAssets="All" />
</ItemGroup>


<ItemGroup Condition="Exists('$(STS2GameDir)/sts2.dll')">
  <Reference Include="sts2">
    <HintPath>$(STS2GameDir)/sts2.dll</HintPath>
    <Private>false</Private>
  </Reference>
  <Reference Include="0Harmony">
    <HintPath>$(STS2GameDir)/0Harmony.dll</HintPath>
    <Private>false</Private>
  </Reference>
  <Reference Include="GodotSharp">
    <HintPath>$(STS2GameDir)/GodotSharp.dll</HintPath>
    <Private>false</Private>
  </Reference>
</ItemGroup>

CI/CD Example (GitHub Actions)

Since the NuGet package provides the stubs, your CI workflow doesn't need the game installed:

name: Build Mod

on: [push, pull_request]

jobs:
  build:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - name: Setup .NET
        uses: actions/setup-dotnet@v4
        with:
          dotnet-version: '9.0.x'
      - name: Restore dependencies
        run: dotnet restore
      - name: Build
        run: dotnet build -c Release --no-restore

How to regenerate stubs (for maintainers)

  1. Ensure you have the game installed.

  2. Ensure you have the dotnet CLI installed. The generation script will automatically install the refasmer global tool if it's not found in ~/.dotnet/tools/refasmer.

  3. Run the generation script:

    ./scripts/generate-stubs.sh
    

    (If the game is in a non-standard location, set STS2_GAME_DIR first.)

  4. Pack and publish:

    dotnet pack BSchneppe.Sts2.ReferenceAssemblies/BSchneppe.Sts2.ReferenceAssemblies.csproj -c Release
    

These stubs contain only type signatures and no implementation logic. They are intended for compilation use only and do not contain copyrighted game code.

Product Compatible and additional computed target framework versions.
.NET net9.0 is compatible.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 was computed.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
  • net9.0

    • No dependencies.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
0.111.0-beta-41cef1ea 220 8/14/2026
0.110.0-beta-eecc8c4d 147 7/31/2026
0.109.0-beta-c12f634d 133 7/17/2026
0.107.1 247 7/17/2026
0.103.2 406 4/17/2026
0.103.0-beta-bb50d016 236 4/10/2026
0.102.0-beta-5fd772f8 172 4/7/2026
0.101.0-beta-a6b8b83d 214 3/29/2026
0.99.1 285 3/29/2026