mirror of
				https://github.com/amevarashi/RJW-Sexperience.git
				synced 2024-08-14 23:54:08 +00:00 
			
		
		
		
	Change VariousDefOf to RsDefOf
Fix some IDE messages
This commit is contained in:
		
							parent
							
								
									8a48d2e463
								
							
						
					
					
						commit
						67c2328ad6
					
				
					 23 changed files with 196 additions and 162 deletions
				
			
		| 
						 | 
				
			
			@ -42,8 +42,8 @@ namespace RJWSexperience // Used in Menstruation with this namespace
 | 
			
		|||
			if (SexperienceMod.Settings.DevMode)
 | 
			
		||||
			{
 | 
			
		||||
				stringBuilder.AppendLine();
 | 
			
		||||
				stringBuilder.AppendLine($"[Debug] stored: {StoredStackCount}");
 | 
			
		||||
				stringBuilder.Append($"[Debug] storedDecimalRemainder: {storedDecimalRemainder}");
 | 
			
		||||
				stringBuilder.Append("[Debug] stored: ").Append(StoredStackCount).AppendLine();
 | 
			
		||||
				stringBuilder.Append("[Debug] storedDecimalRemainder: ").Append(storedDecimalRemainder);
 | 
			
		||||
			}
 | 
			
		||||
 | 
			
		||||
			return stringBuilder.ToString();
 | 
			
		||||
| 
						 | 
				
			
			@ -51,7 +51,7 @@ namespace RJWSexperience // Used in Menstruation with this namespace
 | 
			
		|||
 | 
			
		||||
		public void AddCum(float amount)
 | 
			
		||||
		{
 | 
			
		||||
			AddCum(amount, VariousDefOf.GatheredCum);
 | 
			
		||||
			AddCum(amount, RsDefOf.Thing.GatheredCum);
 | 
			
		||||
		}
 | 
			
		||||
 | 
			
		||||
		public void AddCum(float amount, ThingDef cumDef)
 | 
			
		||||
| 
						 | 
				
			
			@ -69,7 +69,7 @@ namespace RJWSexperience // Used in Menstruation with this namespace
 | 
			
		|||
			cum.stackCount = num;
 | 
			
		||||
			if (cum.stackCount > 0 && !GenPlace.TryPlaceThing(cum, PositionHeld, Map, ThingPlaceMode.Direct, out Thing res))
 | 
			
		||||
			{
 | 
			
		||||
				FilthMaker.TryMakeFilth(PositionHeld, Map, VariousDefOf.FilthCum, num);
 | 
			
		||||
				FilthMaker.TryMakeFilth(PositionHeld, Map, RsDefOf.Thing.FilthCum, num);
 | 
			
		||||
			}
 | 
			
		||||
			storedDecimalRemainder -= num;
 | 
			
		||||
		}
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -125,7 +125,7 @@ namespace RJWSexperience.Cum
 | 
			
		|||
			const float allOf = 1000f;
 | 
			
		||||
 | 
			
		||||
			log.Message($"FeedCum({pawn.NameShortColored}, {amount})");
 | 
			
		||||
			Thing cum = ThingMaker.MakeThing(VariousDefOf.GatheredCum);
 | 
			
		||||
			Thing cum = ThingMaker.MakeThing(RsDefOf.Thing.GatheredCum);
 | 
			
		||||
			cum.stackCount = (int)Math.Ceiling(amount);
 | 
			
		||||
			log.Message($"Created a stack of {cum.stackCount} cum");
 | 
			
		||||
			cum.Ingested(pawn, allOf);
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -6,7 +6,7 @@ namespace RJWSexperience.Cum.FilterWorkers
 | 
			
		|||
	{
 | 
			
		||||
		public override bool Matches(Thing t)
 | 
			
		||||
		{
 | 
			
		||||
			return IsCum(t) || IsFoodWithCum(t);
 | 
			
		||||
			return IsCum(t.def) || IsFoodWithCum(t);
 | 
			
		||||
		}
 | 
			
		||||
	}
 | 
			
		||||
}
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -10,20 +10,18 @@ namespace RJWSexperience.Cum.FilterWorkers
 | 
			
		|||
			return def.IsIngestible && def.IsProcessedFood;
 | 
			
		||||
		}
 | 
			
		||||
 | 
			
		||||
		protected bool IsCum(Thing t) => IsCum(t.def);
 | 
			
		||||
 | 
			
		||||
		protected bool IsCum(ThingDef t) => t == VariousDefOf.GatheredCum;
 | 
			
		||||
		protected bool IsCum(ThingDef t) => t == RsDefOf.Thing.GatheredCum;
 | 
			
		||||
 | 
			
		||||
		protected bool IsFoodWithCum(Thing food)
 | 
			
		||||
		{
 | 
			
		||||
			CompIngredients compIngredients = food.TryGetComp<CompIngredients>();
 | 
			
		||||
 | 
			
		||||
			if (compIngredients == null)
 | 
			
		||||
			if (compIngredients?.ingredients == null)
 | 
			
		||||
				return false;
 | 
			
		||||
 | 
			
		||||
			foreach (ThingDef ingredient in compIngredients.ingredients)
 | 
			
		||||
			for (int i = 0; i < compIngredients.ingredients.Count; i++)
 | 
			
		||||
			{
 | 
			
		||||
				if (IsCum(ingredient))
 | 
			
		||||
				if (IsCum(compIngredients.ingredients[i]))
 | 
			
		||||
					return true;
 | 
			
		||||
			}
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -6,7 +6,7 @@ namespace RJWSexperience.Cum.FilterWorkers
 | 
			
		|||
	{
 | 
			
		||||
		public override bool Matches(Thing t)
 | 
			
		||||
		{
 | 
			
		||||
			return !IsCum(t) && !IsFoodWithCum(t);
 | 
			
		||||
			return !IsCum(t.def) && !IsFoodWithCum(t);
 | 
			
		||||
		}
 | 
			
		||||
	}
 | 
			
		||||
}
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -12,8 +12,8 @@ namespace RJWSexperience.Cum
 | 
			
		|||
		{
 | 
			
		||||
			int amount = ingested.stackCount * (int)unitAmount;
 | 
			
		||||
			Logs.LogManager.GetLogger<IngestionOutcomeDoer_RecordEatenCum, Logs.DebugLogProvider>().Message($"Record {pawn.NameShortColored} eating {amount} ml of cum");
 | 
			
		||||
			pawn.records.Increment(VariousDefOf.NumofEatenCum);
 | 
			
		||||
			pawn.records.AddTo(VariousDefOf.AmountofEatenCum, amount);
 | 
			
		||||
			pawn.records.Increment(RsDefOf.Record.NumofEatenCum);
 | 
			
		||||
			pawn.records.AddTo(RsDefOf.Record.AmountofEatenCum, amount);
 | 
			
		||||
		}
 | 
			
		||||
	}
 | 
			
		||||
}
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -17,7 +17,7 @@ namespace RJWSexperience.Cum.Interactions
 | 
			
		|||
			if (context.Internals.Submissive.Parts.Penises.Any())
 | 
			
		||||
				return GetForCumAddict(context.Internals.Dominant.Pawn);
 | 
			
		||||
 | 
			
		||||
			if (AddictionUtility.IsAddicted(context.Internals.Submissive.Pawn, VariousDefOf.Cum))
 | 
			
		||||
			if (AddictionUtility.IsAddicted(context.Internals.Submissive.Pawn, RsDefOf.Chemical.Cum))
 | 
			
		||||
				return GetForPartner();
 | 
			
		||||
 | 
			
		||||
			return Enumerable.Empty<Weighted<LewdablePartKind>>();
 | 
			
		||||
