mirror of
https://gitlab.com/xCrystal/pokecrystal-board.git
synced 2024-11-16 11:27:33 -08:00
Bug Doc: Options menu fails to clear joypad state on initialization (#984)
This commit is contained in:
parent
0d5cf5c8b9
commit
38cd2155df
@ -103,6 +103,7 @@ Fixes in the [multi-player battle engine](#multi-player-battle-engine) category
|
|||||||
- [`ReadObjectEvents` overflows into `wObjectMasks`](#readobjectevents-overflows-into-wobjectmasks)
|
- [`ReadObjectEvents` overflows into `wObjectMasks`](#readobjectevents-overflows-into-wobjectmasks)
|
||||||
- [`ClearWRAM` only clears WRAM bank 1](#clearwram-only-clears-wram-bank-1)
|
- [`ClearWRAM` only clears WRAM bank 1](#clearwram-only-clears-wram-bank-1)
|
||||||
- [`BattleAnimCmd_ClearObjs` only clears the first 6⅔ objects](#battleanimcmd_clearobjs-only-clears-the-first-6-objects)
|
- [`BattleAnimCmd_ClearObjs` only clears the first 6⅔ objects](#battleanimcmd_clearobjs-only-clears-the-first-6-objects)
|
||||||
|
- [Options menu fails to clear joypad state on initialization](#options-menu-fails-to-clear-joypad-state-on-initialization)
|
||||||
|
|
||||||
|
|
||||||
## Multi-player battle engine
|
## Multi-player battle engine
|
||||||
@ -2629,3 +2630,21 @@ If `IsInArray` returns `nc`, data at `bc` will be executed as code.
|
|||||||
jr nz, .loop
|
jr nz, .loop
|
||||||
ret
|
ret
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
|
### Options menu fails to clear joypad state on initialization
|
||||||
|
|
||||||
|
([Video](https://www.youtube.com/watch?v=uhDSIkXkl3g))
|
||||||
|
|
||||||
|
This bug allows all the options to be updated at once if the left or right buttons are pressed on the same frame that the options menu is opened.
|
||||||
|
|
||||||
|
**Fix:** Edit `_Option` in [engine/menus/options_menu.asm](https://github.com/pret/pokecrystal/blob/master/engine/menus/options_menu.asm):
|
||||||
|
|
||||||
|
```diff
|
||||||
|
_Option:
|
||||||
|
-; BUG: Options menu fails to clear joypad state on initialization (see docs/bugs_and_glitches.md)
|
||||||
|
+ call ClearJoypad
|
||||||
|
ld hl, hInMenu
|
||||||
|
ld a, [hl]
|
||||||
|
push af
|
||||||
|
```
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
DEF NUM_OPTIONS EQU const_value ; 8
|
DEF NUM_OPTIONS EQU const_value ; 8
|
||||||
|
|
||||||
_Option:
|
_Option:
|
||||||
|
; BUG: Options menu fails to clear joypad state on initialization (see docs/bugs_and_glitches.md)
|
||||||
ld hl, hInMenu
|
ld hl, hInMenu
|
||||||
ld a, [hl]
|
ld a, [hl]
|
||||||
push af
|
push af
|
||||||
|
Loading…
Reference in New Issue
Block a user