Exemple #1
0
        protected override IEnumerable <Toil> MakeNewToils()
        {
            ticks_left = (int)(2500.0f * Rand.Range(0.20f, 0.70f));

            this.FailOnDespawnedOrNull(ibed);
            this.KeepLyingDown(ibed);
            yield return(Toils_Bed.ClaimBedIfNonMedical(ibed, TargetIndex.None));

            yield return(Toils_Bed.GotoBed(ibed));

            Toil do_fappin = Toils_LayDown.LayDown(ibed, true, false, false, false);

            do_fappin.AddPreTickAction(delegate
            {
                --this.ticks_left;
                if (this.ticks_left <= 0)
                {
                    this.ReadyForNextToil();
                }
                else if (pawn.IsHashIntervalTick(ticks_between_hearts))
                {
                    MoteMaker.ThrowMetaIcon(pawn.Position, pawn.Map, ThingDefOf.Mote_Heart);
                }
            });
            do_fappin.AddFinishAction(delegate
            {
                pawn.mindState.canLovinTick = Find.TickManager.TicksGame + generate_min_ticks_to_next_fappin(pawn);
                xxx.satisfy(pawn, null);
            });
            do_fappin.socialMode = RandomSocialMode.Off;
            yield return(do_fappin);
        }
        protected override IEnumerable <Toil> MakeNewToils()
        {
            //Fail Checks

            this.EndOnDespawnedOrNull(TargetIndex.A, JobCondition.Incompletable);   //If we don't exist, exit.

            if (job.targetA.Thing is Building_Radio)
            {
                report = "Listening to the radio.";
            }


            //yield return Toils_Reserve.Reserve(TargetIndex.A, base.CurJob.def.joyMaxParticipants); //Can we reserve?

            //yield return Toils_Reserve.Reserve(TargetIndex.B, 1);   //Reserve

            var  flag = base.TargetC.HasThing && base.TargetC.Thing is Building_Bed;
            Toil toil;

            if (flag)   //If we have a bed, do something else.
            {
                this.KeepLyingDown(TargetIndex.C);
                yield return(Toils_Reserve.Reserve(TargetIndex.C, ((Building_Bed)base.TargetC.Thing).SleepingSlotsCount));

                yield return(Toils_Bed.ClaimBedIfNonMedical(TargetIndex.C, TargetIndex.None));

                yield return(Toils_Bed.GotoBed(TargetIndex.C));

                toil = Toils_LayDown.LayDown(TargetIndex.C, true, false, true, true);
                toil.AddFailCondition(() => !pawn.Awake());
            }
            else
            {
                if (base.TargetC.HasThing)
                {
                    yield return(Toils_Reserve.Reserve(TargetIndex.C, 1));
                }
                yield return(Toils_Goto.GotoCell(TargetIndex.B, PathEndMode.OnCell));

                toil = new Toil();
            }
            toil.AddPreTickAction(delegate
            {
                if (job.targetA.Thing is Building_Radio)
                {
                    report = "Listening to the radio.";
                }

                ListenTickAction();
            });
            toil.AddFinishAction(delegate
            {
                JoyUtility.TryGainRecRoomThought(pawn);
            });
            toil.defaultCompleteMode = ToilCompleteMode.Delay;
            toil.defaultDuration     = base.job.def.joyDuration * 2;
            yield return(toil);

            yield break;
        }
        protected override IEnumerable <Toil> MakeNewToils()
        {
            // Faster fapping when frustrated.
            //Rand.PopState();
            //Rand.PushState(RJW_Multiplayer.PredictableSeed());
            ticks_left = (int)(xxx.need_some_sex(pawn) > 2f ? 2500.0f * Rand.Range(0.2f, 0.7f) : 2500.0f * Rand.Range(0.2f, 0.4f));

            this.FailOnDespawnedOrNull(ibed);
            this.FailOn(() => pawn.Drafted);
            this.KeepLyingDown(ibed);
            yield return(Toils_Bed.ClaimBedIfNonMedical(ibed));

            yield return(Toils_Bed.GotoBed(ibed));

            Toil do_fappin = Toils_LayDown.LayDown(ibed, true, false, false, false);

            do_fappin.AddPreTickAction(delegate
            {
                --ticks_left;
                xxx.reduce_rest(pawn, 1);
                if (ticks_left <= 0)
                {
                    ReadyForNextToil();
                }
                else if (pawn.IsHashIntervalTick(ticks_between_hearts))
                {
                    MoteMaker.ThrowMetaIcon(pawn.Position, pawn.Map, ThingDefOf.Mote_Heart);
                }
            });
            do_fappin.AddFinishAction(delegate
            {
                //Moved satisfy and tick increase to aftersex, since it works with solo acts now.
                SexUtility.Aftersex(pawn, xxx.rjwSextype.Masturbation);
                if (SexUtility.ConsiderCleaning(pawn))
                {
                    LocalTargetInfo own_cum = pawn.PositionHeld.GetFirstThing <Filth>(pawn.Map);

                    Job clean = new Job(JobDefOf.Clean);
                    clean.AddQueuedTarget(TargetIndex.A, own_cum);

                    pawn.jobs.jobQueue.EnqueueFirst(clean);
                }
            });
            do_fappin.socialMode = RandomSocialMode.Off;
            yield return(do_fappin);
        }
