diff --git a/Mods/Sexperience/Defs/HediffDefs/Sexperience_HediffDefs.xml b/Mods/Sexperience/Defs/HediffDefs/Sexperience_HediffDefs.xml
index 0a63095..f890bd9 100644
--- a/Mods/Sexperience/Defs/HediffDefs/Sexperience_HediffDefs.xml
+++ b/Mods/Sexperience/Defs/HediffDefs/Sexperience_HediffDefs.xml
@@ -14,6 +14,14 @@
-0.5
+
+
+ 0
+ 0.5
+ 0.25
+ 0.1
+
+
diff --git a/Mods/Sexperience/Defs/JobDefs/Sexperience_JobProcessCumbucket.xml b/Mods/Sexperience/Defs/JobDefs/Sexperience_JobProcessCumbucket.xml
new file mode 100644
index 0000000..2c42bea
--- /dev/null
+++ b/Mods/Sexperience/Defs/JobDefs/Sexperience_JobProcessCumbucket.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+ ProcessCumbucket
+ RJW_Genes.JobDriver_ProcessingCumbucket
+ true
+ false
+ processing internal cumbucket.
+ false
+
+
+
diff --git a/Source/Genes/Cum/HediffComp_ProcessCumbucket.cs b/Source/Genes/Cum/HediffComp_ProcessCumbucket.cs
new file mode 100644
index 0000000..db3b544
--- /dev/null
+++ b/Source/Genes/Cum/HediffComp_ProcessCumbucket.cs
@@ -0,0 +1,29 @@
+
+using RimWorld;
+using System;
+using Verse;
+
+namespace RJW_Genes
+{
+ public class HediffComp_ProcessCumbucket : HediffComp
+ {
+ public HediffsCompProperties_ProcessCumbucketMTB Props
+ {
+ get
+ {
+ return (HediffsCompProperties_ProcessCumbucketMTB)this.props;
+ }
+ }
+
+ public override void CompPostTick(ref float severityAdjustment)
+ {
+ ModLog.Debug("Running HediffComp_ProcessCumbucket CompPostTick");
+ if (this.Props.mtbDaysPerStage[this.parent.CurStageIndex] > 0f && base.Pawn.IsHashIntervalTick(60) && Rand.MTBEventOccurs(this.Props.mtbDaysPerStage[this.parent.CurStageIndex], 60000f, 60f))
+ {
+
+ ModLog.Debug("Firing HediffComp_ProcessCumbucket CompPostTick");
+ this.Pawn.jobs.StartJob(JobMaker.MakeJob(DefDatabase.GetNamed("ProcessCumbucket")), lastJobEndCondition: Verse.AI.JobCondition.InterruptForced, resumeCurJobAfterwards: true);
+ }
+ }
+ }
+}
diff --git a/Source/Genes/Cum/HediffsCompProperties_ProcessCumbucketMTB.cs b/Source/Genes/Cum/HediffsCompProperties_ProcessCumbucketMTB.cs
new file mode 100644
index 0000000..194b883
--- /dev/null
+++ b/Source/Genes/Cum/HediffsCompProperties_ProcessCumbucketMTB.cs
@@ -0,0 +1,36 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+using Verse;
+
+namespace RJW_Genes
+{
+ public class HediffsCompProperties_ProcessCumbucketMTB : HediffCompProperties
+ {
+ public HediffsCompProperties_ProcessCumbucketMTB()
+ {
+ this.compClass = typeof(HediffsCompProperties_ProcessCumbucketMTB);
+ }
+
+ public override IEnumerable ConfigErrors(HediffDef parentDef)
+ {
+ foreach (string text in base.ConfigErrors(parentDef))
+ {
+ yield return text;
+ }
+ if (this.mtbDaysPerStage == null)
+ {
+ yield return "mtbDaysPerStage is not defined";
+ }
+ else if (this.mtbDaysPerStage.Count != parentDef.stages.Count)
+ {
+ yield return "mtbDaysPerStage count doesn't match Hediffs number of stages";
+ }
+ yield break;
+ }
+
+ public List mtbDaysPerStage;
+ }
+}
diff --git a/Source/Genes/Cum/JobDriver_ProcessingCumbucket.cs b/Source/Genes/Cum/JobDriver_ProcessingCumbucket.cs
new file mode 100644
index 0000000..e1910b5
--- /dev/null
+++ b/Source/Genes/Cum/JobDriver_ProcessingCumbucket.cs
@@ -0,0 +1,97 @@
+using LicentiaLabs;
+using System.Collections.Generic;
+using Verse;
+using Verse.AI;
+using UnityEngine;
+using System;
+using rjw;
+using RimWorld;
+
+namespace RJW_Genes
+{
+ ///
+ /// Shamelessly stolen from LicentaLabs
+ /// [Jaals Fork] https://gitgud.io/Jaaldabaoth/licentia-labs/-/blob/master/Source/LicentiaLabs/LicentiaLabs/JobDriver_VomitCum.cs
+ ///
+ class JobDriver_ProcessingCumbucket : JobDriver_Vomit
+ {
+ public override bool CanBeginNowWhileLyingDown()
+ {
+ return true;
+ }
+
+ protected override IEnumerable MakeNewToils()
+ {
+ if (ModsConfig.IsActive("rjw.sexperience"))
+ yield break;
+
+ ModLog.Debug("Starting Toils for Processing Cumbucket");
+
+ Toil toil = new Toil();
+ toil.initAction = delegate ()
+ {
+ this.ticksLeft = Rand.Range(150, 600);
+ int num = 0;
+ IntVec3 c;
+ for (; ; )
+ {
+ c = this.pawn.Position + GenAdj.AdjacentCellsAndInside[Rand.Range(0, 9)];
+ num++;
+ if (num > 12)
+ {
+ break;
+ }
+ if (c.InBounds(this.pawn.Map) && c.Standable(this.pawn.Map))
+ {
+ goto IL_77;
+ }
+ }
+ c = this.pawn.Position;
+ IL_77:
+ this.job.targetA = c;
+ this.pawn.pather.StopDead();
+ };
+ toil.tickAction = delegate ()
+ {
+ if (this.ticksLeft % 150 == 149)
+ {
+ if (!sourceName.NullOrEmpty())
+ {
+ if (ModsConfig.IsActive("LustLicentia.RJWLabs"))
+ FilthMaker.TryMakeFilth(this.job.targetA.Cell, base.Map, Licentia.ThingDefs.FilthCum, sourceName);
+ SpawnCum(this.pawn, this.job.targetA.Cell, base.Map);
+ }
+ else
+ {
+ if (ModsConfig.IsActive("LustLicentia.RJWLabs"))
+ FilthMaker.TryMakeFilth(this.job.targetA.Cell, base.Map, Licentia.ThingDefs.FilthCum);
+ SpawnCum(this.pawn, this.job.targetA.Cell, base.Map);
+ }
+ }
+ this.ticksLeft--;
+ if (this.ticksLeft <= 0)
+ {
+ base.ReadyForNextToil();
+ TaleRecorder.RecordTale(Licentia.TaleDefs.VomitedCum, new object[]
+ {
+ this.pawn
+ });
+ }
+ };
+ toil.defaultCompleteMode = ToilCompleteMode.Never;
+ toil.WithEffect(EffecterDefOf.Vomit, TargetIndex.A, new Color(100f, 100f, 100f, 0.5f));
+ toil.PlaySustainerOrSound(() => SoundDefOf.Vomit, 1f);
+ yield return toil;
+ yield break;
+ }
+
+ private void SpawnCum(Pawn pawn, IntVec3 cell, Map map)
+ {
+ ModLog.Warning($"This will be spawning cum for {pawn} at {cell}");
+ }
+
+ private int ticksLeft;
+
+ public string sourceName;
+ }
+}
diff --git a/Source/Genes/Cum/Patches/Patch_LivingCumbucket_StackHediff.cs b/Source/Genes/Cum/Patches/Patch_LivingCumbucket_StackHediff.cs
index 030b784..67ec45e 100644
--- a/Source/Genes/Cum/Patches/Patch_LivingCumbucket_StackHediff.cs
+++ b/Source/Genes/Cum/Patches/Patch_LivingCumbucket_StackHediff.cs
@@ -17,7 +17,7 @@ namespace RJW_Genes
///
/// This is the amount of fluid required if the pawn has a bodysize of 1, to reach a severity in the hediff of 1.
- /// The hediff can still be increased.
+ /// The hediff can still be increased over 1.0.
///
const float fluid_amount_required_for_hediff_severity_ = 100.0f;
@@ -48,7 +48,6 @@ namespace RJW_Genes
{
float bodysize = pawn.BodySize;
float result_severity_increase = cumamount / (fluid_amount_required_for_hediff_severity_ * bodysize);
- ModLog.Message($"Pumping the living cumbucket {pawn} (Bodysize {bodysize}) with {cumamount} cum, resulting in severity {result_severity_increase}");
Hediff hediff = pawn.health.hediffSet.GetFirstHediffOfDef(HediffDefOf.rjw_genes_filled_living_cumbucket);
@@ -59,6 +58,7 @@ namespace RJW_Genes
}
hediff.Severity += result_severity_increase;
+ ModLog.Debug($"Pumping the living cumbucket {pawn} (Bodysize {bodysize}) with {cumamount} cum, resulting in severity {hediff.Severity} (+{result_severity_increase})");
}
}
}
diff --git a/Source/Rjw-Genes.csproj b/Source/Rjw-Genes.csproj
index 41ad6da..05e2ed3 100644
--- a/Source/Rjw-Genes.csproj
+++ b/Source/Rjw-Genes.csproj
@@ -82,6 +82,9 @@
+
+
+