Hide implanted eggs for hidden fetuses

This commit is contained in:
lutepickle 2022-09-29 09:34:30 -07:00
parent b83b15569b
commit b174820e50
3 changed files with 6 additions and 8 deletions

Binary file not shown.

View File

@ -185,13 +185,7 @@ namespace RJW_Menstruation
} }
public static Texture2D GetEggIcon(this HediffComp_Menstruation comp, bool includeOvary) public static Texture2D GetEggIcon(this HediffComp_Menstruation comp, bool includeOvary)
{ {
if (comp.Pregnancy != null && !(comp.Pregnancy is Hediff_MechanoidPregnancy)) switch (comp.CurrentVisibleStage)
{
if (comp.GetPregnancyProgress() < 0.2f) return ContentFinder<Texture2D>.Get("Eggs/Egg_Implanted00", true);
else return ContentFinder<Texture2D>.Get("Womb/Empty", true);
}
switch (comp.curStage)
{ {
case HediffComp_Menstruation.Stage.Follicular: case HediffComp_Menstruation.Stage.Follicular:
case HediffComp_Menstruation.Stage.ClimactericFollicular: case HediffComp_Menstruation.Stage.ClimactericFollicular:
@ -230,9 +224,12 @@ namespace RJW_Menstruation
return ContentFinder<Texture2D>.Get("Eggs/Egg_Fertilizing01", true); return ContentFinder<Texture2D>.Get("Eggs/Egg_Fertilizing01", true);
} }
else return ContentFinder<Texture2D>.Get("Eggs/Egg", true); else return ContentFinder<Texture2D>.Get("Eggs/Egg", true);
case HediffComp_Menstruation.Stage.Pregnant:
if (comp.Pregnancy is Hediff_MechanoidPregnancy) break;
else if (comp.GetPregnancyProgress() < 0.2f) return ContentFinder<Texture2D>.Get("Eggs/Egg_Implanted00", true);
else break;
} }
return ContentFinder<Texture2D>.Get("Womb/Empty", true); return ContentFinder<Texture2D>.Get("Womb/Empty", true);
} }
public static void DrawEggOverlay(this HediffComp_Menstruation comp, Rect wombRect, bool includeOvary) public static void DrawEggOverlay(this HediffComp_Menstruation comp, Rect wombRect, bool includeOvary)

View File

@ -5,6 +5,7 @@ Version 1.0.7.5
- Fix error after the game is loaded with an NPC in estrus off-map. - Fix error after the game is loaded with an NPC in estrus off-map.
- Fix udders not appearing in the womb dialog with RJW 5.2.2. - Fix udders not appearing in the womb dialog with RJW 5.2.2.
- Fix missing texture error when insect egged with multiple sizes. - Fix missing texture error when insect egged with multiple sizes.
- Don't show an implanted egg if the fetus is supposed to be hidden.
- Properly calculate cramp pain falloff again. - Properly calculate cramp pain falloff again.
- Climacteric and menopause are now per-womb, appearing in the womb dialog instead of as hediffs. Any old hediffs should disappear upon loading the save. - Climacteric and menopause are now per-womb, appearing in the womb dialog instead of as hediffs. Any old hediffs should disappear upon loading the save.
- Added new property to vaginas to multiply the number of eggs available. Archotech vaginas will have quadruple the normal amount. - Added new property to vaginas to multiply the number of eggs available. Archotech vaginas will have quadruple the normal amount.