Exemple #4
0
        protected override IEnumerable <Toil> MakeNewToils()
        {
            Toil relax;

            if (this.FromBed)
            {
                this.KeepLyingDown(TargetIndex.A);
                yield return(Toils_Bed.ClaimBedIfNonMedical(TargetIndex.A, TargetIndex.None));

                yield return(Toils_Bed.GotoBed(TargetIndex.A));

                relax = Toils_LayDown.LayDown(TargetIndex.A, true, false, true, true);
                relax.AddFailCondition(() => !this.pawn.Awake());
            }
            else
            {
                yield return(Toils_Goto.GotoCell(TargetIndex.A, PathEndMode.OnCell));

                relax            = new Toil();
                relax.initAction = delegate
                {
                    this.faceDir = ((!this.job.def.faceDir.IsValid) ? Rot4.Random : this.job.def.faceDir);
                };
                relax.handlingFacing = true;
            }
            relax.defaultCompleteMode = ToilCompleteMode.Delay;
            relax.defaultDuration     = this.job.def.joyDuration;
            relax.AddPreTickAction(delegate
            {
                if (this.faceDir.IsValid)
                {
                    this.pawn.rotationTracker.FaceCell(this.pawn.Position + this.faceDir.FacingCell);
                }
                this.pawn.GainComfortFromCellIfPossible();
                JoyUtility.JoyTickCheckEnd(this.pawn, JoyTickFullJoyAction.EndJob, 1f, null);
                PrayUtility.TickCheckEnd(pawn);
            });
            yield return(relax);

            this.AddFinishAction(() =>
            {
                ReligionProperty property = pawn.GetReligionComponent().Religion.GetSettings <ReligionSettings_Prayings>(SettingsTagDefOf.PrayingsTag).Property;
                PietyUtility.TryApplyOnPawn(property.Subject, pawn);
            });
        }
        protected override IEnumerable <Toil> MakeNewToils()
        {
            this.FailOnDespawnedOrNull(TargetIndex.A);
            Toil goToPlatform = Toils_Bed.GotoBed(TargetIndex.A);

            yield return(goToPlatform);

            Toil layDownToil = Toils_LayDown.LayDown(TargetIndex.A, true, false, false, false);

            layDownToil.defaultCompleteMode = ToilCompleteMode.Never;
            layDownToil.initAction          = new Action(delegate {
                pawn.ClearAllReservations();
            });
            layDownToil.AddPreTickAction(delegate
            {
                if (!(pawn.health.hediffSet.HasNaturallyHealingInjury() || (pawn.OnHackingTable() && HealthAIUtility.ShouldHaveSurgeryDoneNow(pawn))))
                {
                    ReadyForNextToil();
                }
                if (pawn.jobs.posture == PawnPosture.Standing)
                {
                    RotateToSouth();
                }
            });
            yield return(layDownToil);

            Toil toil = new Toil();

            toil.defaultCompleteMode = ToilCompleteMode.Never;
            toil.initAction          = delegate
            {
                pawn.jobs.posture = PawnPosture.Standing;
                pawn.Position     = RestingPlace.GetSleepingSlotPos(RestingPlace is Building_HackingTable ? Building_HackingTable.SLOTINDEX : Building_BaseMechanoidPlatform.SLOTINDEX);
                RotateToSouth();
            };
            yield return(toil);
        }
        protected override IEnumerable <Toil> MakeNewToils()
        {
            setup_ticks();
            parteners.Add(Partner);            // add job starter, so this wont fail, before Initiator starts his job
            //--Log.Message("[RJW]JobDriver_GettinLoved::MakeNewToils is called");

            float partner_ability = xxx.get_sex_ability(Partner);

            // More/less hearts based on partner ability.
            if (partner_ability < 0.8f)
            {
                ticks_between_thrusts += 120;
            }
            else if (partner_ability > 2.0f)
            {
                ticks_between_thrusts -= 30;
            }

            // More/less hearts based on opinion.
            if (pawn.relations.OpinionOf(Partner) < 0)
            {
                ticks_between_hearts += 50;
            }
            else if (pawn.relations.OpinionOf(Partner) > 60)
            {
                ticks_between_hearts -= 25;
            }

            this.FailOnDespawnedOrNull(iTarget);
            this.FailOn(() => !Partner.health.capacities.CanBeAwake);

            if (Partner.CurJob.def == xxx.casual_sex)
            {
                this.FailOn(() => pawn.Drafted);
                this.KeepLyingDown(iBed);
                yield return(Toils_Reserve.Reserve(iTarget, 1, 0));

                yield return(Toils_Reserve.Reserve(iBed, Bed.SleepingSlotsCount, 0));

                Toil get_loved = Toils_LayDown.LayDown(iBed, true, false, false, false);
                get_loved.FailOn(() => Partner.CurJob.def != xxx.casual_sex);
                get_loved.defaultCompleteMode = ToilCompleteMode.Never;
                get_loved.socialMode          = RandomSocialMode.Off;
                get_loved.handlingFacing      = true;
                get_loved.tickAction          = delegate
                {
                    if (pawn.IsHashIntervalTick(ticks_between_hearts))
                    {
                        ThrowMetaIcon(pawn.Position, pawn.Map, ThingDefOf.Mote_Heart);
                    }
                };
                get_loved.AddFinishAction(delegate
                {
                    if (xxx.is_human(pawn))
                    {
                        pawn.Drawer.renderer.graphics.ResolveApparelGraphics();
                    }
                });
                yield return(get_loved);
            }
            else if (Partner.CurJob.def == xxx.whore_is_serving_visitors)
            {
                this.FailOn(() => Partner.CurJob == null);
                yield return(Toils_Goto.GotoThing(iTarget, PathEndMode.OnCell));

                yield return(Toils_Reserve.Reserve(iTarget, 1, 0));

                Toil get_loved = new Toil();
                get_loved.FailOn(() => (Partner.CurJob.def != xxx.whore_is_serving_visitors));
                get_loved.defaultCompleteMode = ToilCompleteMode.Never;
                get_loved.socialMode          = RandomSocialMode.Off;
                get_loved.handlingFacing      = true;
                get_loved.tickAction          = delegate
                {
                    --ticks_remaining;
                    if (pawn.IsHashIntervalTick(ticks_between_hearts))
                    {
                        ThrowMetaIcon(pawn.Position, pawn.Map, ThingDefOf.Mote_Heart);
                    }
                };
                get_loved.AddEndCondition(new Func <JobCondition>(() =>
                {
                    if ((ticks_remaining <= 0) || (parteners.Count <= 0))
                    {
                        return(JobCondition.Succeeded);
                    }
                    return(JobCondition.Ongoing);
                }));
                get_loved.AddFinishAction(delegate
                {
                    if (xxx.is_human(pawn))
                    {
                        pawn.Drawer.renderer.graphics.ResolveApparelGraphics();
                    }
                });
                yield return(get_loved);
            }
            else if (Partner.CurJob.def == xxx.bestialityForFemale)
            {
                this.FailOn(() => Partner.CurJob == null);
                yield return(Toils_Goto.GotoThing(iTarget, PathEndMode.OnCell));

                yield return(Toils_Reserve.Reserve(iTarget, 1, 0));

                Toil get_loved = new Toil();
                get_loved.FailOn(() => (Partner.CurJob.def != xxx.bestialityForFemale));
                get_loved.defaultCompleteMode = ToilCompleteMode.Never;
                get_loved.socialMode          = RandomSocialMode.Off;
                get_loved.handlingFacing      = true;
                get_loved.tickAction          = delegate
                {
                    --ticks_remaining;
                    if (pawn.IsHashIntervalTick(ticks_between_hearts))
                    {
                        ThrowMetaIcon(pawn.Position, pawn.Map, ThingDefOf.Mote_Heart);
                    }
                };
                get_loved.AddEndCondition(new Func <JobCondition>(() =>
                {
                    if ((ticks_remaining <= 0) || (parteners.Count <= 0))
                    {
                        return(JobCondition.Succeeded);
                    }
                    return(JobCondition.Ongoing);
                }));
                get_loved.AddFinishAction(delegate
                {
                    if (xxx.is_human(pawn))
                    {
                        pawn.Drawer.renderer.graphics.ResolveApparelGraphics();
                    }
                });
                get_loved.socialMode = RandomSocialMode.Off;
                yield return(get_loved);
            }
        }
