From 9841aa145d6f8ffe136b055d41361d451fb4387b Mon Sep 17 00:00:00 2001 From: lutepickle <28810-lutepickle@users.noreply.gitgud.io> Date: Wed, 31 Aug 2022 15:17:48 -0700 Subject: [PATCH] Null check pregnancy in PregnantAction --- .../RJW_Menstruation/HediffComps/HediffComp_Menstruation.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/1.3/source/RJW_Menstruation/RJW_Menstruation/HediffComps/HediffComp_Menstruation.cs b/1.3/source/RJW_Menstruation/RJW_Menstruation/HediffComps/HediffComp_Menstruation.cs index ad93d99..d032122 100644 --- a/1.3/source/RJW_Menstruation/RJW_Menstruation/HediffComps/HediffComp_Menstruation.cs +++ b/1.3/source/RJW_Menstruation/RJW_Menstruation/HediffComps/HediffComp_Menstruation.cs @@ -1509,7 +1509,7 @@ namespace RJW_Menstruation Implant(); } - if (Pawn.health.hediffSet.hediffs.Contains(pregnancy)) + if (pregnancy != null && Pawn.health.hediffSet.hediffs.Contains(pregnancy)) { curStageHrs += 1; StayCurrentStageConst(Stage.Pregnant);