diff --git a/CHANGELOG.md b/CHANGELOG.md
index 3852765..629613f 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -23,7 +23,15 @@
- Issues with Elasticity References (#87)
- Null Pointer for LoveFeeding when finding Mechs. Thanks to @Jaaldabaoth (Fixes #90)
- Changes to the Implants introduced in 2.0.0 - they imposed a hidden dependency on Royalty (Fixes #89)
-
+- Issues when generating relations (#98, fixed in #106 thanks @Jaaldabaoth)
+- Hardening of Licentia Dependencies (#105)
+- Littered Birth and Chest-Burst Pregnancy are now mutually exclusive (#96)
+- Youth Fountain cannot youth on masturbation anymore (#99)
+- Documented the HasActiveGene Error Message (#104)
+- Pawns with "rjw_genes_no_sexneed" wont go raping (or atleast way less, #100)
+- Extra Nullcheck for Genes in Orgasmic Mytosis (#95)
+- Orgasmic Mytosis Pawns *should* inherit the Xenotypename and favorite colour now
+- Babies should not have "SexChangeThoughts" anymore when they had a (fe)male-only gene (#103)
**Changes**:
@@ -34,6 +42,7 @@
- Translate-Key for Animal Hybrid Race-Names
- "Tick-Speed" for Evergrowth moved from Mod-Settings to XML
- Some new Icons thanks to Kira-Bad-Artist
+- Some new Icons thanks to Archer
# 2.0.0
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index 103a4f5..a7084d8 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -30,4 +30,5 @@ But please consider also the following:
- Cockeater & Naked Prowess come from *WasMachenDennSachen* but I copied it from Discord Chat.
- Fertilin, Fertilin Drain, Healpussy, Succubus Wing & Tail come from Shabakur
- Littered Birth, Many of the Penis Types are from Jaaldabaoth
-- Feline Genitalia, Animal Mating Call and Udder are from Kira-Bad-Artist
\ No newline at end of file
+- Feline Genitalia, Animal Mating Call and Udder are from Kira-Bad-Artist
+- Sexual Tamer, Pheromone Spit and Mating call are from Archer
\ No newline at end of file
diff --git a/Common/Defs/AbilityDefs/Ability_MatingCall.xml b/Common/Defs/AbilityDefs/Ability_MatingCall.xml
index a45fb1d..383895f 100644
--- a/Common/Defs/AbilityDefs/Ability_MatingCall.xml
+++ b/Common/Defs/AbilityDefs/Ability_MatingCall.xml
@@ -5,7 +5,7 @@
rjw_genes_ability_mating_callCalls nearby animals to breed me.
- Genes/Icons/Animal_Mating_Call
+ Genes/Icons/Mating_Call_2truefalse
diff --git a/Common/Defs/AbilityDefs/Ability_PheromoneSpit.xml b/Common/Defs/AbilityDefs/Ability_PheromoneSpit.xml
index 1305665..853a192 100644
--- a/Common/Defs/AbilityDefs/Ability_PheromoneSpit.xml
+++ b/Common/Defs/AbilityDefs/Ability_PheromoneSpit.xml
@@ -4,7 +4,7 @@
rjw_genes_ability_pheromone_spitSpit a condensed ball of animal pheromones to mark a target. Nearby Animals will try to breed the target. This means all animals - hostile, friendly and wild.
- Genes/Icons/Pheromone_Spit
+ Genes/Icons/RJW_Genes_PheromoneSpit3000201
diff --git a/Common/Defs/GeneDefs/GeneDefs_Breeding.xml b/Common/Defs/GeneDefs/GeneDefs_Breeding.xml
index 200af57..1eab617 100644
--- a/Common/Defs/GeneDefs/GeneDefs_Breeding.xml
+++ b/Common/Defs/GeneDefs/GeneDefs_Breeding.xml
@@ -82,7 +82,7 @@
rjw_genes_mating_callThis gene allows to call nearby animals and invite them for mating.
- Genes/Icons/Animal_Mating_Call
+ Genes/Icons/RJW_Genes_Mating_Call65
rjw_genes_ability_mating_call
@@ -99,7 +99,7 @@
rjw_genes_pheromone_spitThis gene allows to mark targets for breeding, enticing nearby animals for a ride.
- Genes/Icons/Pheromone_Spit
+ Genes/Icons/RJW_Genes_PheromoneSpit66
rjw_genes_ability_pheromone_spit
diff --git a/Common/Defs/GeneDefs/GeneDefs_Reproduction.xml b/Common/Defs/GeneDefs/GeneDefs_Reproduction.xml
index 6a0878a..8a9d018 100644
--- a/Common/Defs/GeneDefs/GeneDefs_Reproduction.xml
+++ b/Common/Defs/GeneDefs/GeneDefs_Reproduction.xml
@@ -1,4 +1,4 @@
-
+
@@ -7,7 +7,7 @@
ReproductionXenotypes with this Gene are Hypersexual (Nymphs).Genes/Icons/Hypersexual
- 1
+ 1
-
-
-
-
- LitteredBirths
-
- Reproduction
- Female carriers of this gene birth litters instead of just one baby, with a chance of having two to four babies per pregnancy.
- Genes/Icons/Gene_LitteredBirths
- 110
- 1.10
- -2
- 1
-
-
-
+
+
+
+
+ LitteredBirths
+
+ Reproduction
+ Female carriers of this gene birth litters instead of just one baby, with a
+ chance of having two to four babies per pregnancy.
+ Genes/Icons/Gene_LitteredBirths
+ 110
+ 1.10
+ -2
+ 1
+
+
+ ImpregnationFetishQuirk
+
+
+
+
rjw_genes_littered_birth_vs_chestburst
+
+
\ No newline at end of file
diff --git a/Common/Defs/GeneDefs/GeneDefs_SexSpecial.xml b/Common/Defs/GeneDefs/GeneDefs_SexSpecial.xml
index 4e85dc7..dc07787 100644
--- a/Common/Defs/GeneDefs/GeneDefs_SexSpecial.xml
+++ b/Common/Defs/GeneDefs/GeneDefs_SexSpecial.xml
@@ -137,7 +137,7 @@
sextamerBestiality has a chance to tame animals or advance their training.
- Genes/Icons/Sexual_Tamer
+ Genes/Icons/RJW_Genes_SexualTamer142-1
diff --git a/Common/Patches/Genes/Patch_Insector_ChestEggs.xml b/Common/Patches/Genes/Patch_Insector_ChestEggs.xml
new file mode 100644
index 0000000..8d01d52
--- /dev/null
+++ b/Common/Patches/Genes/Patch_Insector_ChestEggs.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Common/Textures/Genes/Icons/Mating_Call_2.png b/Common/Textures/Genes/Icons/Mating_Call_2.png
new file mode 100644
index 0000000..275e6dc
Binary files /dev/null and b/Common/Textures/Genes/Icons/Mating_Call_2.png differ
diff --git a/Common/Textures/Genes/Icons/RJW_Genes_PheromoneSpit.png b/Common/Textures/Genes/Icons/RJW_Genes_PheromoneSpit.png
new file mode 100644
index 0000000..fc8f699
Binary files /dev/null and b/Common/Textures/Genes/Icons/RJW_Genes_PheromoneSpit.png differ
diff --git a/Common/Textures/Genes/Icons/RJW_Genes_SexualTamer.png b/Common/Textures/Genes/Icons/RJW_Genes_SexualTamer.png
new file mode 100644
index 0000000..6a848c6
Binary files /dev/null and b/Common/Textures/Genes/Icons/RJW_Genes_SexualTamer.png differ
diff --git a/Common/Textures/Genes/Icons/Samples/AnimalMatingcall.psd b/Common/Textures/Genes/Icons/Samples/AnimalMatingcall.psd
new file mode 100644
index 0000000..16c084b
Binary files /dev/null and b/Common/Textures/Genes/Icons/Samples/AnimalMatingcall.psd differ
diff --git a/Common/Textures/Genes/Icons/Samples/Pheromone_Spit.psd b/Common/Textures/Genes/Icons/Samples/Pheromone_Spit.psd
new file mode 100644
index 0000000..c977538
Binary files /dev/null and b/Common/Textures/Genes/Icons/Samples/Pheromone_Spit.psd differ
diff --git a/Common/Textures/Genes/Icons/Samples/RJW_Genes_MatingCall.psd b/Common/Textures/Genes/Icons/Samples/RJW_Genes_MatingCall.psd
new file mode 100644
index 0000000..0ac04b9
Binary files /dev/null and b/Common/Textures/Genes/Icons/Samples/RJW_Genes_MatingCall.psd differ
diff --git a/Common/Textures/Genes/Icons/Samples/Sexual_Tamer.psd b/Common/Textures/Genes/Icons/Samples/Sexual_Tamer.psd
new file mode 100644
index 0000000..e85ca52
Binary files /dev/null and b/Common/Textures/Genes/Icons/Samples/Sexual_Tamer.psd differ
diff --git a/Common/Textures/Genes/Icons/Samples/Skill_Pheromone_Spit.psd b/Common/Textures/Genes/Icons/Samples/Skill_Pheromone_Spit.psd
new file mode 100644
index 0000000..72e02a0
Binary files /dev/null and b/Common/Textures/Genes/Icons/Samples/Skill_Pheromone_Spit.psd differ
diff --git a/KNOWN_BUGS.md b/KNOWN_BUGS.md
index b836d4e..676fc74 100644
--- a/KNOWN_BUGS.md
+++ b/KNOWN_BUGS.md
@@ -2,6 +2,34 @@
Collection of Known Bugs and reasons for their origin.
+## System.MissingMethodException: bool RimWorld.Pawn_GeneTracker.HasActiveGene(Verse.GeneDef)
+
+You might see a bug like this:
+
+```
+Exception in Verse.AI.ThinkNode_Priority TryIssueJobPackage: System.MissingMethodException: bool RimWorld.Pawn_GeneTracker.HasActiveGene(Verse.GeneDef)
+[Ref A8629303] Duplicate stacktrace, see ref for original
+UnityEngine.StackTraceUtility:ExtractStackTrace ()
+(wrapper dynamic-method) MonoMod.Utils.DynamicMethodDefinition:Verse.Log.Error_Patch2 (string)
+Verse.AI.ThinkNode_Priority:TryIssueJobPackage (Verse.Pawn,Verse.AI.JobIssueParams)
+Verse.AI.ThinkNode_SubtreesByTag:TryIssueJobPackage (Verse.Pawn,Verse.AI.JobIssueParams)
+Verse.AI.ThinkNode_Priority:TryIssueJobPackage (Verse.Pawn,Verse.AI.JobIssueParams)
+Verse.AI.Pawn_JobTracker:DetermineNextJob (Verse.ThinkTreeDef&,bool)
+Verse.AI.Pawn_JobTracker:TryFindAndStartJob ()
+(wrapper dynamic-method) MonoMod.Utils.DynamicMethodDefinition:Verse.AI.Pawn_JobTracker.EndCurrentJob_Patch1 (Verse.AI.Pawn_JobTracker,Verse.AI.JobCondition,bool,bool)
+(wrapper dynamic-method) MonoMod.Utils.DynamicMethodDefinition:Verse.AI.Pawn_JobTracker.JobTrackerTick_Patch0 (Verse.AI.Pawn_JobTracker)
+(wrapper dynamic-method) MonoMod.Utils.DynamicMethodDefinition:Verse.Pawn.Tick_Patch2 (Verse.Pawn)
+Verse.TickList:Tick ()
+(wrapper dynamic-method) MonoMod.Utils.DynamicMethodDefinition:Verse.TickManager.DoSingleTick_Patch3 (Verse.TickManager)
+Verse.TickManager:TickManagerUpdate ()
+(wrapper dynamic-method) MonoMod.Utils.DynamicMethodDefinition:Verse.Game.UpdatePlay_Patch2 (Verse.Game)
+Verse.Root_Play:Update ()
+```
+
+This is due to the game not being updated - hasActiveGene has been introduced later than 1.5.
+
+You will have to update your game.
+
## My Youth Fountain / Age Drainer Pawns do not alter Ages!!!
Issue: You had a pawn with Youth Fountain have Sex with another Pawn, and the other pawn did not get younger.
diff --git a/Source/Common/patches/Patch_ParentRelationUtility_GetParents.cs b/Source/Common/patches/Patch_ParentRelationUtility_GetParents.cs
index c153bf5..d6f2d94 100644
--- a/Source/Common/patches/Patch_ParentRelationUtility_GetParents.cs
+++ b/Source/Common/patches/Patch_ParentRelationUtility_GetParents.cs
@@ -12,6 +12,8 @@ namespace RJW_Genes
{
///
/// This Patch handles the changes to Fathers / Mothers when dealing with Femboys and Male/Male Pregnancies.
+ ///
+ /// This is related to
///
[HarmonyPatch(typeof(ParentRelationUtility))]
public class Patch_ParentRelationUtility_GetParents
diff --git a/Source/Genes/Cum/Patch_LikesCumflation.cs b/Source/Genes/Cum/Patch_LikesCumflation.cs
index f25f28c..6b78068 100644
--- a/Source/Genes/Cum/Patch_LikesCumflation.cs
+++ b/Source/Genes/Cum/Patch_LikesCumflation.cs
@@ -28,6 +28,9 @@ namespace RJW_Genes
if (props == null || props.pawn == null || props.partner == null) return;
+ // Minor Hardening to help with #105
+ if (!ModsConfig.IsActive("LustLicentia.RJWLabs")) return;
+
if (props.pawn.genes != null && props.pawn.genes.HasActiveGene(GeneDefOf.rjw_genes_likes_cumflation) )
{
AddOrIncreaseCumflationCounterHediff(props.pawn);
diff --git a/Source/Genes/Gender/GenderUtility.cs b/Source/Genes/Gender/GenderUtility.cs
index 88aa063..15c7c02 100644
--- a/Source/Genes/Gender/GenderUtility.cs
+++ b/Source/Genes/Gender/GenderUtility.cs
@@ -101,5 +101,20 @@ namespace RJW_Genes
pawn.health.RemoveHediff(hediff);
}
}
+
+ ///
+ /// This check helps to get babies after birth, if the pawn was born with the gene it does not need to have thoughts.
+ /// There are very different ways to do the life stages, and there are also HAR people still around,
+ /// so instead of checking for stages I intentionally check for the biological ticks to be very low (that they can only exist basically if they are born right before).
+ /// Issue is tracked in #103.
+ ///
+ ///
+ public static void RemoveSexChangeThoughtsIfTooYoung(Pawn pawn)
+ {
+ if (pawn.ageTracker.AgeBiologicalTicks < 1000)
+ {
+ GenderUtility.RemoveAllSexChangeThoughts(pawn);
+ }
+ }
}
}
diff --git a/Source/Genes/Gender/Gene_FemaleOnly.cs b/Source/Genes/Gender/Gene_FemaleOnly.cs
index df48328..c3d5ef6 100644
--- a/Source/Genes/Gender/Gene_FemaleOnly.cs
+++ b/Source/Genes/Gender/Gene_FemaleOnly.cs
@@ -14,12 +14,15 @@ namespace RJW_Genes
// Here we call Sexualization after the Sex-Change
if (GenitaliaUtility.PawnStillNeedsGenitalia(pawn))
Sexualizer.sexualize_pawn(pawn);
+
+ GenderUtility.RemoveSexChangeThoughtsIfTooYoung(this.pawn);
}
public override void PostAdd()
{
base.PostMake();
AdjustPawnToFemale();
+ GenderUtility.RemoveSexChangeThoughtsIfTooYoung(this.pawn);
}
private void AdjustPawnToFemale()
diff --git a/Source/Genes/Gender/Gene_MaleOnly.cs b/Source/Genes/Gender/Gene_MaleOnly.cs
index d99652a..daca649 100644
--- a/Source/Genes/Gender/Gene_MaleOnly.cs
+++ b/Source/Genes/Gender/Gene_MaleOnly.cs
@@ -14,12 +14,15 @@ namespace RJW_Genes
// Here we call Sexualization after the Sex-Change
if (GenitaliaUtility.PawnStillNeedsGenitalia(pawn))
Sexualizer.sexualize_pawn(pawn);
+
+ GenderUtility.RemoveSexChangeThoughtsIfTooYoung(this.pawn);
}
public override void PostAdd()
{
base.PostMake();
AdjustPawnToMale();
+ GenderUtility.RemoveSexChangeThoughtsIfTooYoung(this.pawn);
}
private void AdjustPawnToMale()
diff --git a/Source/Genes/Patches/Patch_Asexual_CanRape.cs b/Source/Genes/Patches/Patch_Asexual_CanRape.cs
new file mode 100644
index 0000000..76e02a3
--- /dev/null
+++ b/Source/Genes/Patches/Patch_Asexual_CanRape.cs
@@ -0,0 +1,28 @@
+using HarmonyLib;
+using rjw;
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+using Verse;
+
+namespace RJW_Genes.Genes.Patches
+{
+ ///
+ /// This Patch hooks after "can_rape" and changes it to false for pawns that have no sex_need (are a-sexual).
+ /// This helps with #100, and is more of a non-intrusive improvement over the base game.
+ ///
+ [HarmonyPatch(typeof(xxx), nameof(xxx.can_rape))]
+ public class Patch_Asexual_CanRape
+ {
+ public static bool PostFix(Pawn pawn, ref bool __result)
+ {
+ if (pawn != null && pawn.genes != null && pawn.genes.HasActiveGene(GeneDefOf.rjw_genes_no_sex_need))
+ {
+ __result = false;
+ }
+ return __result;
+ }
+ }
+}
diff --git a/Source/Genes/Special/Patches/Patch_AgeDrain.cs b/Source/Genes/Special/Patches/Patch_AgeDrain.cs
index 060c20d..ab159b1 100644
--- a/Source/Genes/Special/Patches/Patch_AgeDrain.cs
+++ b/Source/Genes/Special/Patches/Patch_AgeDrain.cs
@@ -31,6 +31,12 @@ namespace RJW_Genes.Genes.Special
return;
}
+ if (props.pawn == props.partner || props.sexType == xxx.rjwSextype.Masturbation || props.sexType == xxx.rjwSextype.None)
+ {
+ // This case was reported but is a bit strange, I hardened it after reports in #99
+ return;
+ }
+
Pawn pawn = props.pawn;
Pawn partner = props.partner;
diff --git a/Source/Genes/Special/Patches/Patch_OrgasmMytosis.cs b/Source/Genes/Special/Patches/Patch_OrgasmMytosis.cs
index ba640bb..fb93e10 100644
--- a/Source/Genes/Special/Patches/Patch_OrgasmMytosis.cs
+++ b/Source/Genes/Special/Patches/Patch_OrgasmMytosis.cs
@@ -31,7 +31,9 @@ namespace RJW_Genes
Pawn orgasmingPawn = __instance.pawn;
bool hasPollutedMytosis = false;
- if (orgasmingPawn != null && (GeneUtility.HasGeneNullCheck(orgasmingPawn, GeneDefOf.rjw_genes_sexual_mytosis) || hasPollutedMytosis) && ! orgasmingPawn.health.hediffSet.HasHediff(HediffDefOf.rjw_genes_mytosis_shock_hediff))
+ if (orgasmingPawn == null || orgasmingPawn.genes == null) { return; }
+
+ if ((GeneUtility.HasGeneNullCheck(orgasmingPawn, GeneDefOf.rjw_genes_sexual_mytosis) || hasPollutedMytosis) && ! orgasmingPawn.health.hediffSet.HasHediff(HediffDefOf.rjw_genes_mytosis_shock_hediff))
{
var mytosisHediff = GetOrgasmMytosisHediff(orgasmingPawn);
mytosisHediff.Severity += SEVERITY_INCREASE_PER_ORGASM;
@@ -148,6 +150,8 @@ namespace RJW_Genes
copy.style = CopyStyleTracker(copy, toMultiply.style);
copy.story = CopyStoryTracker(copy, toMultiply.story);
+ copy.genes.xenotypeName = toMultiply.genes.xenotypeName;
+ copy.story.favoriteColor = toMultiply.story.favoriteColor;
Find.LetterStack.ReceiveLetter("Orgasmic Mytosis", $"{toMultiply.NameShortColored} performed mytosis on orgasm! The pawn and its clone entered a regenerative state.",
RimWorld.LetterDefOf.NeutralEvent, copy);
diff --git a/Source/Genes/Special/Patches/Patch_Youth_Fountain.cs b/Source/Genes/Special/Patches/Patch_Youth_Fountain.cs
index b64ca83..d810bc6 100644
--- a/Source/Genes/Special/Patches/Patch_Youth_Fountain.cs
+++ b/Source/Genes/Special/Patches/Patch_Youth_Fountain.cs
@@ -30,6 +30,12 @@ namespace RJW_Genes.Genes.Special
return;
}
+ if (props.pawn == props.partner || props.sexType == xxx.rjwSextype.Masturbation || props.sexType == xxx.rjwSextype.None)
+ {
+ // This case was reported but is a bit strange, I hardened it after reports in #99
+ return;
+ }
+
if (GeneUtility.IsYouthFountain(props.pawn))
{
ChangeAgeForPawn(props.partner, props.pawn);
diff --git a/Source/Rjw-Genes.csproj b/Source/Rjw-Genes.csproj
index 500f87e..dadf954 100644
--- a/Source/Rjw-Genes.csproj
+++ b/Source/Rjw-Genes.csproj
@@ -166,6 +166,7 @@
+
@@ -218,8 +219,7 @@
False
- ..\..\rjw-sexperience-master\1.5\Assemblies\RJWSexperience.dll
- False
+ ..\..\rjw-sexperience\1.5\Assemblies\RJWSexperience.dll