2015-11-06 11:45:10 -08:00
|
|
|
BattleCommand_Foresight: ; 376a0
|
2013-12-01 11:19:57 -08:00
|
|
|
; foresight
|
|
|
|
|
2018-01-23 14:39:09 -08:00
|
|
|
ld a, [wAttackMissed]
|
2013-12-01 11:19:57 -08:00
|
|
|
and a
|
|
|
|
jr nz, .failed
|
|
|
|
|
|
|
|
call CheckHiddenOpponent
|
|
|
|
jr nz, .failed
|
|
|
|
|
|
|
|
ld a, BATTLE_VARS_SUBSTATUS1_OPP
|
2014-06-14 00:34:57 -07:00
|
|
|
call GetBattleVarAddr
|
2013-12-01 11:19:57 -08:00
|
|
|
bit SUBSTATUS_IDENTIFIED, [hl]
|
|
|
|
jr nz, .failed
|
|
|
|
|
|
|
|
set SUBSTATUS_IDENTIFIED, [hl]
|
2014-01-01 05:09:15 -08:00
|
|
|
call AnimateCurrentMove
|
2013-12-01 11:19:57 -08:00
|
|
|
ld hl, IdentifiedText
|
|
|
|
jp StdBattleTextBox
|
|
|
|
|
|
|
|
.failed
|
2018-01-26 08:36:00 -08:00
|
|
|
jp FailMove
|
2013-12-01 11:19:57 -08:00
|
|
|
; 376c2
|