mirror of
https://gitgud.io/lutepickle/rjw_menstruation.git
synced 2024-08-14 22:46:52 +00:00
Split ShouldSimulate into its own function
This commit is contained in:
parent
e88e40c2cc
commit
acfee52dd8
2 changed files with 18 additions and 3 deletions
|
@ -158,6 +158,14 @@ namespace RJW_Menstruation
|
||||||
Scribe_Values.Look(ref baseNipple, "baseNipple", baseNipple, true);
|
Scribe_Values.Look(ref baseNipple, "baseNipple", baseNipple, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public bool ShouldSimulate()
|
||||||
|
{
|
||||||
|
if (!Configurations.EnableAnimalCycle && Pawn.IsAnimal()) return false;
|
||||||
|
if (Pawn.Spawned) return true;
|
||||||
|
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
public override void CompPostTick(ref float severityAdjustment)
|
public override void CompPostTick(ref float severityAdjustment)
|
||||||
{
|
{
|
||||||
base.CompPostTick(ref severityAdjustment);
|
base.CompPostTick(ref severityAdjustment);
|
||||||
|
@ -166,7 +174,7 @@ namespace RJW_Menstruation
|
||||||
{
|
{
|
||||||
if (
|
if (
|
||||||
!Pawn.IsHashIntervalTick(tickInterval) ||
|
!Pawn.IsHashIntervalTick(tickInterval) ||
|
||||||
!Pawn.Spawned // TODO: Add option to simulate off-map pawns
|
!ShouldSimulate()
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
|
|
|
@ -549,6 +549,14 @@ namespace RJW_Menstruation
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public bool ShouldSimulate()
|
||||||
|
{
|
||||||
|
if (!Configurations.EnableAnimalCycle && Pawn.IsAnimal()) return false;
|
||||||
|
if (Pawn.Spawned) return true;
|
||||||
|
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
public override void CompPostTick(ref float severityAdjustment)
|
public override void CompPostTick(ref float severityAdjustment)
|
||||||
{
|
{
|
||||||
base.CompPostTick(ref severityAdjustment);
|
base.CompPostTick(ref severityAdjustment);
|
||||||
|
@ -557,8 +565,7 @@ namespace RJW_Menstruation
|
||||||
{
|
{
|
||||||
if (
|
if (
|
||||||
!Pawn.IsHashIntervalTick(tickInterval) ||
|
!Pawn.IsHashIntervalTick(tickInterval) ||
|
||||||
!Pawn.Spawned || // TODO: Add option to simulate off-map pawns
|
!ShouldSimulate()
|
||||||
(Pawn.IsAnimal() && !Configurations.EnableAnimalCycle)
|
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
|
|
Loading…
Reference in a new issue