mirror of
https://gitlab.com/xCrystal/pokecrystal-board.git
synced 2024-11-16 11:27:33 -08:00
Merge branch 'master' of hyperdriveguy/pokecrystal
This commit is contained in:
commit
8aebc7ba56
@ -246,7 +246,35 @@ DefenseDownHit:
|
|||||||
|
|
||||||
([Video](https://www.youtube.com/watch?v=uRYyzKRatFk))
|
([Video](https://www.youtube.com/watch?v=uRYyzKRatFk))
|
||||||
|
|
||||||
*To do:* Identify specific code causing this bug and fix it.
|
This is a bug with `BattleCommand_Counter` in [engine/battle/move_effects/counter.asm](/engine/battle/move_effects/counter.asm) and `BattleCommand_MirrorCoat` in [engine/battle/move_effects/mirror_coat.asm](/engine/battle/move_effects/mirror_coat.asm):
|
||||||
|
|
||||||
|
```asm
|
||||||
|
; BUG: Move should fail with all non-damaging battle actions
|
||||||
|
ld hl, wCurDamage
|
||||||
|
ld a, [hli]
|
||||||
|
or [hl]
|
||||||
|
ret z
|
||||||
|
```
|
||||||
|
|
||||||
|
**Fix:**
|
||||||
|
|
||||||
|
```diff
|
||||||
|
ld hl, wCurDamage
|
||||||
|
ld a, [hli]
|
||||||
|
or [hl]
|
||||||
|
- ret z
|
||||||
|
+ jp z, .failed
|
||||||
|
```
|
||||||
|
|
||||||
|
Add this to the end of each file:
|
||||||
|
|
||||||
|
```diff
|
||||||
|
+.failed
|
||||||
|
+ ld a, 1
|
||||||
|
+ ld [wEffectFailed], a
|
||||||
|
+ and a
|
||||||
|
+ ret
|
||||||
|
```
|
||||||
|
|
||||||
|
|
||||||
## A Disabled but PP Up–enhanced move may not trigger Struggle
|
## A Disabled but PP Up–enhanced move may not trigger Struggle
|
||||||
|
@ -36,6 +36,7 @@ BattleCommand_Counter:
|
|||||||
cp SPECIAL
|
cp SPECIAL
|
||||||
ret nc
|
ret nc
|
||||||
|
|
||||||
|
; BUG: Move should fail with all non-damaging battle actions
|
||||||
ld hl, wCurDamage
|
ld hl, wCurDamage
|
||||||
ld a, [hli]
|
ld a, [hli]
|
||||||
or [hl]
|
or [hl]
|
||||||
|
@ -37,6 +37,7 @@ BattleCommand_MirrorCoat:
|
|||||||
cp SPECIAL
|
cp SPECIAL
|
||||||
ret c
|
ret c
|
||||||
|
|
||||||
|
; BUG: Move should fail with all non-damaging battle actions
|
||||||
ld hl, wCurDamage
|
ld hl, wCurDamage
|
||||||
ld a, [hli]
|
ld a, [hli]
|
||||||
or [hl]
|
or [hl]
|
||||||
|
Loading…
x
Reference in New Issue
Block a user