| 
						 | 
				
			
			@ -28,7 +28,7 @@ namespace RJWSexperience.Cum.Interactions
 | 
			
		|||
			if (context.Internals.Dominant.Parts.Penises.Any())
 | 
			
		||||
				return GetForCumAddict(context.Internals.Submissive.Pawn);
 | 
			
		||||
 | 
			
		||||
			if (AddictionUtility.IsAddicted(context.Internals.Dominant.Pawn, VariousDefOf.Cum))
 | 
			
		||||
			if (AddictionUtility.IsAddicted(context.Internals.Dominant.Pawn, RsDefOf.Chemical.Cum))
 | 
			
		||||
				return GetForPartner();
 | 
			
		||||
 | 
			
		||||
			return Enumerable.Empty<Weighted<LewdablePartKind>>();
 | 
			
		||||
| 
						 | 
				
			
			@ -42,7 +42,7 @@ namespace RJWSexperience.Cum.Interactions
 | 
			
		|||
			var log = LogManager.GetLogger<CumAddictPartKindUsageRule, DebugLogProvider>();
 | 
			
		||||
			log.Message($"Called for {pawn.NameShortColored}");
 | 
			
		||||
 | 
			
		||||
			if (!(pawn.needs?.TryGetNeed(VariousDefOf.Chemical_Cum) is Need_Chemical cumNeed))
 | 
			
		||||
			if (!(pawn.needs?.TryGetNeed(RsDefOf.Need.Chemical_Cum) is Need_Chemical cumNeed))
 | 
			
		||||
				yield break;
 | 
			
		||||
 | 
			
		||||
			log.Message($"{pawn.NameShortColored} is cum addict, current desire level: {cumNeed.CurCategory}");
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -4,7 +4,7 @@
 | 
			
		|||
	{
 | 
			
		||||
		protected override void UpdateCurStage()
 | 
			
		||||
		{
 | 
			
		||||
			if (pawn?.health?.hediffSet?.HasHediff(VariousDefOf.CumAddiction) ?? false)
 | 
			
		||||
			if (pawn?.health?.hediffSet?.HasHediff(RsDefOf.Hediff.CumAddiction) ?? false)
 | 
			
		||||
			{
 | 
			
		||||
				SetForcedStage(def.stages.Count - 1);
 | 
			
		||||
			}
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue