Silph Gauntlet reset-on-victory

This functionally turns the Silph Gauntlet into a battle tower of sorts.

I did notice some weirdness post-event-reset so definitely do some tests. It should be fine, though.
This commit is contained in:
Llinos Evans 2023-12-24 18:13:41 +00:00
parent 355661350e
commit 6678af8722
7 changed files with 12 additions and 7 deletions

View file

@ -817,6 +817,7 @@ DEF INDIGO_PLATEAU_EVENTS_END EQU const_value - 1
const EVENT_BEAT_VICTORY_ROAD_1_TRAINER_1 const EVENT_BEAT_VICTORY_ROAD_1_TRAINER_1
const_skip 4 const_skip 4
const EVENT_VICTORY_ROAD_1_BOULDER_ON_SWITCH const EVENT_VICTORY_ROAD_1_BOULDER_ON_SWITCH
const EVENT_BEAT_CHIEF ; moved out of the below union to prevent bugs
; Silph Gauntlet events ; Silph Gauntlet events
const_next $930 const_next $930
@ -872,7 +873,7 @@ DEF SILPH_GAUNTLET_EVENTS_START EQU const_value
const EVENT_BEAT_GAUNTLET_SABRINA const EVENT_BEAT_GAUNTLET_SABRINA
const EVENT_BEAT_GAUNTLET_BLAINE const EVENT_BEAT_GAUNTLET_BLAINE
const_skip const_skip
const EVENT_BEAT_CHIEF const_skip
const_skip 5 const_skip 5
const_skip const_skip
DEF SILPH_GAUNTLET_EVENTS_END EQU const_value - 1 DEF SILPH_GAUNTLET_EVENTS_END EQU const_value - 1

View file

@ -4,11 +4,12 @@ RedsHouse2F_Object:
def_warp_events def_warp_events
warp_event 7, 1, REDS_HOUSE_1F, 3 warp_event 7, 1, REDS_HOUSE_1F, 3
;warp_event 5, 1, SILPH_GAUNTLET_7F, 1 ; - Test Chief ;warp_event 5, 1, SILPH_GAUNTLET_7F, 1 ; - Test Chief
warp_event 5, 1, SILPH_CO_1F, 1 ; - Go through Gauntlet
;warp_event 5, 1, SILPH_CO_11F, 2 ; - Test J&J, Omega, & Giovanni. To test the Omega refight, change to SHOW in hide/show data, and set warp ID to 1. ;warp_event 5, 1, SILPH_CO_11F, 2 ; - Test J&J, Omega, & Giovanni. To test the Omega refight, change to SHOW in hide/show data, and set warp ID to 1.
;warp_event 5, 1, ROCKET_HIDEOUT_B4F, 2 ; - Test Giovanni 1 ;warp_event 5, 1, ROCKET_HIDEOUT_B4F, 2 ; - Test Giovanni 1
;warp_event 5, 1, MT_MOON_SQUARE, 1 ; - Test Shop, NPCs, and Crater ;warp_event 5, 1, MT_MOON_SQUARE, 1 ; - Test Shop, NPCs, and Crater
;warp_event 5, 1, CELESTE_HILL, 1 ; - Test GMolt ;warp_event 5, 1, CELESTE_HILL, 1 ; - Test GMolt
warp_event 5, 1, HALL_OF_FAME, 1 ; Test post-game setup ;warp_event 5, 1, HALL_OF_FAME, 1 ; Test post-game setup
;warp_event 5, 1, GARNET_CAVERN_B1F, 1 ; Test GCuno ;warp_event 5, 1, GARNET_CAVERN_B1F, 1 ; Test GCuno
;warp_event 5, 1, FARAWAY_ISLAND_INSIDE, 1 ; Test Mew ;warp_event 5, 1, FARAWAY_ISLAND_INSIDE, 1 ; Test Mew
;warp_event 5, 1, GIOVANNIS_ROOM, 1 ; Test spinner tiles ;warp_event 5, 1, GIOVANNIS_ROOM, 1 ; Test spinner tiles

View file

@ -206,6 +206,7 @@ DebugItemsList:
db BICYCLE, 1 db BICYCLE, 1
db EXP_ALL, 1 db EXP_ALL, 1
db FULL_RESTORE, 99 db FULL_RESTORE, 99
db MAX_ELIXER, 99
db MAX_REPEL, 99 db MAX_REPEL, 99
db RARE_CANDY, 99 db RARE_CANDY, 99
db ESCAPE_ROPE, 99 db ESCAPE_ROPE, 99

View file

@ -9,6 +9,7 @@ SilphCo1F_ScriptPointers:
dw SilphCo1FScript1 dw SilphCo1FScript1
SilphCo1FScript0: SilphCo1FScript0:
ResetEvent EVENT_BEAT_CHIEF ; Used so you can rematch Chief and later the gauntlet, without him being reset alongside everything else. An absolutely tragic way to fix a bug, but it works. If you enter his room, you have to fight him, so this all works under the hood without infringing on design.
ld b, SILPHLETTER ld b, SILPHLETTER
call IsItemInBag call IsItemInBag
ret nz ret nz

View file

@ -71,7 +71,7 @@ ChiefScript3:
xor a xor a
ld [wIsTrainerBattle], a ld [wIsTrainerBattle], a
call UpdateSprites call UpdateSprites
SetEvent EVENT_BEAT_CHIEF SetEvent EVENT_BEAT_CHIEF ; Ensures Chief cannot be rematched in the room.
ld a, $f0 ld a, $f0
ld [wJoyIgnore], a ld [wJoyIgnore], a
ld a, $1 ld a, $1
@ -95,7 +95,7 @@ ChiefScript4:
ld a, HS_CERULEAN_CAVE_GUY ld a, HS_CERULEAN_CAVE_GUY
ld [wMissableObjectIndex], a ld [wMissableObjectIndex], a
predef HideObject predef HideObject
; ResetEventRange SILPH_GAUNTLET_EVENTS_START, SILPH_GAUNTLET_EVENTS_END, 1 ; I want this to reset the trainers so you can refight them, but I'm very unsure how this works... ResetEventRange SILPH_GAUNTLET_EVENTS_START, SILPH_GAUNTLET_EVENTS_END, 1
ld a, $0 ld a, $0
ld [wSilphGauntlet7FCurScript], a ld [wSilphGauntlet7FCurScript], a

View file

@ -58,8 +58,9 @@ _SilphGauntlet2FAfterBattleText3::
_SilphGauntlet2FBattleText4:: _SilphGauntlet2FBattleText4::
text "Hahaha! This is" text "Hahaha! This is"
line "great! So many" line "great! So many"
cont "rare #MON! Show" cont "rare #MON!"
cont "me yours, now!" para "Show me yours,"
line "now!"
done done
_SilphGauntlet2FEndBattleText4:: _SilphGauntlet2FEndBattleText4::

View file

@ -22,7 +22,7 @@ _SilphGauntlet3FBattleText2::
done done
_SilphGauntlet3FEndBattleText2:: _SilphGauntlet3FEndBattleText2::
text "Sploosh!" text "Agh!"
prompt prompt
_SilphGauntlet3FAfterBattleText2:: _SilphGauntlet3FAfterBattleText2::