2018-06-24 14:09:41 +00:00
|
|
|
BattleCommand_LeechSeed:
|
2018-01-26 16:36:00 +00:00
|
|
|
; leechseed
|
2018-02-03 23:21:53 +00:00
|
|
|
ld a, [wAttackMissed]
|
2018-01-26 16:36:00 +00:00
|
|
|
and a
|
|
|
|
jr nz, .evaded
|
|
|
|
call CheckSubstituteOpp
|
|
|
|
jr nz, .evaded
|
|
|
|
|
2018-02-03 23:21:53 +00:00
|
|
|
ld de, wEnemyMonType1
|
2018-08-25 18:28:22 +00:00
|
|
|
ldh a, [hBattleTurn]
|
2018-01-26 16:36:00 +00:00
|
|
|
and a
|
|
|
|
jr z, .ok
|
2018-02-03 23:21:53 +00:00
|
|
|
ld de, wBattleMonType1
|
2018-01-26 16:36:00 +00:00
|
|
|
.ok
|
|
|
|
|
|
|
|
ld a, [de]
|
|
|
|
cp GRASS
|
|
|
|
jr z, .grass
|
|
|
|
inc de
|
|
|
|
ld a, [de]
|
|
|
|
cp GRASS
|
|
|
|
jr z, .grass
|
|
|
|
|
|
|
|
ld a, BATTLE_VARS_SUBSTATUS4_OPP
|
|
|
|
call GetBattleVarAddr
|
|
|
|
bit SUBSTATUS_LEECH_SEED, [hl]
|
|
|
|
jr nz, .evaded
|
|
|
|
set SUBSTATUS_LEECH_SEED, [hl]
|
|
|
|
call AnimateCurrentMove
|
|
|
|
ld hl, WasSeededText
|
2019-04-08 12:15:10 +00:00
|
|
|
jp StdBattleTextbox
|
2018-01-26 16:36:00 +00:00
|
|
|
|
|
|
|
.grass
|
|
|
|
call AnimateFailedMove
|
|
|
|
jp PrintDoesntAffect
|
|
|
|
|
|
|
|
.evaded
|
|
|
|
call AnimateFailedMove
|
|
|
|
ld hl, EvadedText
|
2019-04-08 12:15:10 +00:00
|
|
|
jp StdBattleTextbox
|