[1.1][LIB] NuGet Package for RimWorld Assemblies

Started by krafs, November 16, 2019, 06:07:55 AM

Previous topic - Next topic

krafs

What is it?
RimRef is a NuGet package containing reference assemblies for all managed C# assemblies in RimWorld.

What does it do?
It allows for compiling RimWorld mods without the game assemblies.

Who is it for?
Anyone making C# mods for RimWorld.

Why use it?
By removing the need for adding references to actual game files, developers can make their mods self-contained.
A self-contained mod has everything needed to build it contained within the mod project itself.
Basically, anyone can clone the git repository of a self-contained mod, open it in her IDE, click Build, and it will work. No need to manually add any references.

Where can I get it?
It is available on nuget.org.
Using Visual Studio - Add it to your mod project by right-clicking Dependencies -> Manage NuGet packages.
Search for Krafs.Rimworld.Ref and install*.
Don't forget to remove the old references to the actual game assemblies.

You can read about the package in more detail at GitHub.

Published with permission from Ludeon Studios.




*This package is only compatible with projects using PackageReference. It's a different, much better way to organize your NuGet references than packages.config.
However, it is easy to migrate your project from packages.config to PackageReference. See this guide.

alexschrod

How did this get so little attention? This is so brilliant. I was just setting up automatic builds on GitHub Actions for my Rimworld mod earlier, and I was contemplating how to do so without having to upload the Rimworld binaries anywhere, and then this gem comes up in my searches and totally saves the day!

Thank you so much for making this NuGet package, krafs; it's really appreicated!

botlord

Quote from: alexschrod on April 01, 2021, 05:24:12 AM
How did this get so little attention? This is so brilliant. I was just setting up automatic builds on GitHub Actions for my Rimworld mod earlier, and I was contemplating how to do so without having to upload the Rimworld binaries anywhere, and then this gem comes up in my searches and totally saves the day!

Thank you so much for making this NuGet package, krafs; it's really appreicated!

You may be interested in RimCI then, another project Krafs made that integrates GitHub actions.