diff options
author | dannye <corrnondacqb@yahoo.com> | 2016-08-08 15:35:13 -0500 |
---|---|---|
committer | dannye <corrnondacqb@yahoo.com> | 2016-08-08 15:35:13 -0500 |
commit | fe02309fe38d8be4f0a087c63ca7d63cc9cab859 (patch) | |
tree | 6722b75c0cb6e2477e67fb1976a40331ed365546 /engine/items | |
parent | 33ea880aa4f408624b967d4ab811c477e6a76784 (diff) |
Add Devolve Stoneadding-pokemon
rolls back Pokemon to their pre-evolution without degenerating stats
Diffstat (limited to 'engine/items')
-rwxr-xr-x | engine/items/items.asm | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/engine/items/items.asm b/engine/items/items.asm index 95fea960..433a42d3 100755 --- a/engine/items/items.asm +++ b/engine/items/items.asm @@ -114,6 +114,7 @@ ItemUsePtrTable: dw UnusableItem ; FLOOR_11F dw UnusableItem ; FLOOR_B4F dw ItemUseEvoStone ; ICE_STONE + dw ItemUseEvoStone ; DEVOLVE_STONE ItemUseBall: @@ -777,9 +778,13 @@ ItemUseEvoStone: ld a,[wWhichPokemon] push af ld a,[wcf91] + cp DEVOLVE_STONE ld [wEvoStoneItemID],a push af + ld a,DEVO_STONE_PARTY_MENU + jr z, .devolveMenu ld a,EVO_STONE_PARTY_MENU +.devolveMenu ld [wPartyMenuTypeOrMessageID],a ld a,$ff ld [wUpdateSpritesEnabled],a @@ -793,7 +798,14 @@ ItemUseEvoStone: ld a,SFX_HEAL_AILMENT call PlaySoundWaitForCurrent call WaitForSoundToFinish + ld a, [wPartyMenuTypeOrMessageID] + cp DEVO_STONE_PARTY_MENU + jr z, .devolvePokemon callab TryEvolvingMon ; try to evolve pokemon + jr .doneEvolving +.devolvePokemon + callab DevolvePokemon +.doneEvolving ld a,[wEvolutionOccurred] and a jr z,.noEffect |