SHARE
TWEET

RBY Damage

a guest Mar 23rd, 2015 844 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. - The current damage in battle is stored in two 8-bit addresses (will be referred to as a 16-bit address from now on) so it can store values up to 65535. Anything that would make the damage overflow, caps it at 65535 instead. This damage address is shared by both players.
  2.         - The damage address isn't cleared (set to 0) when a battle starts or finishes, nor on a switch. Thus, it will be carried over between battles.
  3.  
  4. - If the attacker hurts itself due to confusion, the damage stored in the damage address will correspond to the calculated damage that the confused Pokemon deals to itself.
  5.  
  6. - If the turn holder is storing energy due to Bide, the content of the damage address is added to the value already stored in a separate Bide damage address (two 8-bit addresses).
  7.         - Bide's store energy effect won't occur during a turn the Pokemon is asleep, frozen, trapped (from Wrap or a similar move), flinched, or recharging from Hyper Beam.
  8.         - If energy is unleashed this turn, the content of the Bide damage address is copied to the damage address and cleared, then the damage address is doubled.
  9.  
  10. - Whenever a move whose effect is NOT on the list below is used, the damage address is cleared.
  11.         + CONVERSION_EFFECT
  12.         + HAZE_EFFECT
  13.         + SWITCH_AND_TELEPORT_EFFECT
  14.         + MIST_EFFECT
  15.         + FOCUS_ENERGY_EFFECT
  16.         + CONFUSION_EFFECT
  17.         + HEAL_EFFECT
  18.         + TRANSFORM_EFFECT
  19.         + LIGHT_SCREEN_EFFECT
  20.         + REFLECT_EFFECT
  21.         + POISON_EFFECT
  22.         + PARALYZE_EFFECT
  23.         + SUBSTITUTE_EFFECT
  24.         + MIMIC_EFFECT
  25.         + LEECH_SEED_EFFECT
  26.         + SPLASH_EFFECT
  27.         - Using a move means actually using it, and not just that its effect gets executed.
  28.                 - Selecting a move and failing to use it due to being asleep, frozen, etc. is not using a move.
  29.                 - Recharging from Hyper Beam is not using Hyper Beam.
  30.                 - Bide storing energy (after the turn it's selected) is not using Bide.
  31.                 - Wrap, Bind, Clamp and Fire Spin are only used in the first turn of the sequence (not entirely true, but to this effect, yes).
  32.                 - Multi-hit moves such as Double Kick and Fury Attack are only used once despite hitting twice or more.
  33.  
  34. - If the requirements for Counter dealing damage to the target meet, the content of the damage address is doubled. The three requirements are (excluding desync and other similar glitches):
  35.         - The other player's last selected move's Base Power must be non-zero.
  36.         - The other player's last selected move must be either Normal- or Fighting-type, but can not be Counter.
  37.         - The damage address must contain a non-zero value.
  38.        
  39.  
  40. - Whenever a damaging move (including fixed damage moves like Seismic Toss or Super Fang, Counter, OHKO moves like Horn Drill, and Bide's damage dealing effect) deals damage to the target, the damage dealt corresponds to the value stored in the damage address. The damage stored corresponds to the damage calculated during the last damage calculation process.
  41.         - Multi-turn and multi-hit moves such as Wrap, Double Kick and Fury Attack only execute damage calculation for the first hit.
  42.  
  43. - Whenever any move that goes through standard accuracy checks misses, the damage address is cleared.
  44.         - Moves included are:
  45.                 + Damaging moves
  46.                 + Non-damaging moves that inflict sleep, poison, paralysis, or confusion
  47.                 + Disable
  48.                 + Mimic
  49.                 + Non-damaging moves with a stat modifier down effect
  50.                 + Leech Seed
  51.         - Missing isn't the same as having no effect (e.g. Thunder Wave on a already statused move, Leer on a -6 Def Pokemon).
  52.         - Failing because of Mist, because the target is using Fly/Dig, or because the target is not asleep when the move used is Dream Eater, is considered missing.
  53.  
  54. - If Jump Kick or Hi-Jump Kick misses, the attacker takes 1 damage, and 1 is written to the damage address.
  55.         - In reality, it takes damage equal to the maximum of 1, and the value stored in the damage address divided by 8 and rounded down. But because the move missed, the damage address will contain 0 and thus, damage taken will be 1. Damage taken is then written to the damage address.
  56.  
  57. - If a OHKO move like Horn Drill is successful, 65535 is written to the damage address.
  58.  
  59. - If, as a result of a damage dealing move or self-confusion damage, the target is KOed, the damage stored is overwritten with the HP the Pokemon had before being KOed.
  60.         - If the target's Substitute faints, the damage stored is NOT overwritten with the HP the Substitute had.
  61.  
  62. - If Absorb, Mega Drain or Leech Life is successful, the content of the damage address is halved, then 1 is written to it if it contains 0, and finally the attacker gets its HP increased by the value stored in the damage address.
  63.         - HP recovery is capped to the attacker's maximum HP, but the damage address isn't updated with the actual HP healed in this case.
  64.  
  65. - If the attacker takes recoil damage due to the effect of a recoil move such as Take Down, it will take damage equal to the value stored in the damage address, divided by 4 and rounded down.
  66.         - The damage address isn't updated with the recoil damage taken.
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top