Critical hit: Difference between revisions

→‎In Generation I: Rewriting the Probability section to use LaTeX and a table | Noting that in the Gen 1 handheld games, FE causes Speed to be rounded down even further.
(→‎In Generation I: Rewriting the Probability section to use LaTeX and a table | Noting that in the Gen 1 handheld games, FE causes Speed to be rounded down even further.)
Line 4: Line 4:
A '''critical hit''' (Japanese: '''{{tt|急所|きゅうしょ}}''' ''{{wp|pressure point}}'') is a (generally) random event that multiplies the [[damage]] of a damage-dealing [[move]]. When one occurs, the game will display the message "A critical hit!" (Japanese: {{tt|急所に 当たった!|きゅうしょに あたった!}} ''Hit a pressure point!'') after the damage is dealt.
A '''critical hit''' (Japanese: '''{{tt|急所|きゅうしょ}}''' ''{{wp|pressure point}}'') is a (generally) random event that multiplies the [[damage]] of a damage-dealing [[move]]. When one occurs, the game will display the message "A critical hit!" (Japanese: {{tt|急所に 当たった!|きゅうしょに あたった!}} ''Hit a pressure point!'') after the damage is dealt.


==In Generation I==
==Generation I==
===Damage===
===Damage===
When a move lands a critical hit, the attacker's level will be doubled during [[damage]] calculation, which approximately (but not quite) doubles the damage dealt. A rough formula for the damage multiplier is <code>(2L+5)/(L+5)</code> where L is the attacker's level; as a result, lower-leveled Pokémon have a smaller critical hit boost than higher-leveled Pokémon. For example, a level 5 Pokémon will inflict about 1.5× damage on a critical hit, while a level 20 Pokémon will inflict 1.8× and a level 95 Pokémon will inflict 1.95×.
When a move lands a critical hit, the attacker's level will be doubled during [[damage]] calculation, which approximately (but not quite) doubles the damage dealt. A rough approximation for the damage multiplier is <math display="inline">{2L + 5} \over {L + 5}</math> where L is the attacker's level; as a result, lower-leveled Pokémon have a smaller critical hit boost than higher-leveled Pokémon. For example, a level 5 Pokémon will inflict about 1.5× damage on a critical hit, while a level 20 Pokémon will inflict 1.8× and a level 95 Pokémon will inflict 1.95×.


Critical hits ignore all [[Statistic|stat]] stage modifiers and the halved {{stat|Attack}} from {{status|burn}}. This includes beneficial stat modifiers as well, making it possible for a critical hit to deal less damage than a non-critical hit if the attacker has at least doubled their Attack/{{stat|Special}} or the target's {{stat|Defense}}/Special is at least halved.
Critical hits ignore all [[Statistic|stat]] stage modifiers and the halved {{stat|Attack}} from {{status|burn}}. This includes beneficial stat modifiers as well, making it possible for a critical hit to deal less damage than a non-critical hit if the attacker has at least doubled their Attack/{{stat|Special}} or the target's {{stat|Defense}}/Special is at least halved.


===Probability===
===Probability===
Whether a move scores a critical hit is determined by comparing a 1-byte random number (0 to 255) against a 1-byte threshold value (also 0 to 255); if the random number is less than the threshold, the Pokémon scores a critical hit. If the threshold value is ''T'', then this means the probability (''P'') of scoring a critical hit is <code>''P'' = ''T'' / 256</code>. (It is impossible for a critical hit to be guaranteed; there will always be at least a 1/256 chance that a critical hit will not be scored.)
====Handheld games====
Whether a move scores a critical hit is determined by comparing a 1-byte random number (0 to 255) against a 1-byte threshold value (also 0 to 255). If the random number is strictly less than the threshold, the Pokémon scores a critical hit. For a given threshold value <math>T</math>, the probability of scoring a critical hit is <math display="inline">\frac{T}{256}</math>.


The value of ''T'' is based on a Pokémon's [[base stats|base]] {{stat|Speed}}. For a normal move, ''T'' is half the base Speed:
If the threshold would exceed 255, it instead becomes 255. Consequently, the maximum possible chance of landing a critical hit is 255/256. (If the generated random number is 255, that number can never be less than the threshold, regardless of the value of the threshold.)
:<code>''T'' = ''BaseSpeed'' / 2</code> or <code>''P'' = ''BaseSpeed'' / 512</code>
 
Due to a bug in Generation I, {{m|Focus Energy}} and [[Dire Hit]] lower a Pokémon's chance of scoring a critical hit instead of raising it, dividing ''T'' by 4:
The threshold is normally equal to half the user's [[base stats|base]] {{stat|Speed}}. If the move used has a high critical-hit ratio ({{m|Crabhammer}}, {{m|Karate Chop}}, {{m|Razor Leaf}}, or {{m|Slash}}), the move is 8 times more likely to be a critical hit (up to a maximum of 255/256). If the Pokémon has used {{m|Focus Energy}} or a [[Dire Hit]], due to a bug, the user is 1/4 as likely to land a critical hit.
:<code>''T''<sub>''FE''</sub> = ''BaseSpeed'' / 8</code> or <code>''P''<sub>''FE''</sub> = ''BaseSpeed'' / 2048</code>
 
If the move being used has a high critical-hit ratio ({{m|Crabhammer}}, {{m|Karate Chop}}, {{m|Razor Leaf}}, or {{m|Slash}}), ''T'' is multiplied by 8:
The threshold has the following values, depending on the move used and whether the user is under the effect of Focus Energy or a Dire Hit. The probability of landing a critical hit is simply these values divided by 256.
:<code>''T''<sub>''HighCHR''</sub> = ''BaseSpeed'' * 4</code> or <code>''P''<sub>''HighCHR''</sub> = ''BaseSpeed'' / 64</code>
 
Both effects may also be active at the same time. This would result in:
{| class="wikitable" style="text-align:center"
:<code>''T''<sub>''FE+HighCHR''</sub> = ''BaseSpeed''</code> or <code>''P''<sub>''FE+HighCHR''</sub> = ''BaseSpeed'' / 256</code>
|+ Threshold
At all times, the maximum value for ''T'' is 255 (which equally means the maximum value for ''P'' is 255/256). All operations that factor into ''T'' are also integer operations (meaning divisions are rounded down to the nearest whole number). (Note that the division in <code>''P'' = ''T'' / 256</code> is not rounded.) Due to the process the game uses to compute ''T'', ''BaseSpeed'' is also effectively rounded down to the nearest even number.
!
! Normal move
! High critical-hit ratio move
|-
! Normal status
| <math>\left\lfloor \frac{BaseSpeed}{2} \right\rfloor</math>
| <math>\mathrm{min}(4 \times BaseSpeed, 255)</math>
|-
! Focus Energy
| <math>\left\lfloor {BaseSpeed \over 8} \right\rfloor</math>
| <math>BaseSpeed</math>
|}
 
Due to the process the game uses to compute ''T'', ''BaseSpeed'' is effectively rounded down to the nearest even number. If the Pokémon is under the effect of Focus Energy or a Dire Hit, ''BaseSpeed'' is effectively rounded down to the nearest multiple of 4.


====In Pokémon Stadium====
====Pokémon Stadium====
In {{g|Stadium}}, the threshold value ''T'' is determined by a different formula.
In {{g|Stadium}}, the threshold value ''T'' is determined by a different formula.


For a normal move, ''T'' is:
For a normal move, ''T'' is:
:<code>''T'' = ( ''BaseSpeed'' + 76 ) / 4</code> or <code>''P'' = ( ''BaseSpeed'' + 76 ) / 1024</code>
:<math>T = ( BaseSpeed + 76 ) / 4</math> or <math>P = ( BaseSpeed + 76 ) / 1024</math>
{{m|Focus Energy}}  is slightly more complicated than in the core games, but it does correctly raise the chance of a critical hit instead of lowering it:
{{m|Focus Energy}}  is slightly more complicated than in the core games, but it does correctly raise the chance of a critical hit instead of lowering it:
:<code>''T''<sub>''FE''</sub> = ( ''BaseSpeed'' + 236 ) / 2</code> or <code>''P''<sub>''FE''</sub> = ( ''BaseSpeed'' + 236 ) / 512</code>
:<math>T_{FE} = ( BaseSpeed + 236 ) / 2</math> or <math>P_{FE} = ( BaseSpeed + 236 ) / 512</math>
If the move being used has a high critical-hit ratio ({{m|Crabhammer}}, {{m|Karate Chop}}, {{m|Razor Leaf}}, or {{m|Slash}}), ''T'' is multiplied by 8:
If the move being used has a high critical-hit ratio ({{m|Crabhammer}}, {{m|Karate Chop}}, {{m|Razor Leaf}}, or {{m|Slash}}), ''T'' is multiplied by 8:
:<code>''T''<sub>''HighCHR''</sub> = ( ''BaseSpeed'' + 76 ) * 2</code> or <code>''P''<sub>''HighCHR''</sub> = ( ''BaseSpeed'' + 76 ) / 128</code>
:<math>T_{HighCHR} = ( BaseSpeed + 76 ) * 2</math> or <math>P_{HighCHR} = ( BaseSpeed + 76 ) / 128</math>
If both effects are active at the same time, then:
If both effects are active at the same time, then:
:<code>''T''<sub>''FE+HighCHR''</sub> = ( ''BaseSpeed'' + 236 ) * 4</code> or <code>''P''<sub>''FE+HighCHR''</sub> = ( ''BaseSpeed'' + 236 ) / 64</code>
:<math>T_{FE+HighCHR} = ( BaseSpeed + 236 ) * 4</math> or <math>P_{FE+HighCHR} = ( BaseSpeed + 236 ) / 64</math>
Since 236 * 4 is well beyond 255, any Pokémon will have a maximum chance to score a critical hit if both effects are active.
Since 236 * 4 is well beyond 255, any Pokémon will have a maximum chance to score a critical hit if both effects are active.