diff --git a/1.3/Textures/Womb/Womb_Egged.png b/1.3/Textures/Womb/Insect_Egged/Womb_Egged_1.png similarity index 100% rename from 1.3/Textures/Womb/Womb_Egged.png rename to 1.3/Textures/Womb/Insect_Egged/Womb_Egged_1.png diff --git a/1.3/Textures/Womb/Insect_Egged/Womb_Egged_2.png b/1.3/Textures/Womb/Insect_Egged/Womb_Egged_2.png new file mode 100644 index 0000000..e65723d Binary files /dev/null and b/1.3/Textures/Womb/Insect_Egged/Womb_Egged_2.png differ diff --git a/1.3/Textures/Womb/Insect_Egged/Womb_Egged_3.png b/1.3/Textures/Womb/Insect_Egged/Womb_Egged_3.png new file mode 100644 index 0000000..d67f3d0 Binary files /dev/null and b/1.3/Textures/Womb/Insect_Egged/Womb_Egged_3.png differ diff --git a/1.3/Textures/Womb/Insect_Egged/Womb_Egged_Large.png b/1.3/Textures/Womb/Insect_Egged/Womb_Egged_Large.png new file mode 100644 index 0000000..dbf41c1 Binary files /dev/null and b/1.3/Textures/Womb/Insect_Egged/Womb_Egged_Large.png differ diff --git a/1.3/Textures/Womb/Insect_Egged/Womb_Egged_Large_Stretched.png b/1.3/Textures/Womb/Insect_Egged/Womb_Egged_Large_Stretched.png new file mode 100644 index 0000000..8d7f546 Binary files /dev/null and b/1.3/Textures/Womb/Insect_Egged/Womb_Egged_Large_Stretched.png differ diff --git a/1.3/Textures/Womb/Insect_Egged/Womb_Egged_Many.png b/1.3/Textures/Womb/Insect_Egged/Womb_Egged_Many.png new file mode 100644 index 0000000..2665259 Binary files /dev/null and b/1.3/Textures/Womb/Insect_Egged/Womb_Egged_Many.png differ diff --git a/1.3/Textures/Womb/Insect_Egged/Womb_Egged_Multiple_ManyMixed.png b/1.3/Textures/Womb/Insect_Egged/Womb_Egged_Multiple_ManyMixed.png new file mode 100644 index 0000000..575203e Binary files /dev/null and b/1.3/Textures/Womb/Insect_Egged/Womb_Egged_Multiple_ManyMixed.png differ diff --git a/1.3/source/RJW_Menstruation/RJW_Menstruation/HediffComps/MenstruationUtility.cs b/1.3/source/RJW_Menstruation/RJW_Menstruation/HediffComps/MenstruationUtility.cs index 30ae120..4f85edf 100644 --- a/1.3/source/RJW_Menstruation/RJW_Menstruation/HediffComps/MenstruationUtility.cs +++ b/1.3/source/RJW_Menstruation/RJW_Menstruation/HediffComps/MenstruationUtility.cs @@ -123,7 +123,7 @@ namespace RJW_Menstruation { for (int i = babycount; i > 1; i--) { - Texture2D result = ContentFinder.Get((path + "_Multiplet_" + i), false); + Texture2D result = ContentFinder.Get(path + "_Multiplet_" + i, false); if (result != null) return result; } return null; @@ -155,14 +155,30 @@ namespace RJW_Menstruation Texture2D cumtex = ContentFinder.Get((icon), true); return cumtex; } + public static Texture2D GetInsectEggedIcon(this HediffComp_Menstruation comp) + { + List hediffs = comp.Pawn.health.hediffSet.GetHediffs().ToList(); + if (hediffs.NullOrEmpty()) return null; + string path = "Womb/Insect_Egged/"; + if (hediffs.Max(hediff => hediff.eggssize) > 0.3) // The threshold for "large egg" in the debug + { + if (hediffs.Count == 1) return ContentFinder.Get(path + "Womb_Egged_Large", true); + else return ContentFinder.Get(path + "Womb_Egged_ManyMixed", true); + } + Texture2D result = ContentFinder.Get(path + "Womb_Egged_" + hediffs.Count(), false); + if (result == null) result = ContentFinder.Get(path + "Womb_Egged_Many", true); + + return result; + } public static Texture2D GetWombIcon(this HediffComp_Menstruation comp) { - if (comp.Pawn.health.hediffSet.GetHediffs().FirstOrDefault() != null) return ContentFinder.Get(("Womb/Womb_Egged"), true); + Texture2D wombtex = comp.GetInsectEggedIcon(); + if (wombtex != null) return wombtex; string icon = comp.WombTex; HediffComp_Menstruation.Stage stage = comp.curStage; if (stage == HediffComp_Menstruation.Stage.Bleeding) icon += "_Bleeding"; - Texture2D wombtex = ContentFinder.Get((icon), true); + wombtex = ContentFinder.Get(icon, true); return wombtex; } diff --git a/changelogs.txt b/changelogs.txt index 3303d80..090e8fc 100644 --- a/changelogs.txt +++ b/changelogs.txt @@ -1,6 +1,7 @@ Version 1.0.7.3 - Properly display multiple icons for pawns with multiple wombs. - Show the 'about to ovulate' icon in the womb dialog for induced ovulators during vaginal sex. + - Display more insect eggs in a womb when someone has more, with new graphics by Euldrop. Version 1.0.7.2 - Fix errors when trying to open dev actions when HAR is not installed.