Install Steam
login
|
language
简体中文 (Simplified Chinese)
繁體中文 (Traditional Chinese)
日本語 (Japanese)
한국어 (Korean)
ไทย (Thai)
Български (Bulgarian)
Čeština (Czech)
Dansk (Danish)
Deutsch (German)
Español - España (Spanish - Spain)
Español - Latinoamérica (Spanish - Latin America)
Ελληνικά (Greek)
Français (French)
Italiano (Italian)
Bahasa Indonesia (Indonesian)
Magyar (Hungarian)
Nederlands (Dutch)
Norsk (Norwegian)
Polski (Polish)
Português (Portuguese - Portugal)
Português - Brasil (Portuguese - Brazil)
Română (Romanian)
Русский (Russian)
Suomi (Finnish)
Svenska (Swedish)
Türkçe (Turkish)
Tiếng Việt (Vietnamese)
Українська (Ukrainian)
Report a translation problem
https://ludeon.com/forums/index.php?topic=37177.msg382039#msg382039
ReColor Stockpile & Growing Zones
Preset Filtered Zones
hope you-ll implement Harony soon :-)
thanks Kiame for jumping in!
If you want to see examples of how to use it most of my mods use harmony. One that's close to what you're doing is: https://github.com/KiameV/rimworld-SaveStorageSettings/blob/master/Source/Main.cs
Harmony Prefix is called before a method. Postfix is called after. A method can have both. Prefix can be either a void or boolean return. In the bool case returning false prevents any other Prefixes from running and also prevents the method being Prefixed from being called (a true override)
[HarmonyPatch(typeof(Zone_Stockpile), "GetGizmos")]
static class Patch_Zone_GetGizmos
{
static void Postfix(Zone_Stockpile __instance, ref IEnumerable<Gizmo> __result)
{
__result = GizmoUtil.AddSaveLoadGizmos(__result, "Zone_Stockpile", __instance.settings.filter);
}
}
In this example it's using GizmoUtil to add the new buttons to the list. GizmoUtil is here for reference too: https://github.com/KiameV/rimworld-SaveStorageSettings/blob/master/Source/GizmoUtil.cs