aboutsummaryrefslogtreecommitdiffstats
path: root/engine/slop_menu.asm
diff options
context:
space:
mode:
Diffstat (limited to 'engine/slop_menu.asm')
-rw-r--r--engine/slop_menu.asm33
1 files changed, 31 insertions, 2 deletions
diff --git a/engine/slop_menu.asm b/engine/slop_menu.asm
index 140dc04b..36773423 100644
--- a/engine/slop_menu.asm
+++ b/engine/slop_menu.asm
@@ -8,7 +8,7 @@
; To add an entry: add a "NAME" line to SlopMenuText, a `dw Handler` to
; SlopMenuHandlers, and bump SLOP_MENU_COUNT.
-DEF SLOP_MENU_COUNT EQU 7
+DEF SLOP_MENU_COUNT EQU 9
SECTION "Slop Menu", ROMX
@@ -32,6 +32,14 @@ SlopMenu::
hlcoord 6, 3
ld de, SlopMenuText
call PlaceString
+; ON marker for the NOWILD toggle (item 7 -> row 10)
+ ld a, [wSlopNoWild]
+ and a
+ jr z, .nowildOff
+ hlcoord 13, 10
+ ld de, SlopOnText
+ call PlaceString
+.nowildOff
call SlopMenuShow
xor a
ld [wCurrentMenuItem], a
@@ -102,7 +110,11 @@ SlopMenuText:
next "BADGES"
next "DEX"
next "MAXTEAM"
- next "ITEMS@"
+ next "ITEMS"
+ next "NOWILD"
+ next "REPEL@"
+SlopOnText:
+ db "ON@"
SlopMenuHandlers:
dw WarpSubmenu
dw SlopHealParty
@@ -111,6 +123,8 @@ SlopMenuHandlers:
dw SlopDex
dw SlopMaxTeam
dw GiveItemSubmenu
+ dw SlopToggleNoWild
+ dw SlopRepel
; ===========================================================================
@@ -298,6 +312,21 @@ SlopMaxCash:
and a
ret
+; NOWILD toggle: no wild encounters (hooked in TryDoWildEncounter)
+SlopToggleNoWild:
+ ld a, [wSlopNoWild]
+ xor $01
+ ld [wSlopNoWild], a
+ and a
+ ret
+
+; REPEL: refill repel steps
+SlopRepel:
+ ld a, 255
+ ld [wRepelRemainingSteps], a
+ and a
+ ret
+
; BADGES: all 8
SlopAllBadges:
ld a, $ff