List of glitches (Generation VII): Difference between revisions

m
Line 195: Line 195:
If the user has {{a|Serene Grace}} and uses {{m|Charge Beam}} while its side is under the effect of the rainbow from the combination of {{m|Fire Pledge}} and {{m|Water Pledge}}, the additional effect chance for Charge Beam will overflow and become 24%: <math inline="yes">\left ( 70 \times 4 \right ) \bmod 256 = 24</math>.<ref>[https://www.smogon.com/forums/threads/sword-shield-battle-mechanics-research.3655528/post-9076566 Post by Sasa to Sword & Shield Battle Mechanics Research on Smogon Forums]</ref>
If the user has {{a|Serene Grace}} and uses {{m|Charge Beam}} while its side is under the effect of the rainbow from the combination of {{m|Fire Pledge}} and {{m|Water Pledge}}, the additional effect chance for Charge Beam will overflow and become 24%: <math inline="yes">\left ( 70 \times 4 \right ) \bmod 256 = 24</math>.<ref>[https://www.smogon.com/forums/threads/sword-shield-battle-mechanics-research.3655528/post-9076566 Post by Sasa to Sword & Shield Battle Mechanics Research on Smogon Forums]</ref>


This overflow can occur with any move with a base additional effect chance between 64% and 88% that does not inflict [[status condition]]s because for them, a different data type is used to store the additional effect chance (16-bit signed integer), and if it does not cause [[flinch]]ing because flinching odds are unaffected by the rainbow. Charge Beam is the only move that satisfies this criterion.
This overflow can occur with any move with a base additional effect chance between 64% and 88% that does not inflict [[status condition]]s because for them, a different data type is used to store the additional effect chance (16-bit signed integer), and if it does not cause [[flinch]]ing because the rainbow and Serene Grace doubling does not stack specifically for flinching. Charge Beam is the only move that satisfies this criterion.


The overflow still occurs for moves with a chance of an additional effect chance greater than 88%, e.g. {{m|Mud Shot}}, with the additional effect chance becoming <math inline="yes">\left ( 100 \times 4 \right ) \bmod 256 = 144</math>. However, because 144 is greater than 100, there is no noticeable difference.
The overflow still occurs for moves with a chance of an additional effect chance greater than 88%, e.g. {{m|Mud Shot}}, with the additional effect chance becoming <math inline="yes">\left ( 100 \times 4 \right ) \bmod 256 = 144</math>. However, because 144 is greater than 100, there is no noticeable difference.