diff --git a/1.4/Assemblies/Vampire.dll b/1.4/Assemblies/Vampire.dll index bc4c7d2..22de963 100644 Binary files a/1.4/Assemblies/Vampire.dll and b/1.4/Assemblies/Vampire.dll differ diff --git a/Source/Code/HarmonyPatches/HarmonyPatches.cs b/Source/Code/HarmonyPatches/HarmonyPatches.cs index ca4b5f9..7aa9f99 100644 --- a/Source/Code/HarmonyPatches/HarmonyPatches.cs +++ b/Source/Code/HarmonyPatches/HarmonyPatches.cs @@ -10,8 +10,10 @@ static partial class HarmonyPatches static HarmonyPatches() { - var harmony = new Harmony("rimworld.jecrell.vampire"); + Harmony.DEBUG = false; + var harmony = new Harmony("rimworld.jecrell.vampire"); + HarmonyPatches_Needs(harmony); HarmonyPatches_Ingestion(harmony); diff --git a/Source/Code/HarmonyPatches/HarmonyPatches_Ingestion.cs b/Source/Code/HarmonyPatches/HarmonyPatches_Ingestion.cs index d5f7bdc..39242a3 100644 --- a/Source/Code/HarmonyPatches/HarmonyPatches_Ingestion.cs +++ b/Source/Code/HarmonyPatches/HarmonyPatches_Ingestion.cs @@ -11,43 +11,47 @@ public partial class HarmonyPatches { public static void HarmonyPatches_Ingestion(Harmony harmony) { + //Log.Message("Ingestion: 1"); //Float Menus: Adds vampire blood consumption/consume buttons and hide regular consumption/consume harmony.Patch(AccessTools.Method(typeof(FloatMenuMakerMap), "AddHumanlikeOrders"), null, new HarmonyMethod(typeof(HarmonyPatches), nameof(Vamp_FloatMenus_Consume))); - + //Log.Message("Ingestion: 2"); //Vampires should not try to do drugs when idle. harmony.Patch(AccessTools.Method(typeof(JobGiver_IdleJoy), "TryGiveJob"), null, new HarmonyMethod(typeof(HarmonyPatches), nameof(Vamps_DontDoIdleDrugs))); - + //Log.Message("Ingestion: 3"); //Vampires should not be given food by wardens. harmony.Patch(AccessTools.Method(typeof(Pawn_GuestTracker), "get_CanBeBroughtFood"), null, new HarmonyMethod(typeof(HarmonyPatches), nameof(Vamps_DontWantGuestFood))); - + //Log.Message("Ingestion: 4"); harmony.Patch(AccessTools.Method(typeof(FoodUtility), "InappropriateForTitle"), new HarmonyMethod(typeof(HarmonyPatches), nameof(WhoNeeds___Titles))); + //Log.Message("Ingestion: 5"); harmony.Patch( AccessTools.Method(typeof(FoodUtility), "WillEat", - new[] { typeof(Pawn), typeof(Thing), typeof(Pawn), typeof(bool) }), + new[] { typeof(Pawn), typeof(Thing), typeof(Pawn), typeof(bool), typeof(bool) }), new HarmonyMethod(typeof(HarmonyPatches), nameof(WillEat_Nothing))); + //Log.Message("Ingestion: 6"); harmony.Patch( AccessTools.Method(typeof(FoodUtility), "WillEat", - new[] { typeof(Pawn), typeof(ThingDef), typeof(Pawn), typeof(bool) }), + new[] { typeof(Pawn), typeof(ThingDef), typeof(Pawn), typeof(bool), typeof(bool) }), new HarmonyMethod(typeof(HarmonyPatches), nameof(WillEat_NothingDef))); - + //Log.Message("Ingestion: 7"); harmony.Patch(AccessTools.Method(typeof(Toils_Ingest), "FinalizeIngest"), new HarmonyMethod(typeof(HarmonyPatches), nameof(VampiresDontIngestFood))); - + //Log.Message("Ingestion: 8"); //Fixes random red errors relating to food need checks in this method (WillIngestStackCountOf). harmony.Patch(AccessTools.Method(typeof(FoodUtility), "WillIngestStackCountOf"), new HarmonyMethod(typeof(HarmonyPatches), nameof(Vamp_WillIngestStackCountOf))); - //Log.Message("04"); + + //Log.Message("Ingestion: 9"); //Prevents restful times. harmony.Patch(AccessTools.Method(typeof(JoyGiver_SocialRelax), "TryFindIngestibleToNurse"), new HarmonyMethod(typeof(HarmonyPatches), nameof(INeverDrink___Wine))); @@ -120,7 +124,7 @@ public static bool WhoNeeds___Titles(ThingDef food, Pawn p, bool allowIfStarving // RimWorld.FoodUtility.WillEat (Thing) - public static bool WillEat_Nothing(Pawn p, Thing food, Pawn getter, bool careIfNotAcceptableForTitle, + public static bool WillEat_Nothing(Pawn p, Thing food, Pawn getter, bool careIfNotAcceptableForTitle, bool allowVenerated, ref bool __result) { if (p.IsVampire(true)) @@ -140,7 +144,7 @@ public static bool WillEat_Nothing(Pawn p, Thing food, Pawn getter, bool careIfN // RimWorld.FoodUtility.WillEat (ThingDef) - public static bool WillEat_NothingDef(Pawn p, ThingDef food, Pawn getter, bool careIfNotAcceptableForTitle, + public static bool WillEat_NothingDef(Pawn p, ThingDef food, Pawn getter, bool careIfNotAcceptableForTitle, bool allowVenerated, ref bool __result) { if (p.IsVampire(true)) diff --git a/Source/Directory.Build.props b/Source/Directory.Build.props index d482c65..9e9eec2 100644 --- a/Source/Directory.Build.props +++ b/Source/Directory.Build.props @@ -64,6 +64,48 @@ + + + ..\1.4\Assemblies\ + + + + + + + + + + + + + + ..\..\..\..\..\workshop\content\294100\836308268\1.4\Assemblies\BadHygiene.dll + false + + + + + ..\..\JecsTools\1.4\Assemblies\0JecsTools.dll + false + + + + ..\..\JecsTools\1.4\Assemblies\AbilityUser.dll + false + + + + ..\..\JecsTools\1.4\Assemblies\CompAnimated.dll + false + + + + diff --git a/Source/Vampire.sln b/Source/Vampire.sln index a16d53f..4810c91 100644 --- a/Source/Vampire.sln +++ b/Source/Vampire.sln @@ -11,10 +11,13 @@ Global Release|Any CPU = Release|Any CPU RW1.3|Any CPU = RW1.3|Any CPU RW1.4|Any CPU = RW1.4|Any CPU + RW1.4Unstable|Any CPU = RW1.4Unstable|Any CPU EndGlobalSection GlobalSection(ProjectConfigurationPlatforms) = postSolution - {3A4FB893-1148-4E16-B548-867647DF1724}.RW1.4|Any CPU.ActiveCfg = RW1.4|Any CPU - {3A4FB893-1148-4E16-B548-867647DF1724}.RW1.4|Any CPU.Build.0 = RW1.4|Any CPU + {3A4FB893-1148-4E16-B548-867647DF1724}.RW1.4|Any CPU.ActiveCfg = RW1.4Unstable|Any CPU + {3A4FB893-1148-4E16-B548-867647DF1724}.RW1.4|Any CPU.Build.0 = RW1.4Unstable|Any CPU + {3A4FB893-1148-4E16-B548-867647DF1724}.RW1.4Unstable|Any CPU.ActiveCfg = RW1.4Unstable|Any CPU + {3A4FB893-1148-4E16-B548-867647DF1724}.RW1.4Unstable|Any CPU.Build.0 = RW1.4Unstable|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE diff --git a/updateinfo b/updateinfo index 2e53c01..3527e38 100644 --- a/updateinfo +++ b/updateinfo @@ -3,14 +3,14 @@ ============================== Rim of Madness - Vampires Update -v1.27.0.0 (08-08-2022) +v1.28.0.0 (10-29-2022) ==================== -Meditation has been fixed. Vampire fangs now are added hediffs on tongues due to an underlying RimWorld issue that removes tongues if jaws are modified. Existing saves will have fangs moved to the new position. New settings for sun damage and rest added +Updates for RimWorld 1.4; Fixes bed coffin coloration issues; Neck wounds are cleaned after biting -------------------- Download now on... -- Patreon: https://www.patreon.com/posts/rim-of-madness-1-54281813 +- Patreon: https://www.patreon.com/posts/73953554 - GitHub: https://github.com/Rim-Of-Madness-Team/Rim-of-Madness---Vampires - Steam: https://steamcommunity.com/sharedfiles/filedetails/?id=1187010034 Discuss the mod on... @@ -25,12 +25,12 @@ Discuss the mod on... [img width=260]https://raw.githubusercontent.com/Rim-Of-Madness-Team/Rim-of-Madness---Vampires/master/About/Preview.png[/img] [hr] [b]Rim of Madness - Vampires -Version: 1.27.0.0 -Updated: 08-08-2022 -Description: [color=orange]Meditation has been fixed. Vampire fangs now are added hediffs on tongues due to an underlying RimWorld issue that removes tongues if jaws are modified. Existing saves will have fangs moved to the new position. New settings for sun damage and rest added[/color] +Version: 1.28.0.0 +Updated: 10-29-2022 +Description: [color=orange]Updates for RimWorld 1.4; Fixes bed coffin coloration issues; Neck wounds are cleaned after biting[/color] [hr] [b]Download now on...[/b] -[url=https://www.patreon.com/posts/rim-of-madness-1-54281813]Patreon[/url] +[url=https://www.patreon.com/posts/73953554]Patreon[/url] [url=https://github.com/Rim-Of-Madness-Team/Rim-of-Madness---Vampires]GitHub[/url] [url=https://steamcommunity.com/sharedfiles/filedetails/?id=1187010034]Steam[/url] [b]Discuss the mod on...[/b]