Exemple #7
0
        protected override IEnumerable <Toil> MakeNewToils()
        {
#if DEBUG
            Verse.Log.Message(string.Format("MakeNewToils, HasChairOrBed={0}, IsInBed={1}", HasChairOrBed, IsInBed));
            //Verse.Log.Message(String.Format("pawn.CurJob = {0}", pawn.CurJob == null ? "null" : pawn.CurJob.def.LabelCap ));
            //Verse.Log.Message(String.Format("pawn.getPosture = {0}", pawn.GetPosture().ToString()));
            //Verse.Log.Message(String.Format("current bed hashcode = {0}, target hashcode = {1}", pawn.CurrentBed() == null ? 0 : pawn.CurrentBed().GetHashCode(), HasChairOrBed ? ChairOrBed.GetHashCode() : 0));
#endif

            this.EndOnDespawnedOrNull(MusicSpotParentInd);

            //Verse.Log.Message(String.Format("Gather Spot ID = {0}", MusicSpotParent.GetHashCode()));

            if (HasChairOrBed)
            {
                this.EndOnDespawnedOrNull(ChairOrSpotOrBedInd);
            }

            var listener = pawn;

            var venue = MusicSpotParent;


            if (!HasChairOrBed)
            {
#if DEBUG
                Verse.Log.Message("goto cell");
#endif
                yield return(Toils_Goto.GotoCell(ChairOrSpotOrBedInd, PathEndMode.OnCell));
            }
            else if (!IsInBed)
            {
#if DEBUG
                Verse.Log.Message("goto chair");
#endif
                yield return(Toils_Goto.GotoThing(ChairOrSpotOrBedInd, PathEndMode.OnCell));
            }
            else
            {
#if DEBUG
                Verse.Log.Message("goto bed");
#endif
                yield return(Toils_Bed.ClaimBedIfNonMedical(ChairOrSpotOrBedInd));

                yield return(Toils_Bed.GotoBed(ChairOrSpotOrBedInd));
            }

            // custom toil.
            Toil listen;

            if (IsInBed)
            {
                this.KeepLyingDown(ChairOrSpotOrBedInd);
                listen = Toils_LayDown.LayDown(ChairOrSpotOrBedInd, true, false);
                listen.AddFailCondition(() => !listen.actor.Awake());
            }
            else
            {
                listen = new Toil();
            }


            listen.tickAction = delegate
            {
                if (!HasChairOrBed)
                {
                    pawn.rotationTracker.FaceCell(ClosestMusicSpotParentCell);
                }

                JoyUtility.JoyTickCheckEnd(listener, JoyTickFullJoyAction.GoToNextToil,
                                           1f + Math.Abs(pawn.Map.GetComponent <PerformanceManager>().GetPerformanceQuality(venue)));
            };

            listen.handlingFacing      = !HasChairOrBed;
            listen.defaultCompleteMode = ToilCompleteMode.Delay;
            listen.defaultDuration     = job.def.joyDuration;

            listen.AddEndCondition(() => pawn.Map.GetComponent <PerformanceManager>().HasPerformance(venue)
                ? JobCondition.Ongoing
                : JobCondition.Incompletable);

            listen.AddFinishAction(delegate { JoyUtility.TryGainRecRoomThought(pawn); });
            listen.socialMode = RandomSocialMode.Quiet;
            yield return(listen);
        }
Exemple #8
0
        protected override IEnumerable <Toil> MakeNewToils()
        {
            //--Log.Message("[RJW]JobDriver_GettinLoved::MakeNewToils is called");

            if (Partner.CurJob.def == xxx.nymph_rapin)
            {
                //this.KeepLyingDown(ibed);
                //yield return Toils_Reserve.Reserve(ipartner, 1, 0);
                //yield return Toils_Reserve.Reserve(ibed, Bed.SleepingSlotsCount, 0);
                //Toil get_loved = Toils_LayDown.LayDown(ibed, true, false, false, false);
                //get_loved.FailOn(() => (Partner.CurJob.def != xxx.nymph_rapin));
                //get_loved.defaultCompleteMode = ToilCompleteMode.Never;
                //get_loved.initAction = delegate {
                //    //--Log.Message("[RJW]JobDriver_GettinLoved::MakeNewToils - nymph section is called");
                //};
                //get_loved.AddPreTickAction(delegate {
                //    if (pawn.IsHashIntervalTick(100))
                //        MoteMaker.ThrowMetaIcon(pawn.Position, pawn.Map, ThingDefOf.Mote_Heart);
                //});
                //get_loved.socialMode = RandomSocialMode.Off;
                //yield return get_loved;

                this.FailOnDespawnedOrNull(ipartner);
                this.FailOn(() => !Partner.health.capacities.CanBeAwake);
                this.KeepLyingDown(ibed);
                yield return(Toils_Reserve.Reserve(ipartner, 1, 0));

                yield return(Toils_Reserve.Reserve(ibed, Bed.SleepingSlotsCount, 0));

                Toil get_loved = Toils_LayDown.LayDown(ibed, true, false, false, false);
                get_loved.FailOn(() => (Partner.CurJob == null) || (Partner.CurJob.def != xxx.nymph_rapin));
                get_loved.defaultCompleteMode = ToilCompleteMode.Never;
                get_loved.AddPreTickAction(delegate
                {
                    if (pawn.IsHashIntervalTick(100))
                    {
                        MoteMaker.ThrowMetaIcon(pawn.Position, pawn.Map, ThingDefOf.Mote_Heart);
                    }
                });
                get_loved.socialMode = RandomSocialMode.Off;
                yield return(get_loved);
            }
            else if (Partner.CurJob.def == xxx.whore_is_serving_visitors)
            {
                this.FailOnDespawnedOrNull(ipartner);
                this.FailOn(() => !Partner.health.capacities.CanBeAwake || Partner.CurJob == null);
                yield return(Toils_Goto.GotoThing(ipartner, PathEndMode.OnCell));

                yield return(Toils_Reserve.Reserve(ipartner, 1, 0));

                Toil get_loved = new Toil();
                get_loved.FailOn(() => (Partner.CurJob.def != xxx.whore_is_serving_visitors));
                get_loved.defaultCompleteMode = ToilCompleteMode.Never;
                get_loved.initAction          = delegate
                {
                    //--Log.Message("[RJW]JobDriver_GettinLoved::MakeNewToils - w***e section is called");
                };
                get_loved.AddPreTickAction(delegate
                {
                    if (pawn.IsHashIntervalTick(100))
                    {
                        MoteMaker.ThrowMetaIcon(pawn.Position, pawn.Map, ThingDefOf.Mote_Heart);
                        xxx.sexTick(pawn, Partner);
                    }
                });
                get_loved.socialMode = RandomSocialMode.Off;
                yield return(get_loved);
            }
        }
