diff --git a/Defs/WorkGiverDefs/WorkGivers_CleanSelf.xml b/Defs/WorkGiverDefs/WorkGivers_CleanSelf.xml
new file mode 100644
index 0000000..943e37a
--- /dev/null
+++ b/Defs/WorkGiverDefs/WorkGivers_CleanSelf.xml
@@ -0,0 +1,17 @@
+
+
+
+ CleanSelfwithBucket
+
+ RJWSexperience.Cum.WorkGiver_CleanSelfWithBucket
+ BasicWorker
+ collect cum into a
+ collecting cum into a
+ false
+ 12
+ true
+
+ Manipulation
+
+
+
\ No newline at end of file
diff --git a/RJWSexperience/RJWSexperience/Cum/WorkGiver_CleanSelfWithBucket.cs b/RJWSexperience/RJWSexperience/Cum/WorkGiver_CleanSelfWithBucket.cs
new file mode 100644
index 0000000..82be841
--- /dev/null
+++ b/RJWSexperience/RJWSexperience/Cum/WorkGiver_CleanSelfWithBucket.cs
@@ -0,0 +1,37 @@
+using RimWorld;
+using rjw;
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using Verse;
+using Verse.AI;
+
+namespace RJWSexperience.Cum
+{
+ public class WorkGiver_CleanSelfWithBucket : WorkGiver_Scanner
+ {
+ public override ThingRequest PotentialWorkThingRequest => ThingRequest.ForDef(VariousDefOf.CumBucket);
+ public override PathEndMode PathEndMode => PathEndMode.ClosestTouch;
+ public override bool ShouldSkip(Pawn pawn, bool forced = false)
+ {
+ return !pawn.health.hediffSet.HasHediff(RJW_SemenoOverlayHediffDefOf.Hediff_Bukkake);
+ }
+
+ public override bool HasJobOnThing(Pawn pawn, Thing t, bool forced = false)
+ {
+ if (!(t is Building_CumBucket bucket))
+ return false;
+
+ List thingsInBucket = bucket.Map.thingGrid.ThingsListAt(bucket.Position);
+
+ int stackInBucket = thingsInBucket.Select(thing => thing.stackCount).Aggregate((sum, x) => sum + x);
+
+ return stackInBucket < VariousDefOf.GatheredCum.stackLimit;
+ }
+
+ public override Job JobOnThing(Pawn pawn, Thing t, bool forced = false)
+ {
+ return JobMaker.MakeJob(VariousDefOf.CleanSelfwithBucket, pawn, t);
+ }
+ }
+}
diff --git a/RJWSexperience/RJWSexperience/Patches/Rimworld_Patch.cs b/RJWSexperience/RJWSexperience/Patches/Rimworld_Patch.cs
index 6c8db3f..aaf6351 100644
--- a/RJWSexperience/RJWSexperience/Patches/Rimworld_Patch.cs
+++ b/RJWSexperience/RJWSexperience/Patches/Rimworld_Patch.cs
@@ -1,9 +1,6 @@
using HarmonyLib;
-using RimWorld;
using rjw;
using System;
-using System.Collections.Generic;
-using UnityEngine;
using Verse;
namespace RJWSexperience
@@ -20,33 +17,4 @@ namespace RJWSexperience
__result.AddVirginTrait();
}
}
-
- [HarmonyPatch(typeof(FloatMenuMakerMap), "AddHumanlikeOrders")]
- public static class HumanlikeOrder_Patch
- {
- public static void Postfix(Vector3 clickPos, Pawn pawn, List opts)
- {
- var targets = GenUI.TargetsAt(clickPos, TargetingParameters.ForBuilding());
-
- if (pawn.health.hediffSet.HasHediff(RJW_SemenoOverlayHediffDefOf.Hediff_Bukkake))
- foreach (LocalTargetInfo t in targets)
- {
- if (t.Thing is Building_CumBucket building)
- {
- opts.AddDistinct(MakeMenu(pawn, building));
- break;
- }
- }
- }
-
- public static FloatMenuOption MakeMenu(Pawn pawn, LocalTargetInfo target)
- {
- FloatMenuOption option = FloatMenuUtility.DecoratePrioritizedTask(new FloatMenuOption(Keyed.RS_FloatMenu_CleanSelf, delegate ()
- {
- pawn.jobs.TryTakeOrderedJob(new Verse.AI.Job(VariousDefOf.CleanSelfwithBucket, null, target, target.Cell));
- }, MenuOptionPriority.Low), pawn, target);
-
- return option;
- }
- }
}
diff --git a/RJWSexperience/RJWSexperience/VariousDefOf.cs b/RJWSexperience/RJWSexperience/VariousDefOf.cs
index 8007993..ac33dac 100644
--- a/RJWSexperience/RJWSexperience/VariousDefOf.cs
+++ b/RJWSexperience/RJWSexperience/VariousDefOf.cs
@@ -21,6 +21,7 @@ namespace RJWSexperience
public static readonly RecordDef SexPartnerCount = DefDatabase.GetNamed("SexPartnerCount");
public static readonly RecordDef OrgasmCount = DefDatabase.GetNamed("OrgasmCount");
public static readonly SkillDef SexSkill = DefDatabase.GetNamed("Sex");
+ public static readonly ThingDef CumBucket = DefDatabase.GetNamed("CumBucket");
public static readonly ThingDef GatheredCum = DefDatabase.GetNamed("GatheredCum");
public static readonly ThingDef FilthCum = ThingDef.Named("FilthCum");
public static readonly HediffDef CumAddiction = DefDatabase.GetNamed("CumAddiction");