mirror of
https://github.com/vegapnk/RJW-Genes.git
synced 2024-08-15 00:23:31 +00:00
Compare commits
10 commits
3578e9eb9b
...
7f1fa01abd
Author | SHA1 | Date | |
---|---|---|---|
|
7f1fa01abd | ||
|
13630e6e7c | ||
|
d1129fece2 | ||
|
1b547094fe | ||
|
1e667e2730 | ||
|
05770a834e | ||
|
bd1ef6d5a2 | ||
|
913f1aad3e | ||
|
ba75f6b636 | ||
|
eb5e3bce81 |
24 changed files with 467 additions and 57 deletions
10
CHANGELOG.md
10
CHANGELOG.md
|
@ -101,8 +101,7 @@ and might try to add a gene that already exists - then nothing happens.
|
|||
- (Major) No Penis
|
||||
- (Major) Minor Vulnerability
|
||||
|
||||
These are currently hardcoded but I can change them on popular demand.
|
||||
In general minor changes are only cosmetic and wont change metabolism.
|
||||
You can configure all genes, as well as their application chance, in the Genes` XML.
|
||||
|
||||
*Why are these changes Genetic?*
|
||||
Because this is the genes mod, and I find things here quite robust.
|
||||
|
@ -142,6 +141,7 @@ Because this is the genes mod, and I find things here quite robust.
|
|||
- Fixed an Issue where pawns would always get the Pheromone social boost, unless they had the pheromone (#113)
|
||||
- Fixed two hidden dependencies on Ideology and Royalty (#115)
|
||||
- Fixed some more hidden dependencies on Ideology Icons (#118)
|
||||
- Fixed a hidden dependency on Licentialabs (#119)
|
||||
|
||||
**Internal:**
|
||||
|
||||
|
@ -174,6 +174,12 @@ You can now support me with [buying me a coffee](https://buymeacoffee.com/vegapn
|
|||
The mod will remain free, open source and I will not hide or lock any features.
|
||||
Its just meant if you want to drop me a tip.
|
||||
|
||||
**Since Beta-1** (11-07-2024)
|
||||
|
||||
- Made the Feminizer and Twinkifier configurable with XML.
|
||||
- Typos in the Hediff Defs, tweaking of some values.
|
||||
|
||||
|
||||
# 2.1.0 (27-06-2024)
|
||||
|
||||
**Additions**:
|
||||
|
|
|
@ -125,7 +125,7 @@
|
|||
<WorkSpeedGlobal>-0.1</WorkSpeedGlobal>
|
||||
<Fertility>1.2</Fertility>
|
||||
<SexFrequency>1.2</SexFrequency>
|
||||
<MentalBreakThreshold>-0.15</MentalBreakThreshold>
|
||||
<MentalBreakThreshold>+0.15</MentalBreakThreshold>
|
||||
<GlobalLearningFactor>-0.1</GlobalLearningFactor>
|
||||
</statOffsets>
|
||||
</li>
|
||||
|
@ -141,7 +141,7 @@
|
|||
<statOffsets>
|
||||
<MoveSpeed>0.15</MoveSpeed>
|
||||
<WorkSpeedGlobal>0.25</WorkSpeedGlobal>
|
||||
<MentalBreakThreshold>0.25</MentalBreakThreshold>
|
||||
<MentalBreakThreshold>-0.25</MentalBreakThreshold>
|
||||
</statOffsets>
|
||||
</li>
|
||||
</conditionalStatAffecters>
|
||||
|
|
|
@ -203,9 +203,23 @@
|
|||
<applicableForMen>true</applicableForMen>
|
||||
<requiresPenetrativeSex>false</requiresPenetrativeSex>
|
||||
</li>
|
||||
<li Class="RJW_Genes.GeneAlteringExtension">
|
||||
<majorGenes>
|
||||
<li>rjw_genes_female_only</li>
|
||||
<li>rjw_genes_no_penis</li>
|
||||
<li>rjw_genes_minor_vulnerability</li>
|
||||
</majorGenes>
|
||||
<minorGenes>
|
||||
<li>rjw_genes_small_male_genitalia</li>
|
||||
<li>rjw_genes_big_breasts</li>
|
||||
<li>Beard_NoBeardOnly</li>
|
||||
<li>Hair_LongOnly</li>
|
||||
</minorGenes>
|
||||
<minorApplicationChance>0.25</minorApplicationChance>
|
||||
<majorApplicationChance>0.1</majorApplicationChance>
|
||||
</li>
|
||||
</modExtensions>
|
||||
</GeneDef>
|
||||
|
||||
|
||||
<GeneDef ParentName="SpecialBase">
|
||||
<defName>rjw_genes_twinkifier</defName>
|
||||
|
@ -230,6 +244,23 @@
|
|||
<applicableForMen>true</applicableForMen>
|
||||
<requiresPenetrativeSex>false</requiresPenetrativeSex>
|
||||
</li>
|
||||
<li Class="RJW_Genes.GeneAlteringExtension">
|
||||
<majorGenes>
|
||||
<li>rjw_genes_fertile_anus</li>
|
||||
<li>Beauty_Pretty</li>
|
||||
<li>Delicate</li>
|
||||
<li>rjw_genes_minor_vulnerability</li>
|
||||
<li>rjw_genes_infectious_homosexuality</li>
|
||||
</majorGenes>
|
||||
<minorGenes>
|
||||
<li>rjw_genes_small_male_genitalia</li>
|
||||
<li>Beard_NoBeardOnly</li>
|
||||
<li>Body_Thin</li>
|
||||
<li>rjw_genes_homosexual</li>
|
||||
</minorGenes>
|
||||
<minorApplicationChance>0.25</minorApplicationChance>
|
||||
<majorApplicationChance>0.1</majorApplicationChance>
|
||||
</li>
|
||||
</modExtensions>
|
||||
</GeneDef>
|
||||
|
||||
|
|
|
@ -102,7 +102,7 @@
|
|||
<capMods>
|
||||
<li>
|
||||
<capacity>Consciousness</capacity>
|
||||
<offset>-0.5</offset>
|
||||
<offset>-0.05</offset>
|
||||
</li>
|
||||
</capMods>
|
||||
<statOffsets>
|
||||
|
|
|
@ -16,5 +16,6 @@
|
|||
<li IfModActive="vanillaracesexpanded.android">Mods/Android</li>
|
||||
<li IfModActive="VanillaExpanded.VGeneticsE">Mods/VE_Genetics</li>
|
||||
<li IfModActive="LustLicentia.RJWLabs">Mods/LicentiaLabs</li>
|
||||
<li IfModActive="rjw.sexperience">Mods/Sexperience</li>
|
||||
</v1.5>
|
||||
</loadFolders>
|
|
@ -98,15 +98,6 @@
|
|||
<li Class="HediffCompProperties_SeverityPerDay">
|
||||
<severityPerDay>-0.75</severityPerDay>
|
||||
</li>
|
||||
<li Class="LicentiaLabs.Hediffs.HediffCompProperties_VomitCumMtb">
|
||||
<mtbDaysPerStage>
|
||||
<li>0</li>
|
||||
<li>0</li>
|
||||
<li>0.75</li>
|
||||
<li>0.5</li>
|
||||
<li>0.2</li>
|
||||
</mtbDaysPerStage>
|
||||
</li>
|
||||
</comps>
|
||||
<stages>
|
||||
<li>
|
20
Mods/Sexperience/Defs/GeneDefs/Sexperience_GeneDefs.xml
Normal file
20
Mods/Sexperience/Defs/GeneDefs/Sexperience_GeneDefs.xml
Normal file
|
@ -0,0 +1,20 @@
|
|||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<Defs>
|
||||
|
||||
<GeneDef>
|
||||
<defName>rjw_genes_living_cumbucket</defName>
|
||||
<label>living cumbucket</label>
|
||||
<displayCategory>rjw_genes_cum</displayCategory>
|
||||
<description>When this Xenotype partakes in sexual activity, they store cum and produce it as an item.</description>
|
||||
<iconPath>Genes/Icons/Generous_Donor</iconPath>
|
||||
<displayOrderInCategory>559</displayOrderInCategory>
|
||||
|
||||
<modExtensions>
|
||||
<li MayRequire="OskarPotocki.VanillaFactionsExpanded.Core" Class="VanillaGenesExpanded.GeneExtension">
|
||||
<backgroundPathEndogenes>Genes/Icons/RJW_Genes_Endogene_Background</backgroundPathEndogenes>
|
||||
<backgroundPathXenogenes>Genes/Icons/RJW_Genes_Xenogene_Background</backgroundPathXenogenes>
|
||||
</li>
|
||||
</modExtensions>
|
||||
</GeneDef>
|
||||
|
||||
</Defs>
|
94
Mods/Sexperience/Defs/HediffDefs/Sexperience_HediffDefs.xml
Normal file
94
Mods/Sexperience/Defs/HediffDefs/Sexperience_HediffDefs.xml
Normal file
|
@ -0,0 +1,94 @@
|
|||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<Defs>
|
||||
<HediffDef>
|
||||
<defName>rjw_genes_filled_living_cumbucket</defName>
|
||||
<hediffClass>HediffWithComps</hediffClass>
|
||||
<label>filled living cumbucket</label>
|
||||
<description>This pawn is a (filled) living cum bucket. Thanks to a generous donation, this pawn will slowly generate cum for pickup.</description>
|
||||
<defaultLabelColor>(240,200,110)</defaultLabelColor>
|
||||
<scenarioCanAdd>false</scenarioCanAdd>
|
||||
<!-- <maxSeverity>1.0</maxSeverity> -->
|
||||
<isBad>false</isBad>
|
||||
<tendable>false</tendable>
|
||||
<comps>
|
||||
<li Class="HediffCompProperties_SeverityPerDay">
|
||||
<severityPerDay>-0.5</severityPerDay>
|
||||
</li>
|
||||
<li Class="RJW_Genes.HediffsCompProperties_ProcessCumbucketMTB">
|
||||
<mtbDaysPerStage>
|
||||
<li>0</li>
|
||||
<li>0.5</li>
|
||||
<li>0.25</li>
|
||||
<li>0.1</li>
|
||||
<li>0.005</li>
|
||||
</mtbDaysPerStage>
|
||||
</li>
|
||||
</comps>
|
||||
<stages>
|
||||
<li>
|
||||
<label>slight</label>
|
||||
<statOffsets>
|
||||
<Vulnerability>-0.1</Vulnerability>
|
||||
</statOffsets>
|
||||
</li>
|
||||
<li>
|
||||
<label>moderate</label>
|
||||
<minSeverity>0.4</minSeverity>
|
||||
<hungerRateFactor>0.8</hungerRateFactor>
|
||||
<statOffsets>
|
||||
<Vulnerability>-0.25</Vulnerability>
|
||||
</statOffsets>
|
||||
<capMods>
|
||||
<li>
|
||||
<capacity>Moving</capacity>
|
||||
<offset>-0.05</offset>
|
||||
</li>
|
||||
</capMods>
|
||||
</li>
|
||||
<li>
|
||||
<label>full</label>
|
||||
<minSeverity>0.65</minSeverity>
|
||||
<hungerRateFactor>0.75</hungerRateFactor>
|
||||
<statOffsets>
|
||||
<Vulnerability>-0.25</Vulnerability>
|
||||
</statOffsets>
|
||||
<capMods>
|
||||
<li>
|
||||
<capacity>Moving</capacity>
|
||||
<offset>-0.1</offset>
|
||||
</li>
|
||||
</capMods>
|
||||
</li>
|
||||
<li>
|
||||
<label>over-full</label>
|
||||
<minSeverity>1.1</minSeverity>
|
||||
<hungerRateFactor>0.6</hungerRateFactor>
|
||||
<statOffsets>
|
||||
<Vulnerability>-0.5</Vulnerability>
|
||||
</statOffsets>
|
||||
<capMods>
|
||||
<li>
|
||||
<capacity>Moving</capacity>
|
||||
<offset>-0.15</offset>
|
||||
</li>
|
||||
</capMods>
|
||||
</li>
|
||||
<li>
|
||||
<label>living fountain</label>
|
||||
<minSeverity>10.1</minSeverity>
|
||||
<hungerRateFactor>0.1</hungerRateFactor>
|
||||
<statOffsets>
|
||||
<Vulnerability>-1.5</Vulnerability>
|
||||
</statOffsets>
|
||||
<capMods>
|
||||
<li>
|
||||
<capacity>Moving</capacity>
|
||||
<offset>-0.55</offset>
|
||||
</li>
|
||||
</capMods>
|
||||
</li>
|
||||
</stages>
|
||||
</HediffDef>
|
||||
|
||||
|
||||
</Defs>
|
|
@ -0,0 +1,15 @@
|
|||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<Defs>
|
||||
|
||||
<!--========= General ============-->
|
||||
|
||||
<JobDef>
|
||||
<defName>ProcessCumbucket</defName>
|
||||
<driverClass>RJW_Genes.JobDriver_ProcessingCumbucket</driverClass>
|
||||
<playerInterruptible>true</playerInterruptible>
|
||||
<casualInterruptible>false</casualInterruptible>
|
||||
<reportString>processing internal cumbucket.</reportString>
|
||||
<suspendable>false</suspendable>
|
||||
</JobDef>
|
||||
|
||||
</Defs>
|
|
@ -83,6 +83,7 @@ namespace RJW_Genes
|
|||
[MayRequire("LustLicentia.RJWLabs")] public static readonly GeneDef rjw_genes_likes_cumflation;
|
||||
[MayRequire("LustLicentia.RJWLabs")] public static readonly GeneDef rjw_genes_cumflation_immunity;
|
||||
[MayRequire("LustLicentia.RJWLabs")] public static readonly GeneDef rjw_genes_generous_donor;
|
||||
[MayRequire("rjw.sexperience")] public static readonly GeneDef rjw_genes_living_cumbucket;
|
||||
|
||||
|
||||
// Reproduction
|
||||
|
|
28
Source/Genes/Cum/HediffComp_ProcessCumbucket.cs
Normal file
28
Source/Genes/Cum/HediffComp_ProcessCumbucket.cs
Normal file
|
@ -0,0 +1,28 @@
|
|||
|
||||
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)
|
||||
{
|
||||
if (this.Props.mtbDaysPerStage[this.parent.CurStageIndex] > 0f && base.Pawn.IsHashIntervalTick(60) && Rand.MTBEventOccurs(this.Props.mtbDaysPerStage[this.parent.CurStageIndex], 60000f, 60f))
|
||||
{
|
||||
ModLog.Debug($"Triggered HediffComp_ProcessCumbucket CompPostTick - Starting a JobDriver ProcessCumbucket for {this.parent.pawn}");
|
||||
this.Pawn.jobs.StartJob(JobMaker.MakeJob(DefDatabase<JobDef>.GetNamed("ProcessCumbucket")), lastJobEndCondition: Verse.AI.JobCondition.InterruptForced, resumeCurJobAfterwards: true);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
|
@ -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(HediffComp_ProcessCumbucket);
|
||||
}
|
||||
|
||||
public override IEnumerable<string> 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<float> mtbDaysPerStage;
|
||||
}
|
||||
}
|
112
Source/Genes/Cum/JobDriver_ProcessingCumbucket.cs
Normal file
112
Source/Genes/Cum/JobDriver_ProcessingCumbucket.cs
Normal file
|
@ -0,0 +1,112 @@
|
|||
using LicentiaLabs;
|
||||
using System.Collections.Generic;
|
||||
using Verse;
|
||||
using Verse.AI;
|
||||
using UnityEngine;
|
||||
using System;
|
||||
using rjw;
|
||||
using RimWorld;
|
||||
|
||||
namespace RJW_Genes
|
||||
{
|
||||
/// <summary>
|
||||
/// Shamelessly stolen from LicentaLabs
|
||||
/// [Jaals Fork] https://gitgud.io/Jaaldabaoth/licentia-labs/-/blob/master/Source/LicentiaLabs/LicentiaLabs/JobDriver_VomitCum.cs
|
||||
/// </summary>
|
||||
class JobDriver_ProcessingCumbucket : JobDriver_Vomit
|
||||
{
|
||||
public override bool CanBeginNowWhileLyingDown()
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
protected override IEnumerable<Toil> MakeNewToils()
|
||||
{
|
||||
if (!ModsConfig.IsActive("rjw.sexperience"))
|
||||
yield break;
|
||||
|
||||
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)
|
||||
{
|
||||
ThingDef cumDef = DefDatabase<ThingDef>.GetNamed("GatheredCum", true);
|
||||
|
||||
Hediff hediff = pawn.health.hediffSet.GetFirstHediffOfDef(HediffDefOf.rjw_genes_filled_living_cumbucket);
|
||||
if (hediff == null)
|
||||
{
|
||||
ModLog.Warning($"{pawn} has the JobDriver_ProcessCumbucket but does not have the Hediff for filled cumbucket.");
|
||||
return;
|
||||
}
|
||||
|
||||
Thing cum = ThingMaker.MakeThing(cumDef);
|
||||
cum.Position = cell;
|
||||
int stacks = Math.Max(1, (int)(hediff.Severity * 3));
|
||||
stacks = Math.Min(stacks, 75); // 75 is the default max stacksize ...
|
||||
cum.stackCount = stacks;
|
||||
cum.SpawnSetup(map, false);
|
||||
|
||||
//TODO: Reduce this ... better?
|
||||
hediff.Severity -= stacks / 50;
|
||||
}
|
||||
|
||||
private int ticksLeft;
|
||||
|
||||
public string sourceName;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,64 @@
|
|||
using HarmonyLib;
|
||||
using rjw;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using Verse;
|
||||
using static System.Net.Mime.MediaTypeNames;
|
||||
|
||||
namespace RJW_Genes
|
||||
{
|
||||
|
||||
[HarmonyPatch(typeof(SexUtility), nameof(SexUtility.SatisfyPersonal))]
|
||||
public class Patch_LivingCumbucket_StackHediff
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// 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 over 1.0.
|
||||
/// </summary>
|
||||
const float fluid_amount_required_for_hediff_severity_ = 100.0f;
|
||||
|
||||
public static void Postfix(SexProps props)
|
||||
{
|
||||
if (!ModsConfig.IsActive("rjw.sexperience"))
|
||||
return;
|
||||
|
||||
// ShortCuts: Exit Early if Pawn or Partner are null (can happen with Masturbation or other nieche-cases)
|
||||
if (props == null || props.pawn == null || !props.hasPartner())
|
||||
return;
|
||||
|
||||
Pawn pawnA = props.pawn;
|
||||
Pawn pawnB = props.partner;
|
||||
|
||||
if (pawnA.genes != null && pawnA.genes.HasActiveGene(GeneDefOf.rjw_genes_living_cumbucket) && CumUtility.GetTotalFluidAmount(pawnB) > 0)
|
||||
{
|
||||
ProcessLivingCumbucket(pawnA, CumUtility.GetTotalFluidAmount(pawnB));
|
||||
}
|
||||
|
||||
if (pawnB.genes != null && pawnB.genes.HasActiveGene(GeneDefOf.rjw_genes_living_cumbucket) && CumUtility.GetTotalFluidAmount(pawnA) > 0)
|
||||
{
|
||||
ProcessLivingCumbucket(pawnB, CumUtility.GetTotalFluidAmount(pawnA));
|
||||
}
|
||||
}
|
||||
|
||||
public static void ProcessLivingCumbucket(Pawn pawn, float cumamount)
|
||||
{
|
||||
float bodysize = pawn.BodySize;
|
||||
float result_severity_increase = cumamount / (fluid_amount_required_for_hediff_severity_ * bodysize);
|
||||
|
||||
|
||||
Hediff hediff = pawn.health.hediffSet.GetFirstHediffOfDef(HediffDefOf.rjw_genes_filled_living_cumbucket);
|
||||
if (hediff == null)
|
||||
{
|
||||
hediff = pawn.health.GetOrAddHediff(HediffDefOf.rjw_genes_filled_living_cumbucket);
|
||||
hediff.Severity = 0.01f;
|
||||
}
|
||||
|
||||
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})");
|
||||
}
|
||||
}
|
||||
}
|
|
@ -17,8 +17,6 @@ namespace RJW_Genes
|
|||
public abstract class Gene_GenitaliaResizingGene : RJW_Gene
|
||||
{
|
||||
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Whether or not the gene was already applied.
|
||||
/// If not, it is checked on every birthday and will be applied accordingly.
|
||||
|
|
18
Source/Genes/Special/Defs/GeneAlteringExtension.cs
Normal file
18
Source/Genes/Special/Defs/GeneAlteringExtension.cs
Normal file
|
@ -0,0 +1,18 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using Verse;
|
||||
|
||||
namespace RJW_Genes
|
||||
{
|
||||
public class GeneAlteringExtension : DefModExtension
|
||||
{
|
||||
public List<GeneDef> minorGenes;
|
||||
public List<GeneDef> majorGenes;
|
||||
|
||||
public float minorApplicationChance;
|
||||
public float majorApplicationChance;
|
||||
}
|
||||
}
|
|
@ -16,8 +16,8 @@ namespace RJW_Genes
|
|||
[HarmonyPatch(typeof(SexUtility), "Aftersex")]
|
||||
public static class Patch_Feminizer
|
||||
{
|
||||
const float MINOR_APPLICATION_CHANCE = 0.25f; // = 25% to have a minor transformation
|
||||
const float MAJOR_APPLICATION_CHANCE = 0.10f; // = 10% to have a major transformation
|
||||
|
||||
static GeneAlteringExtension geneAlteringExtension = GeneDefOf.rjw_genes_feminizer.GetModExtension<GeneAlteringExtension>();
|
||||
|
||||
public static void Postfix(SexProps props)
|
||||
{
|
||||
|
@ -26,6 +26,12 @@ namespace RJW_Genes
|
|||
if (props.pawn.IsAnimal() || props.partner.IsAnimal())
|
||||
return;
|
||||
|
||||
if (geneAlteringExtension == null)
|
||||
{
|
||||
ModLog.Warning("Did not find a (well-formed) GeneAlteringExtension for Feminizer");
|
||||
return;
|
||||
}
|
||||
|
||||
ApplyFeminization(props.pawn);
|
||||
ApplyFeminization(props.partner);
|
||||
}
|
||||
|
@ -44,12 +50,12 @@ namespace RJW_Genes
|
|||
{
|
||||
case float f when f > 0.8f:
|
||||
{
|
||||
if (Random.NextDouble() < MAJOR_APPLICATION_CHANCE)
|
||||
if (Random.NextDouble() < geneAlteringExtension.majorApplicationChance)
|
||||
MajorChange(pawn);
|
||||
} break;
|
||||
case float f when f > 0.6f:
|
||||
{
|
||||
if (Random.NextDouble() < MINOR_APPLICATION_CHANCE)
|
||||
if (Random.NextDouble() < geneAlteringExtension.minorApplicationChance)
|
||||
MinorChange(pawn);
|
||||
} break;
|
||||
default:
|
||||
|
@ -57,19 +63,11 @@ namespace RJW_Genes
|
|||
ModLog.Debug($"Tried to feminize {pawn} - severity of feminization was too low ({hediff.def} @ {hediff.Severity} - {hediff.Label})") ;
|
||||
} break;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
private static void MinorChange(Pawn pawn)
|
||||
{
|
||||
List<GeneDef> possibleGenes = new List<GeneDef>() {
|
||||
GeneDefOf.rjw_genes_small_male_genitalia,
|
||||
GeneDefOf.rjw_genes_big_breasts,
|
||||
GeneDefOf.rjw_genes_no_cum,
|
||||
DefDatabase<GeneDef>.GetNamed("Beard_NoBeardOnly"),
|
||||
DefDatabase<GeneDef>.GetNamed("Hair_LongOnly")
|
||||
};
|
||||
|
||||
List<GeneDef> possibleGenes = geneAlteringExtension.minorGenes.ToList();
|
||||
GeneDef chosen = possibleGenes.RandomElement();
|
||||
if (chosen == null)
|
||||
{
|
||||
|
@ -90,12 +88,7 @@ namespace RJW_Genes
|
|||
|
||||
private static void MajorChange(Pawn pawn)
|
||||
{
|
||||
List<GeneDef> possibleGenes = new List<GeneDef>() {
|
||||
GeneDefOf.rjw_genes_female_only,
|
||||
GeneDefOf.rjw_genes_no_penis,
|
||||
GeneDefOf.rjw_genes_minor_vulnerability,
|
||||
};
|
||||
|
||||
List<GeneDef> possibleGenes = geneAlteringExtension.majorGenes.ToList();
|
||||
GeneDef chosen = possibleGenes.RandomElement();
|
||||
if (chosen == null)
|
||||
{
|
||||
|
|
|
@ -16,8 +16,8 @@ namespace RJW_Genes
|
|||
[HarmonyPatch(typeof(SexUtility), "Aftersex")]
|
||||
public static class Patch_Twinkifier
|
||||
{
|
||||
const float MINOR_APPLICATION_CHANCE = 0.25f; // = 25% to have a minor transformation
|
||||
const float MAJOR_APPLICATION_CHANCE = 0.10f; // = 10% to have a major transformation
|
||||
|
||||
static GeneAlteringExtension geneAlteringExtension = GeneDefOf.rjw_genes_twinkifier.GetModExtension<GeneAlteringExtension>();
|
||||
|
||||
public static void Postfix(SexProps props)
|
||||
{
|
||||
|
@ -26,6 +26,12 @@ namespace RJW_Genes
|
|||
if (props.pawn.IsAnimal() || props.partner.IsAnimal())
|
||||
return;
|
||||
|
||||
if (geneAlteringExtension == null)
|
||||
{
|
||||
ModLog.Warning("Did not find a (well-formed) GeneAlteringExtension for Twinkifier");
|
||||
return;
|
||||
}
|
||||
|
||||
ApplyTwinkification(props.pawn);
|
||||
ApplyTwinkification(props.partner);
|
||||
}
|
||||
|
@ -44,12 +50,12 @@ namespace RJW_Genes
|
|||
{
|
||||
case float f when f > 0.8f:
|
||||
{
|
||||
if (Random.NextDouble() < MAJOR_APPLICATION_CHANCE)
|
||||
if (Random.NextDouble() < geneAlteringExtension.majorApplicationChance)
|
||||
MajorChange(pawn);
|
||||
} break;
|
||||
case float f when f > 0.6f:
|
||||
{
|
||||
if (Random.NextDouble() < MINOR_APPLICATION_CHANCE)
|
||||
if (Random.NextDouble() < geneAlteringExtension.minorApplicationChance)
|
||||
MinorChange(pawn);
|
||||
} break;
|
||||
default:
|
||||
|
@ -62,12 +68,7 @@ namespace RJW_Genes
|
|||
|
||||
private static void MinorChange(Pawn pawn)
|
||||
{
|
||||
List<GeneDef> possibleGenes = new List<GeneDef>() {
|
||||
GeneDefOf.rjw_genes_small_male_genitalia,
|
||||
DefDatabase<GeneDef>.GetNamed("Beard_NoBeardOnly"),
|
||||
DefDatabase<GeneDef>.GetNamed("Body_Thin"),
|
||||
GeneDefOf.rjw_genes_homosexual
|
||||
};
|
||||
List<GeneDef> possibleGenes = geneAlteringExtension.minorGenes.ToList();
|
||||
|
||||
GeneDef chosen = possibleGenes.RandomElement();
|
||||
if (chosen == null)
|
||||
|
@ -89,13 +90,7 @@ namespace RJW_Genes
|
|||
|
||||
private static void MajorChange(Pawn pawn)
|
||||
{
|
||||
List<GeneDef> possibleGenes = new List<GeneDef>() {
|
||||
GeneDefOf.rjw_genes_fertile_anus,
|
||||
DefDatabase<GeneDef>.GetNamed("Beauty_Pretty"),
|
||||
DefDatabase<GeneDef>.GetNamed("Delicate"),
|
||||
GeneDefOf.rjw_genes_minor_vulnerability,
|
||||
GeneDefOf.rjw_genes_infectious_homosexuality
|
||||
};
|
||||
List<GeneDef> possibleGenes = geneAlteringExtension.majorGenes.ToList();
|
||||
|
||||
GeneDef chosen = possibleGenes.RandomElement();
|
||||
if (chosen == null)
|
||||
|
|
|
@ -29,5 +29,7 @@ namespace RJW_Genes
|
|||
|
||||
public static readonly HediffDef OvaryAgitator;
|
||||
public static readonly HediffDef Bioscaffold;
|
||||
|
||||
[MayRequire("rjw.sexperience")] public static readonly HediffDef rjw_genes_filled_living_cumbucket;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -82,7 +82,11 @@
|
|||
<Compile Include="Genes\Breeding\Genes\Gene_FerventOvipositor.cs" />
|
||||
<Compile Include="Genes\Breeding\Genes\Gene_InsectIncubator.cs" />
|
||||
<Compile Include="Genes\Breeding\Patches\Patch_BlockedMasturbation.cs" />
|
||||
<Compile Include="Genes\Cum\Patch_LikesCumflation.cs" />
|
||||
<Compile Include="Genes\Cum\HediffComp_ProcessCumbucket.cs" />
|
||||
<Compile Include="Genes\Cum\HediffsCompProperties_ProcessCumbucketMTB.cs" />
|
||||
<Compile Include="Genes\Cum\JobDriver_ProcessingCumbucket.cs" />
|
||||
<Compile Include="Genes\Cum\Patches\Patch_LikesCumflation.cs" />
|
||||
<Compile Include="Genes\Cum\Patches\Patch_LivingCumbucket_StackHediff.cs" />
|
||||
<Compile Include="Genes\Damage\Gene_Elasticity.cs" />
|
||||
<Compile Include="Genes\Diseases\Defs\GeneticDiseaseExtension.cs" />
|
||||
<Compile Include="Genes\Diseases\Defs\GeneticInfectorExtension.cs" />
|
||||
|
@ -109,10 +113,10 @@
|
|||
<Compile Include="Genes\Gender\Genes\Gene_GenderFluid.cs" />
|
||||
<Compile Include="Genes\GenitaliaSize\Gene_EvergrowingGenitalia.cs" />
|
||||
<Compile Include="Genes\Cum\CumUtility.cs" />
|
||||
<Compile Include="Genes\Cum\Gene_ChangeCumAmount.cs" />
|
||||
<Compile Include="Genes\Cum\Patch_TransferNutrition.cs" />
|
||||
<Compile Include="Genes\Cum\Genes\Gene_ChangeCumAmount.cs" />
|
||||
<Compile Include="Genes\Cum\Patches\Patch_TransferNutrition.cs" />
|
||||
<Compile Include="Genes\Damage\Gene_Unbreakable.cs" />
|
||||
<Compile Include="Genes\Cum\Patch_CumflationImmunity.cs" />
|
||||
<Compile Include="Genes\Cum\Patches\Patch_CumflationImmunity.cs" />
|
||||
<Compile Include="Genes\ExtraGenitalia\Gene_ExtraBreasts.cs" />
|
||||
<Compile Include="Genes\ExtraGenitalia\Gene_ExtraAnus.cs" />
|
||||
<Compile Include="Genes\ExtraGenitalia\Gene_Futa.cs" />
|
||||
|
@ -190,6 +194,7 @@
|
|||
<Compile Include="Genes\Special\Abilities\CompAbilityEffect_CocoonWeaver.cs" />
|
||||
<Compile Include="Genes\Special\Abilities\CompProperties_AbilityCocoonWeaver.cs" />
|
||||
<Compile Include="Genes\Special\Defs\AgeTransferExtension.cs" />
|
||||
<Compile Include="Genes\Special\Defs\GeneAlteringExtension.cs" />
|
||||
<Compile Include="Genes\Special\Defs\HormonalSalivaExtension.cs" />
|
||||
<Compile Include="Genes\Special\Patches\Patch_AgeDrain.cs" />
|
||||
<Compile Include="Genes\Special\Patches\Patch_GeneticSexSwap.cs" />
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue