mirror of
https://gitgud.io/lutepickle/rjw_menstruation.git
synced 2024-08-14 22:46:52 +00:00
Add some debug logging around the pregnancy to labor transition
This commit is contained in:
parent
ca895ef296
commit
b28beb8eaa
2 changed files with 5 additions and 0 deletions
Binary file not shown.
|
@ -26,8 +26,10 @@ namespace RJW_Menstruation
|
|||
public static void Postfix(Hediff_Pregnant __instance)
|
||||
{
|
||||
HediffComp_Menstruation comp = __instance.GetMenstruationCompFromPregnancy();
|
||||
if (Configurations.Debug) Log.Message($"{comp.Pawn}'s labor starting, menstruation comp is {comp}");
|
||||
if (comp == null) return;
|
||||
comp.Pregnancy = __instance.pawn.health.hediffSet.GetFirstHediffOfDef(HediffDefOf.PregnancyLabor);
|
||||
if (Configurations.Debug) Log.Message($"New pregnancy Hediff is {comp.Pregnancy}");
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -37,8 +39,10 @@ namespace RJW_Menstruation
|
|||
public static void PostFix(Hediff_Labor __instance)
|
||||
{
|
||||
HediffComp_Menstruation comp = __instance.GetMenstruationCompFromPregnancy();
|
||||
if (Configurations.Debug) Log.Message($"{comp.Pawn}'s initial labor ending, menstruation comp is {comp}");
|
||||
if (comp == null) return;
|
||||
comp.Pregnancy = __instance.pawn.health.hediffSet.GetFirstHediffOfDef(HediffDefOf.PregnancyLaborPushing);
|
||||
if (Configurations.Debug) Log.Message($"New pregnancy Hediff is {comp.Pregnancy}");
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -48,6 +52,7 @@ namespace RJW_Menstruation
|
|||
public static void PostFix(Hediff_LaborPushing __instance)
|
||||
{
|
||||
HediffComp_Menstruation comp = __instance.GetMenstruationCompFromPregnancy();
|
||||
if (Configurations.Debug) Log.Message($"{comp.Pawn}'s labor pushing ending, menstruation comp is {comp}");
|
||||
if (comp == null) return;
|
||||
comp.Pregnancy = null;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue