diff --git a/Assemblies/Vampire.dll b/Assemblies/Vampire.dll index 08afe87..6d4e706 100644 Binary files a/Assemblies/Vampire.dll and b/Assemblies/Vampire.dll differ diff --git a/Languages/English/Keyed/EngROMV.xml b/Languages/English/Keyed/EngROMV.xml index 19a7d33..4787c4d 100644 --- a/Languages/English/Keyed/EngROMV.xml +++ b/Languages/English/Keyed/EngROMV.xml @@ -1,6 +1,9 @@ + +DEADLY + Powerful Vampire {0} is a {1} generation vampire. Powerful vampires tend to be extra dangerous, so tread lightly. diff --git a/Source/Vampires/Utilities/BloodItemUtility.cs b/Source/Vampires/Utilities/BloodItemUtility.cs index cb78f8a..160146f 100644 --- a/Source/Vampires/Utilities/BloodItemUtility.cs +++ b/Source/Vampires/Utilities/BloodItemUtility.cs @@ -10,7 +10,7 @@ public static class BloodItemUtility public static bool ExtractionWillKill(Pawn extractee, bool isBloodPack = false) { int amt = isBloodPack ? AMT_BLOODPACK : AMT_BLOODVIAL; - if (extractee?.BloodNeed()?.CurBloodPoints <= amt) + if (extractee?.BloodNeed() is Need_Blood bn && (bn.CurBloodPoints <= amt || bn.DrainingIsDeadly)) return true; return false; } diff --git a/Source/Vampires/Workers/Recipe_ExtractBloodPack.cs b/Source/Vampires/Workers/Recipe_ExtractBloodPack.cs index 8711b36..432764b 100644 --- a/Source/Vampires/Workers/Recipe_ExtractBloodPack.cs +++ b/Source/Vampires/Workers/Recipe_ExtractBloodPack.cs @@ -22,7 +22,7 @@ public override IEnumerable GetPartsToApplyOn(Pawn pawn, RecipeD public override bool IsViolationOnPawn(Pawn pawn, BodyPartRecord part, Faction billDoerFaction) { - if (BloodItemUtility.ExtractionWillKill(pawn)) + if (BloodItemUtility.ExtractionWillKill(pawn, true)) { Messages.Message("ROMV_DeadlyOperation".Translate(pawn.Label), MessageTypeDefOf.NegativeEvent); } @@ -77,7 +77,7 @@ public override void ApplyOnPawn(Pawn pawn, BodyPartRecord part, Pawn billDoer, public override string GetLabelWhenUsedOn(Pawn pawn, BodyPartRecord part) { - return recipe.LabelCap + " (" + BloodTypeUtility.BloodType(pawn).GetLabel() + ")"; + return recipe.LabelCap + " (" + BloodTypeUtility.BloodType(pawn).GetLabel() + ")" + ((BloodItemUtility.ExtractionWillKill(pawn, true)) ? " (" + "ROMV_DeadlyOperationShort".Translate() + ")" : ""); } } } diff --git a/Source/Vampires/Workers/Recipe_ExtractBloodVial.cs b/Source/Vampires/Workers/Recipe_ExtractBloodVial.cs index edb8bd5..af53ad9 100644 --- a/Source/Vampires/Workers/Recipe_ExtractBloodVial.cs +++ b/Source/Vampires/Workers/Recipe_ExtractBloodVial.cs @@ -75,7 +75,7 @@ public override void ApplyOnPawn(Pawn pawn, BodyPartRecord part, Pawn billDoer, public override string GetLabelWhenUsedOn(Pawn pawn, BodyPartRecord part) { - return recipe.LabelCap + " (" + BloodTypeUtility.BloodType(pawn).GetLabel() + ")"; + return recipe.LabelCap + " (" + BloodTypeUtility.BloodType(pawn).GetLabel() + ")" + ((BloodItemUtility.ExtractionWillKill(pawn)) ? " (" + "ROMV_DeadlyOperationShort".Translate() + ")" : ""); } } }