Exemple #9
0
        //What should we do?
        protected override IEnumerable <Toil> MakeNewToils()
        {
            //Check it out. Can we go there?
            this.FailOnDespawnedNullOrForbidden(TargetIndex.A);

            //Wait a minute, is this thing already playing?
            if (!Gramophone.IsOn())
            {
                if (job.targetA.Thing is Building_Radio)
                {
                    report = "playing the radio.";
                }

                // Toil 1:
                // Reserve Target (TargetPack A is selected (It has the info where the target cell is))
                yield return(Toils_Reserve.Reserve(TargetIndex.A));

                // Toil 2:
                // Go to the thing.
                yield return(Toils_Goto.GotoThing(TargetIndex.A, PathEndMode.Touch));

                // Toil 3:
                // Wind up the gramophone
                var wind = new Toil
                {
                    defaultCompleteMode = ToilCompleteMode.Delay,
                    defaultDuration     = Duration
                };
                wind.WithProgressBarToilDelay(TargetIndex.A);
                wind.PlaySustainerOrSound(job.targetA.Thing is Building_Radio
                    ? DefDatabase <SoundDef> .GetNamed("Estate_RadioSeeking")
                    : DefDatabase <SoundDef> .GetNamed("Estate_GramophoneWindup"));

                wind.initAction = delegate { Gramophone.StopMusic(); };
                yield return(wind);

                // Toil 4:
                // Play music.

                var toilPlayMusic = new Toil
                {
                    defaultCompleteMode = ToilCompleteMode.Instant,
                    initAction          = delegate { Gramophone.PlayMusic(pawn); }
                };
                yield return(toilPlayMusic);
            }

            Toil toil;

            if (TargetC.HasThing && TargetC.Thing is Building_Bed bed) //If we have a bed, lie in bed to listen.
            {
                this.KeepLyingDown(TargetIndex.C);
                yield return(Toils_Reserve.Reserve(TargetIndex.C, bed.SleepingSlotsCount));

                yield return(Toils_Bed.ClaimBedIfNonMedical(TargetIndex.C));

                yield return(Toils_Bed.GotoBed(TargetIndex.C));

                toil = Toils_LayDown.LayDown(TargetIndex.C, true, false);
                toil.AddFailCondition(() => !pawn.Awake());
            }
            else
            {
                if (TargetC.HasThing)
                {
                    yield return(Toils_Reserve.Reserve(TargetIndex.C));
                }

                yield return(Toils_Goto.GotoCell(TargetIndex.B, PathEndMode.OnCell));

                toil = new Toil();
            }

            toil.AddPreTickAction(delegate
            {
                ListenTickAction();
                if (job.targetA.Thing is Building_Radio)
                {
                    report = "Listening to the radio.";
                }
            });
            toil.AddFinishAction(delegate { JoyUtility.TryGainRecRoomThought(pawn); });
            toil.defaultCompleteMode = ToilCompleteMode.Delay;
            toil.defaultDuration     = job.def.joyDuration;
            yield return(toil);
        }
        protected override IEnumerable <Toil> MakeNewToils()
        {
            //--Log.Message("[RJW]JobDriver_GettinLoved::MakeNewToils is called");

            float partner_ability = xxx.get_sex_ability(Partner);

            // More/less hearts based on partner ability.
            if (partner_ability < 0.8f)
            {
                tick_interval += 100;
            }
            else if (partner_ability > 2.0f)
            {
                tick_interval -= 25;
            }

            // More/less hearts based on opinion.
            if (pawn.relations.OpinionOf(Partner) < 0)
            {
                tick_interval += 50;
            }
            else if (pawn.relations.OpinionOf(Partner) > 60)
            {
                tick_interval -= 25;
            }

            if (Partner.CurJob.def == xxx.casual_sex)
            {
                this.FailOnDespawnedOrNull(ipartner);
                this.FailOn(() => !Partner.health.capacities.CanBeAwake);
                this.FailOn(() => pawn.Drafted);
                this.KeepLyingDown(ibed);
                yield return(Toils_Reserve.Reserve(ipartner, 1, 0));

                yield return(Toils_Reserve.Reserve(ibed, Bed.SleepingSlotsCount, 0));

                Toil get_loved = Toils_LayDown.LayDown(ibed, true, false, false, false);
                get_loved.FailOn(() => Partner.CurJob == null || Partner.CurJob.def != xxx.casual_sex);
                get_loved.defaultCompleteMode = ToilCompleteMode.Never;
                get_loved.AddPreTickAction(delegate
                {
                    if (pawn.IsHashIntervalTick(tick_interval))
                    {
                        MoteMaker.ThrowMetaIcon(pawn.Position, pawn.Map, ThingDefOf.Mote_Heart);
                        xxx.sexTick(pawn, Partner);
                    }
                });
                get_loved.socialMode = RandomSocialMode.Off;
                yield return(get_loved);
            }
            else if (Partner.CurJob.def == xxx.whore_is_serving_visitors)
            {
                this.FailOnDespawnedOrNull(ipartner);
                this.FailOn(() => !Partner.health.capacities.CanBeAwake || Partner.CurJob == null);
                yield return(Toils_Goto.GotoThing(ipartner, PathEndMode.OnCell));

                yield return(Toils_Reserve.Reserve(ipartner, 1, 0));

                Toil get_loved = new Toil();
                get_loved.FailOn(() => (Partner.CurJob.def != xxx.whore_is_serving_visitors));
                get_loved.defaultCompleteMode = ToilCompleteMode.Never;
                get_loved.initAction          = delegate
                {
                    //--Log.Message("[RJW]JobDriver_GettinLoved::MakeNewToils - w***e section is called");
                };
                get_loved.AddPreTickAction(delegate
                {
                    if (pawn.IsHashIntervalTick(tick_interval))
                    {
                        MoteMaker.ThrowMetaIcon(pawn.Position, pawn.Map, ThingDefOf.Mote_Heart);
                        xxx.sexTick(pawn, Partner);
                    }
                });
                get_loved.socialMode = RandomSocialMode.Off;
                yield return(get_loved);
            }
            else if (Partner.CurJob.def == xxx.bestialityForFemale)
            {
                this.FailOnDespawnedOrNull(ipartner);
                this.FailOn(() => !Partner.health.capacities.CanBeAwake || Partner.CurJob == null);
                yield return(Toils_Goto.GotoThing(ipartner, PathEndMode.OnCell));

                yield return(Toils_Reserve.Reserve(ipartner, 1, 0));

                Toil get_loved = new Toil();
                get_loved.FailOn(() => (Partner.CurJob.def != xxx.bestialityForFemale));
                get_loved.defaultCompleteMode = ToilCompleteMode.Never;
                get_loved.initAction          = delegate
                {
                    //--Log.Message("[RJW]JobDriver_GettinLoved::MakeNewToils - bestialityForFemale section is called");
                };
                get_loved.AddPreTickAction(delegate
                {
                    if (pawn.IsHashIntervalTick(tick_interval))
                    {
                        MoteMaker.ThrowMetaIcon(pawn.Position, pawn.Map, ThingDefOf.Mote_Heart);
                        xxx.sexTick(pawn, Partner);
                    }
                });
                get_loved.socialMode = RandomSocialMode.Off;
                yield return(get_loved);
            }
        }