+
+ # A slight math note:
+ # The formula is originally: (3 max - 2 curr) rate bonus / (3 max)
+ # I have reduced this to: (1 - 2/3 * pct) rate bonus
+ # My rationale is that this cannot possibly be integer math, so rounding is
+ # not a problem and commutation won't make a difference. It also
+ # simplifies the input considerably.
+ base_chance = (1 - 2/3 * percent_hp) * capture_rate \
+ * ball_bonus * status_bonus