https://github.com/pardeike/rimworld-modfeatures
Shows features and small tutorials in RimWorld mods
https://github.com/pardeike/rimworld-modfeatures
Last synced: about 2 months ago
JSON representation
Shows features and small tutorials in RimWorld mods
- Host: GitHub
- URL: https://github.com/pardeike/rimworld-modfeatures
- Owner: pardeike
- License: mit
- Created: 2023-08-23T03:17:30.000Z (almost 2 years ago)
- Default Branch: master
- Last Pushed: 2024-03-28T22:28:41.000Z (about 1 year ago)
- Last Synced: 2025-03-15T12:17:47.366Z (3 months ago)
- Language: C#
- Size: 516 KB
- Stars: 0
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
Awesome Lists containing this project
README
# RimWorld Mod Features Library
## How to Use
To use ModFeatures, install it at startup with
```cs
using Brrainz;
// install and schedule dialog until a game is started or loaded
ModFeatures.Install(); // 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.mp4For each file, you should have translation strings in your mod in the form of
```xml
Welcome to my mod!
Introduction
```Make sure YourModClass matches the class name that extends `Mod`.
You can also trigger the dialog again by calling
```cs
using Brrainz;// don't call this at startup, only on demand by the user
var showAllFeatures = true;
var unseen = ModFeatures.UnseenFeatures();
if (unseen > 0 || showAllFeatures)
{
ModFeatures.ShowAgain(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
```txt
......\LocalLow\Ludeon Studios\RimWorld by Ludeon Studios\Config\ModFeatures\
```Enjoy
/Brrainz