mirror of
https://gitgud.io/lutepickle/rjw_menstruation.git
synced 2024-08-14 22:46:52 +00:00
Little refactor to ovulation egging
This commit is contained in:
parent
7f306fb9c7
commit
c081e1e9b9
1 changed files with 5 additions and 8 deletions
|
@ -1390,11 +1390,10 @@ namespace RJW_Menstruation
|
|||
protected virtual void OvulatoryAction()
|
||||
{
|
||||
estrusflag = false;
|
||||
int i = 0;
|
||||
float eggnum;
|
||||
int eggnum;
|
||||
try
|
||||
{
|
||||
eggnum = Rand.ByCurve(Pawn.def.race.litterSizeCurve);
|
||||
eggnum = Math.Min((int)Rand.ByCurve(Pawn.def.race.litterSizeCurve), 1);
|
||||
}
|
||||
catch (NullReferenceException)
|
||||
{
|
||||
|
@ -1407,12 +1406,10 @@ namespace RJW_Menstruation
|
|||
}
|
||||
eggnum += eggstack;
|
||||
|
||||
do
|
||||
{
|
||||
ovarypower--;
|
||||
for (int i = 0; i < eggnum; i++)
|
||||
eggs.Add(new Egg((int)(Props.eggLifespanDays * 24 / CycleFactor)));
|
||||
i++;
|
||||
} while (i < (int)eggnum);
|
||||
ovarypower -= eggnum;
|
||||
|
||||
eggstack = 0;
|
||||
if (EggHealth <= 0)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue