Adds battle history, fixes code style
This commit is contained in:
@@ -23,7 +23,7 @@ public class Gen7BattleStatCalculator : IBattleStatCalculator
|
||||
return stat switch
|
||||
{
|
||||
Statistic.Hp => CalculateHealthStat(pokemon),
|
||||
_ => CalculateNormalStat(pokemon, stat)
|
||||
_ => CalculateNormalStat(pokemon, stat),
|
||||
};
|
||||
}
|
||||
|
||||
@@ -90,7 +90,7 @@ public class Gen7BattleStatCalculator : IBattleStatCalculator
|
||||
4 => 6.0f / 2.0f,
|
||||
5 => 7.0f / 2.0f,
|
||||
6 => 8.0f / 2.0f,
|
||||
_ => throw new System.ArgumentException("Stat boost was out of expected range of -6 to 6")
|
||||
_ => throw new System.ArgumentException("Stat boost was out of expected range of -6 to 6"),
|
||||
};
|
||||
}
|
||||
}
|
||||
@@ -62,7 +62,7 @@ public class Gen7DamageCalculator(bool hasRandomness) : IDamageCalculator
|
||||
{
|
||||
> uint.MaxValue => uint.MaxValue,
|
||||
< 1 => 1,
|
||||
_ => (uint)floatDamage
|
||||
_ => (uint)floatDamage,
|
||||
};
|
||||
executingMove.RunScriptHook(script =>
|
||||
script.ChangeDamage(executingMove, target, hitNumber, ref damage));
|
||||
@@ -98,7 +98,7 @@ public class Gen7DamageCalculator(bool hasRandomness) : IDamageCalculator
|
||||
0 => random.GetInt(24) == 0,
|
||||
1 => random.GetInt(8) == 0,
|
||||
2 => random.GetInt(2) == 0,
|
||||
_ => true
|
||||
_ => true,
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -32,7 +32,7 @@ public class Gen7MiscLibrary : IMiscLibrary
|
||||
>= 6 and <= 9 => TimeOfDay.Morning,
|
||||
>= 10 and <= 16 => TimeOfDay.Day,
|
||||
17 => TimeOfDay.Evening,
|
||||
_ => TimeOfDay.Night
|
||||
_ => TimeOfDay.Night,
|
||||
};
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user