balance changes: no need to redesignate induce lactation, relactate percent now starts at 90%, nonadults no longer get debuffs

This commit is contained in:
c0ffee 2021-11-23 16:50:33 -08:00
parent e82456570e
commit 5d3e7d94a3
4 changed files with 16 additions and 13 deletions

View file

@ -31,13 +31,7 @@ namespace CRIALactation
{
return;
}
if (LactationUtility.IsLactating(p))
{
InductionCompletionPercent = 0.8f;
isActive = false;
return;
}
if (!isActive)
if (LactationUtility.IsLactating(p) || !isActive)
{
return;
}
@ -54,8 +48,7 @@ namespace CRIALactation
Find.LetterStack.ReceiveLetter(letter);
LactationUtility.StartLactating(p, true);
isActive = false;
InductionCompletionPercent = 0.80f; //start at 80% in case they ever lose lactating again
InductionCompletionPercent = 0.90f + Random.Range(0f, 5f); //start at 90-95% in case they ever lose lactating again
}
}
@ -83,7 +76,7 @@ namespace CRIALactation
if(isActive)
{
//stop trying to induce lactation
yield return new FloatMenuOption("Undesignate induce lactation", () =>
yield return new FloatMenuOption("Stop inducing lactation", () =>
{
isActive = false;
});
@ -91,7 +84,7 @@ namespace CRIALactation
else
{
//induce lactation
yield return new FloatMenuOption("Designate induce lactation", () =>
yield return new FloatMenuOption("Start inducing lactation", () =>
{
isActive = true;
});
@ -99,7 +92,7 @@ namespace CRIALactation
}
else
{
yield return new FloatMenuOption("Designate induce lactation (no milkable breasts)", null);
yield return new FloatMenuOption("Start inducing lactation (no milkable breasts)", null);
}
yield break;

View file

@ -36,7 +36,12 @@ namespace CRIALactation
return ThoughtState.ActiveAtStage(1);
}
if(ExpectationsUtility.CurrentExpectationFor(p).order <= ExpectationDefOf.VeryLow.order)
if (!p.ageTracker.Adult)
{
return false;
}
if (ExpectationsUtility.CurrentExpectationFor(p).order <= ExpectationDefOf.VeryLow.order)
{
return ThoughtState.ActiveAtStage(2);
}

View file

@ -27,6 +27,11 @@ namespace CRIALactation
}
if(!otherPawn.ageTracker.Adult)
{
return false;
}
if (ExpectationsUtility.CurrentExpectationFor(p).order <= ExpectationDefOf.VeryLow.order)
{
return ThoughtState.ActiveAtStage(2);