diff --git a/About/About.xml b/About/About.xml index 17adb140..e15798c6 100644 --- a/About/About.xml +++ b/About/About.xml @@ -3,7 +3,7 @@ Prison Labor Avius 1.0.0 - Version 0.9.8 + Version 0.9.9 This mod force prisoners to work. To enable this feature prisoners must have "Force to work" option checked ("Prisoner" tab). Prison labor needs management that consist: - Motivation - prisoners need to be motivated by presence of colonists. Wardens have new job - supervising prisoners. Low motivation can lead to revolts. diff --git a/Assemblies/PrisonLabor.dll b/Assemblies/PrisonLabor.dll index dd6c898b..aa1e0a13 100644 Binary files a/Assemblies/PrisonLabor.dll and b/Assemblies/PrisonLabor.dll differ diff --git a/Languages/English/Keyed/Keys.xml b/Languages/English/Keyed/Keys.xml index daf4a104..5814442b 100644 --- a/Languages/English/Keyed/Keys.xml +++ b/Languages/English/Keyed/Keys.xml @@ -49,4 +49,8 @@ When enabled revolts will sometimes occur instead of vanilla incidents Labor area isn't required to make prisoners work.\n\nThis area forbids colonists from working.\n\nIt's for situations where you don't want colonists to work in certain area. Prisoners will work anywhere they can enter. Don't show again + + Everyone + Colonists + Prisoners diff --git a/README.md b/README.md index fc80e35c..a823f732 100644 --- a/README.md +++ b/README.md @@ -3,7 +3,7 @@

- v0.9.8 + v0.9.9

diff --git a/Source/HarmonyPatches/Patch_RenamePrisoners.cs b/Source/HarmonyPatches/Patch_RenamePrisoners.cs index 91fc4b97..f9eed890 100644 --- a/Source/HarmonyPatches/Patch_RenamePrisoners.cs +++ b/Source/HarmonyPatches/Patch_RenamePrisoners.cs @@ -56,7 +56,7 @@ static IEnumerable Transpiler(ILGenerator gen, MethodBase mBase foreach (var instr in instructions) { - if (HPatcher.IsFragment(opCodes, operands, instr, ref step, nameof(Patch_RenamePrisoners) + nameof(EnableRenamingPrisoners), true)) + if (HPatcher.IsFragment(opCodes, operands, instr, ref step, nameof(Patch_RenamePrisoners) + nameof(EnableRenamingPrisoners))) { yield return new CodeInstruction(OpCodes.Call, typeof(EnableRenamingPrisoners).GetMethod(nameof(IsColonistOrPrisonerOfColony))); } diff --git a/Source/NewsDialog.cs b/Source/NewsDialog.cs index 74c1fc78..db0c76c5 100644 --- a/Source/NewsDialog.cs +++ b/Source/NewsDialog.cs @@ -29,6 +29,7 @@ internal class NewsDialog : Window public static bool news_0_9_0 = false; public static bool news_0_9_1 = false; public static bool news_0_9_2 = false; + public static bool news_0_9_9 = false; // Fields private string[] titles; @@ -53,7 +54,85 @@ public void Init() // [img] ... [/img] for image (inside name of file) // [gap] for gap - // TODO 0.9.3 + // 0.9.9 + if (news_0_9_9 || showAll) + { + titlesList.Add("Prison Labor Beta v0.9.8"); + string[] itemsArray = + { + "added sub-tabs in \"Work\" Tab and \"Assign\" Tab for \"Colonists\" and \"Prisoners\"", + "added renaming Prisoners for imprisonment time (pawns will restore old names after releasing)", + }; + itemsList.Add(itemsArray); + } + + // 0.9.8 + if (showAll) + { + titlesList.Add("Prison Labor Beta v0.9.8"); + string[] itemsArray = + { + "fixed SeedsPlease compatibility", + }; + itemsList.Add(itemsArray); + } + + // 0.9.7 + if (showAll) + { + titlesList.Add("Prison Labor Beta v0.9.7"); + string[] itemsArray = + { + "added warning message before placing labor area for the first time", + }; + itemsList.Add(itemsArray); + } + + // 0.9.6 + if (showAll) + { + titlesList.Add("Prison Labor Beta v0.9.6"); + string[] itemsArray = + { + "updated to RimWorld 1.0", + }; + itemsList.Add(itemsArray); + } + + // 0.9.5 + if (showAll) + { + titlesList.Add("Prison Labor Beta v0.9.5"); + string[] itemsArray = + { + "updated to RimWorld Beta 19", + }; + itemsList.Add(itemsArray); + } + + // 0.9.4 + if (showAll) + { + titlesList.Add("Prison Labor Beta v0.9.4"); + string[] itemsArray = + { + "disabled Warden and Jailor types of work for prisoner labor, it should fix bug, where jailors do not warden inside labor area", + }; + itemsList.Add(itemsArray); + } + + // 0.9.3 + if (showAll) + { + titlesList.Add("Prison Labor Beta v0.9.3"); + string[] itemsArray = + { + "fixed compatibility with No Water no Life", + "fixed compatibility with Dubs Bad Hygiene Mod", + "fixed error with loading old saves", + }; + itemsList.Add(itemsArray); + } // 0.9.2 if (news_0_9_2 || showAll) diff --git a/Source/PrefsData.cs b/Source/PrefsData.cs index d2f67853..9e1647a2 100644 --- a/Source/PrefsData.cs +++ b/Source/PrefsData.cs @@ -63,7 +63,8 @@ public enum Version v0_9_4, v0_9_5, v0_9_6, - v0_9_8 + v0_9_8, + v0_9_9 } [Flags] diff --git a/Source/PrisonLabor.csproj b/Source/PrisonLabor.csproj index 1e44d9dc..6ff08e1d 100644 --- a/Source/PrisonLabor.csproj +++ b/Source/PrisonLabor.csproj @@ -88,7 +88,6 @@ - diff --git a/Source/VersionUtility.cs b/Source/VersionUtility.cs index 33df0320..e047532b 100644 --- a/Source/VersionUtility.cs +++ b/Source/VersionUtility.cs @@ -8,8 +8,8 @@ namespace PrisonLabor { class VersionUtility { - public const Version versionNumber = Version.v0_9_8; - public const string versionString = "0.9.8"; + public const Version versionNumber = Version.v0_9_9; + public const string versionString = "0.9.9"; public static void CheckVersion() { @@ -79,6 +79,11 @@ public static void CheckVersion() { CompatibilityPatches.OlderVersions.Pre_v0_9_4(); } + if (PrisonLaborPrefs.LastVersion < Version.v0_9_9) + { + NewsDialog.news_0_9_9 = true; + NewsDialog.autoShow = true; + } PrisonLaborPrefs.Version = versionNumber; PrisonLaborPrefs.Save(); diff --git a/changelog.txt b/changelog.txt index dbda0283..476e73a5 100644 --- a/changelog.txt +++ b/changelog.txt @@ -22,6 +22,7 @@ Changelog: - fixed blurred effect on settings window 0.9.9 - added sub-tabs in "Work" Tab and "Assign" Tab for "Colonists" and "Prisoners" +- added renaming Prisoners for imprisonment time (pawns will restore old names after releasing) 0.9.8 - fixed SeedsPlease compatibility 0.9.7