mirror of
https://gitgud.io/lutepickle/rjw_menstruation.git
synced 2024-08-14 22:46:52 +00:00
Be sure the periodic can go into anestrus if it initializes into ovulatory
This commit is contained in:
parent
82dea0f425
commit
50310988ca
1 changed files with 2 additions and 2 deletions
|
@ -29,14 +29,14 @@ namespace RJW_Menstruation
|
|||
|
||||
protected override void InitializeExtraValues()
|
||||
{
|
||||
base.InitializeExtraValues();
|
||||
base.InitializeExtraValues();
|
||||
if (averageCycleIntervalTicks < 0)
|
||||
{
|
||||
averageCycleIntervalTicks = (int)(Props.cycleIntervalDays.RandomInRange * GenDate.TicksPerDay / cycleSpeed);
|
||||
if (ticksToNextCycle < -50000)
|
||||
ticksToNextCycle = Rand.Range(0, averageCycleIntervalTicks);
|
||||
// Make the cutoff halfway into cycle, just to be sure there isn't a double-cycle the first time
|
||||
if ((curStage == Stage.Follicular || curStage == Stage.Luteal || curStage == Stage.Bleeding)
|
||||
if ((curStage == Stage.Follicular || curStage == Stage.Ovulatory || curStage == Stage.Luteal || curStage == Stage.Bleeding)
|
||||
&& (averageCycleIntervalTicks - ticksToNextCycle) / 2 >= GenDate.TicksPerDay * (Props.follicularIntervalDays + Props.lutealIntervalDays) / cycleSpeed)
|
||||
GoNextStage(Stage.Anestrus);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue