Run from the repository root:
dotnet build Source/CameraPlus.csproj -c ReleaseThe current project has no automated test project. Treat a clean build as the minimum check, then use in-game validation for camera, marker, label, and compatibility changes.
Release builds write:
1.6/Assemblies/CameraPlus.dll
The project also has a CopyToRimworld MSBuild target that runs when RIMWORLD_MOD_DIR is set. That target:
- deletes
1.6/Assemblies/0Harmony.dll. - copies version folders, metadata, defs, languages, resources, sounds, textures, license, load folders, README, and README image assets into
$(RIMWORLD_MOD_DIR)\CameraPlus. - zips that copied mod folder as
$(RIMWORLD_MOD_DIR)\CameraPlus.zip.
On macOS with a Unix shell, MSBuild still prints Windows-style path separators in the target body because the project file uses backslashes.
During this prep pass on 2026-05-15:
- The project was pinned to
Krafs.Rimworld.Ref1.6.4518. - NuGet reported
1.6.4633as the latest stable package. - NuGet's flat-container index listed
1.6.4817-betaas the latest package overall. - The project was updated to
Krafs.Rimworld.Ref1.6.4817-betato compile against the newest known RimWorld 1.6 API surface before the larger review. dotnet build Source/CameraPlus.csproj -c Releasesucceeded after the update.
Primary package source:
https://www.nuget.org/packages/Krafs.Rimworld.Refhttps://api.nuget.org/v3-flatcontainer/krafs.rimworld.ref/index.json
Current top-level package references in Source/CameraPlus.csproj:
Brrainz.RimWorld.CrossPromotion1.1.2Krafs.Rimworld.Ref1.6.4817-betaLib.Harmony2.3.6, withExcludeAssets="runtime"Microsoft.NETCore.Platforms7.0.4Microsoft.NETFramework.ReferenceAssemblies.net4721.0.3TaskPubliciser1.0.3
Lib.Harmony is a compile-time package here. The runtime Harmony dependency is provided by the RimWorld Harmony mod declared in About/About.xml.
Source/CameraPlus.csproj contains two custom targets:
MyCode, beforeUpdateReferences, publicises$(PkgKrafs_Rimworld_Ref)\ref\net472\Assembly-CSharp.dllintoAssembly-CSharp_publicised.dll, then adds the publicised assembly as a reference.UpdateReferences, afterResolveLockFileReferences, removes the original non-publicisedAssembly-CSharp.dllreference.
This is central to the codebase. Many patches and helpers access non-public RimWorld members through the publicised assembly.
Directory.Build.props owns:
ModNameModFileNameRepositoryModVersionProjectGuid
The PostBuildAction target writes ModVersion into:
About/About.xmlat//ModMetaData/modVersionAbout/Manifest.xmlat//Manifest/version
RimWorld loads common content from the root and per-version assemblies through LoadFolders.xml.
Important payload directories:
About: RimWorld metadata, manifest, preview, Steam id.Defs: sound defs for snapback.Languages: keyed translations for settings and marker tags.Textures: marker/editor UI textures loaded throughContentFinder.Sounds: snapback audio clips.Resources: platform-specific Unity asset bundles.