diff --git a/1.4/Assemblies/RJW_Menstruation.dll b/1.4/Assemblies/RJW_Menstruation.dll index 443fe23..f289122 100644 Binary files a/1.4/Assemblies/RJW_Menstruation.dll and b/1.4/Assemblies/RJW_Menstruation.dll differ diff --git a/1.4/MilkModule/Assemblies/MilkModule.dll b/1.4/MilkModule/Assemblies/MilkModule.dll index 0adf6be..7337849 100644 Binary files a/1.4/MilkModule/Assemblies/MilkModule.dll and b/1.4/MilkModule/Assemblies/MilkModule.dll differ diff --git a/1.4/source/RJW_Menstruation/RJW_Menstruation/Compatibility/AnimalGeneticsCompatibility.cs b/1.4/source/RJW_Menstruation/RJW_Menstruation/Compatibility/AnimalGeneticsCompatibility.cs index 1e7e50c..9cbb425 100644 --- a/1.4/source/RJW_Menstruation/RJW_Menstruation/Compatibility/AnimalGeneticsCompatibility.cs +++ b/1.4/source/RJW_Menstruation/RJW_Menstruation/Compatibility/AnimalGeneticsCompatibility.cs @@ -1,5 +1,4 @@ -#if false -using AnimalGenetics; +using AnimalGenetics; using RimWorld; using System.Collections.Generic; using Verse; @@ -39,4 +38,3 @@ namespace RJW_Menstruation } } } -#endif diff --git a/1.4/source/RJW_Menstruation/RJW_Menstruation/Hediff_MultiplePregnancy.cs b/1.4/source/RJW_Menstruation/RJW_Menstruation/Hediff_MultiplePregnancy.cs index e7c91dc..119613e 100644 --- a/1.4/source/RJW_Menstruation/RJW_Menstruation/Hediff_MultiplePregnancy.cs +++ b/1.4/source/RJW_Menstruation/RJW_Menstruation/Hediff_MultiplePregnancy.cs @@ -10,7 +10,7 @@ namespace RJW_Menstruation { public class Hediff_MultiplePregnancy : Hediff_BasePregnancy { - protected Dictionary enzygoticSiblings; // Each pawn and who they split from + protected Dictionary enzygoticSiblings = new Dictionary(); // Each pawn and who they split from public override void DiscoverPregnancy() { @@ -52,7 +52,7 @@ namespace RJW_Menstruation { father = Trytogetfather(ref pawn); } - Initialize(pawn, father); + Initialize(pawn, father, SelectDnaGivingParent(pawn, father)); } foreach (Pawn baby in babies) @@ -356,7 +356,7 @@ namespace RJW_Menstruation Scribe_Collections.Look(ref enzygoticSiblings, "enzygoticSiblings", keyLookMode: LookMode.Reference, valueLookMode: LookMode.Reference); } - protected override void GenerateBabies() + protected override void GenerateBabies(DnaGivingParent _) { AddNewBaby(pawn, father); } @@ -378,31 +378,10 @@ namespace RJW_Menstruation public bool AddNewBaby(Pawn mother, Pawn father) { - //float melanin; string lastname; - if (xxx.is_human(mother)) - { - if (xxx.is_human(father)) - { - //melanin = ChildRelationUtility.GetRandomChildSkinColor(father.story?.melanin ?? 0f, mother.story?.melanin ?? 0f); - //melanin = (mother.story?.melanin ?? 0f + father.story?.melanin ?? 0f) / 2; - } - else - { - //melanin = mother.story?.melanin ?? 0f; - } - lastname = NameTriple.FromString(mother.Name.ToStringFull).Last; - } - else if (xxx.is_human(father)) - { - //melanin = father.story?.melanin ?? 0f; - lastname = NameTriple.FromString(father.Name.ToStringFull).Last; - } - else - { - //melanin = Rand.Range(0, 1.0f); - lastname = ""; - } + if (xxx.is_human(mother)) lastname = NameTriple.FromString(mother.Name.ToStringFull).Last; + else if (xxx.is_human(father)) lastname = NameTriple.FromString(father.Name.ToStringFull).Last; + else lastname = ""; PawnGenerationRequest request = new PawnGenerationRequest( developmentalStages: DevelopmentalStage.Newborn, @@ -424,7 +403,6 @@ namespace RJW_Menstruation int division = 1; Pawn firstbaby = null; - //string firstheadpath = null; int traitSeed = Rand.Int; List parentTraits = GetInheritableTraits(mother, father); while (Rand.Chance(Configurations.EnzygoticTwinsChance) && division < Configurations.MaxEnzygoticTwins) division++; @@ -476,8 +454,8 @@ namespace RJW_Menstruation if (baby.IsHAR()) HARCompatibility.CopyHARProperties(baby, firstbaby); - //if (Configurations.AnimalGeneticsActivated) - //AnimalGeneticsCompatibility.CopyGenes(baby, firstbaby); + if (Configurations.AnimalGeneticsActivated) + AnimalGeneticsCompatibility.CopyGenes(baby, firstbaby); } } babies.Add(baby); @@ -489,9 +467,9 @@ namespace RJW_Menstruation public Pawn GenerateBaby(PawnGenerationRequest request, Pawn mother, Pawn father, List parentTraits, int traitSeed) { - //if (Configurations.AnimalGeneticsActivated) AnimalGeneticsCompatibility.PreConception(mother, father); + if (Configurations.AnimalGeneticsActivated) AnimalGeneticsCompatibility.PreConception(mother, father); Pawn baby = PawnGenerator.GeneratePawn(request); - //if (Configurations.AnimalGeneticsActivated) AnimalGeneticsCompatibility.PostConception(); + if (Configurations.AnimalGeneticsActivated) AnimalGeneticsCompatibility.PostConception(); if (baby == null) { Log.Error("Baby not generated. Request: " + request.ToString()); @@ -777,12 +755,6 @@ namespace RJW_Menstruation pawn.story.traits.allTraits = selectedTraits; } - public override void Initialize(Pawn mother, Pawn dad) - { - enzygoticSiblings = new Dictionary(); - base.Initialize(mother, dad); - } - public string DueDate() { if (pawn.Tile == -1) return ""; diff --git a/1.4/source/RJW_Menstruation/RJW_Menstruation/Patch/GetGizmos.cs b/1.4/source/RJW_Menstruation/RJW_Menstruation/Patch/Gizmo_Patch.cs similarity index 100% rename from 1.4/source/RJW_Menstruation/RJW_Menstruation/Patch/GetGizmos.cs rename to 1.4/source/RJW_Menstruation/RJW_Menstruation/Patch/Gizmo_Patch.cs diff --git a/1.4/source/RJW_Menstruation/RJW_Menstruation/RJW_Menstruation.csproj b/1.4/source/RJW_Menstruation/RJW_Menstruation/RJW_Menstruation.csproj index 22ab246..2de20d8 100644 --- a/1.4/source/RJW_Menstruation/RJW_Menstruation/RJW_Menstruation.csproj +++ b/1.4/source/RJW_Menstruation/RJW_Menstruation/RJW_Menstruation.csproj @@ -72,6 +72,7 @@ + @@ -80,7 +81,6 @@ - @@ -98,6 +98,10 @@ ..\..\..\..\..\..\..\..\workshop\content\294100\839005762\1.4\Assemblies\AlienRace.dll False + + ..\..\..\..\..\..\..\..\workshop\content\294100\2830943477\1.4\Assemblies\AnimalGenetics.dll + False + ..\..\..\..\..\..\RimWorldWin64_Data\Managed\Assembly-CSharp.dll False diff --git a/About/Manifest.xml b/About/Manifest.xml index c88dc12..84c2a83 100644 --- a/About/Manifest.xml +++ b/About/Manifest.xml @@ -1,7 +1,7 @@ RJW Menstruation - 1.0.8.2 + 1.0.8.3 @@ -11,6 +11,7 @@
  • rim.job.world
  • Abraxas.RJW.RaceSupport
  • rjw.milk.humanoid
  • +
  • Mlie.AnimalGenetics
  • diff --git a/changelogs.txt b/changelogs.txt index 91640aa..cfa0841 100644 --- a/changelogs.txt +++ b/changelogs.txt @@ -1,3 +1,8 @@ +Version 1.0.8.3 + - Compatibility update for RJW 5.3.0.9 + - Requires RJW 5.3.0.9 + - Re-added support for Animal Genetics (Continued). + Version 1.0.8.2 - Compatibility update for RJW 5.3.0.7 - Requires RJW 5.3.0.7