diff --git a/1.5/Assemblies/Rimworld-Animations.dll b/1.5/Assemblies/Rimworld-Animations.dll index def309c..5251f7f 100644 Binary files a/1.5/Assemblies/Rimworld-Animations.dll and b/1.5/Assemblies/Rimworld-Animations.dll differ diff --git a/1.5/Source/Patches/RJWPatches/JobDrivers/HarmonyPatch_JobDriver_Sex.cs b/1.5/Source/Patches/RJWPatches/JobDrivers/HarmonyPatch_JobDriver_Sex.cs index c025bec..5b1043a 100644 --- a/1.5/Source/Patches/RJWPatches/JobDrivers/HarmonyPatch_JobDriver_Sex.cs +++ b/1.5/Source/Patches/RJWPatches/JobDrivers/HarmonyPatch_JobDriver_Sex.cs @@ -24,4 +24,30 @@ namespace Rimworld_Animations } } + [HarmonyPatch(typeof(JobDriver_Sex), "SexTick")] + public class HarmonyPatch_JobDriver_Sex2 + { + public static void Postfix(JobDriver_Sex __instance, Pawn pawn) + { + //if neverending sex and pawn doesn't have an animation, + if (__instance.neverendingsex + && __instance is JobDriver_SexBaseReciever receiverJobDriver + && !pawn.TryGetComp().IsAnimating) + { + + //start a new animation for all the pawns paired with receiver job driver + List participants = receiverJobDriver.parteners.Append(pawn).ToList(); + GroupAnimationDef animation = AnimationUtility.FindGroupAnimation(participants, out int reorder); + if (animation != null) + { + Thing anchor = (Thing)__instance.Bed ?? pawn; + AnimationUtility.StartGroupAnimation(participants, animation, reorder, anchor); + } + + + } + + } + } + } diff --git a/1.5/Source/Patches/RJWPatches/JobDrivers/HarmonyPatch_JobDriver_SexBaseInitiator.cs b/1.5/Source/Patches/RJWPatches/JobDrivers/HarmonyPatch_JobDriver_SexBaseInitiator.cs index e30e0b9..75e43cc 100644 --- a/1.5/Source/Patches/RJWPatches/JobDrivers/HarmonyPatch_JobDriver_SexBaseInitiator.cs +++ b/1.5/Source/Patches/RJWPatches/JobDrivers/HarmonyPatch_JobDriver_SexBaseInitiator.cs @@ -48,8 +48,6 @@ namespace Rimworld_Animations { participantJobDriver.orgasmStartTick = animTicks; participantJobDriver.duration = animTicks; } - - } } }