Brrainz.RimWorld.ModFeatures 1.2.3

There is a newer version of this package available.
See the version list below for details.
dotnet add package Brrainz.RimWorld.ModFeatures --version 1.2.3
NuGet\Install-Package Brrainz.RimWorld.ModFeatures -Version 1.2.3
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="Brrainz.RimWorld.ModFeatures" Version="1.2.3" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Brrainz.RimWorld.ModFeatures --version 1.2.3
#r "nuget: Brrainz.RimWorld.ModFeatures, 1.2.3"
#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.
// Install Brrainz.RimWorld.ModFeatures as a Cake Addin
#addin nuget:?package=Brrainz.RimWorld.ModFeatures&version=1.2.3

// Install Brrainz.RimWorld.ModFeatures as a Cake Tool
#tool nuget:?package=Brrainz.RimWorld.ModFeatures&version=1.2.3

RimWorld Mod Features Library

How to Use

To use ModFeatures, install it at startup with

using Brrainz;
// install and schedule dialog until a game is started or loaded
ModFeatures.Install<YourModClass>();  // YourModClass is the class extending 'Mod'

and create a folder called Features in your mod root (same level as About). Put .png and .mp4 files into that folder and name them nn_title.xxx. For example:

  • 01_Welcome.png
  • 02_Introduction.mp4
  • 03_Stuff.png
  • 04_MoreStuff.mp4

For each file, you should have translation strings in your mod in the form of

<Feature_YourModClass_Welcome>Welcome to my mod!</Feature_YourModClass_Welcome>
<Feature_YourModClass_Introduction>Introduction</Feature_YourModClass_Introduction>

Make sure YourModClass matches the class name that extends Mod.

You can also trigger the dialog again by calling

using Brrainz;

// don't call this at startup, only on demand by the user
var showAllFeatures = true;
var unseen = ModFeatures.UnseenFeatures<YourModClass>();
if (unseen > 0 || showAllFeatures)
{
   ModFeatures.ShowAgain<YourModClass>(showAllFeatures);
}

That's it. You will automatically get a feature dialog displayed when the player starts or loads a game. The user can remove topics and the preferences for that are stored in

......\LocalLow\Ludeon Studios\RimWorld by Ludeon Studios\Config\ModFeatures\

Enjoy /Brrainz

Product Compatible and additional computed target framework versions.
.NET Framework net472 is compatible.  net48 was computed.  net481 was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

This package has 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
1.2.5 100 3/16/2024
1.2.4 285 9/1/2023
1.2.3 291 8/29/2023
1.2.2 286 8/29/2023
1.2.1 278 8/28/2023
1.2.0 297 8/24/2023
1.1.1 271 8/24/2023
1.1.0 260 8/24/2023
1.0.1 285 8/24/2023
1.0.0 294 8/23/2023

Initial release