Skip to content

Commit

Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Name unnamed seafoam/mansion labels
Browse files Browse the repository at this point in the history
Vortyne committed Nov 19, 2023
1 parent 9ab48c5 commit 2bf69e2
Showing 10 changed files with 93 additions and 93 deletions.
2 changes: 1 addition & 1 deletion engine/overworld/push_boulder.asm
Original file line number Diff line number Diff line change
@@ -94,7 +94,7 @@ DoBoulderDustAnimation::
call DiscardButtonPresses
ld [wJoyIgnore], a
call ResetBoulderPushFlags
set 7, [hl]
set 7, [hl] ; [wFlags_0xcd60]
ld a, [wBoulderSpriteIndex]
ldh [hSpriteIndex], a
call GetSpriteMovementByte2Pointer
4 changes: 2 additions & 2 deletions scripts/PokemonMansion1F.asm
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
PokemonMansion1F_Script:
call Mansion1Subscript1
call Mansion1CheckReplaceSwitchDoorBlocks
call EnableAutoTextBoxDrawing
ld hl, Mansion1TrainerHeaders
ld de, PokemonMansion1F_ScriptPointers
@@ -8,7 +8,7 @@ PokemonMansion1F_Script:
ld [wPokemonMansion1FCurScript], a
ret

Mansion1Subscript1:
Mansion1CheckReplaceSwitchDoorBlocks:
ld hl, wCurrentMapScriptFlags
bit 5, [hl]
res 5, [hl]
22 changes: 11 additions & 11 deletions scripts/PokemonMansion2F.asm
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
PokemonMansion2F_Script:
call Mansion2Script_51fee
call Mansion2CheckReplaceSwitchDoorBlocks
call EnableAutoTextBoxDrawing
ld hl, Mansion2TrainerHeaders
ld de, PokemonMansion2F_ScriptPointers
@@ -8,36 +8,36 @@ PokemonMansion2F_Script:
ld [wPokemonMansion2FCurScript], a
ret

Mansion2Script_51fee:
Mansion2CheckReplaceSwitchDoorBlocks:
ld hl, wCurrentMapScriptFlags
bit 5, [hl]
res 5, [hl]
ret z
CheckEvent EVENT_MANSION_SWITCH_ON
jr nz, .asm_52016
jr nz, .switchTurnedOn
ld a, $e
lb bc, 2, 4
call Mansion2Script_5202f
call Mansion2ReplaceBlock
ld a, $54
lb bc, 4, 9
call Mansion2Script_5202f
call Mansion2ReplaceBlock
ld a, $5f
lb bc, 11, 3
call Mansion2Script_5202f
call Mansion2ReplaceBlock
ret
.asm_52016
.switchTurnedOn
ld a, $5f
lb bc, 2, 4
call Mansion2Script_5202f
call Mansion2ReplaceBlock
ld a, $e
lb bc, 4, 9
call Mansion2Script_5202f
call Mansion2ReplaceBlock
ld a, $e
lb bc, 11, 3
call Mansion2Script_5202f
call Mansion2ReplaceBlock
ret

Mansion2Script_5202f:
Mansion2ReplaceBlock:
ld [wNewTileBlockID], a
predef_jump ReplaceTileBlock

24 changes: 12 additions & 12 deletions scripts/PokemonMansion3F.asm
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
PokemonMansion3F_Script:
call Mansion3Script_52204
call Mansion3CheckReplaceSwitchDoorBlocks
call EnableAutoTextBoxDrawing
ld hl, Mansion3TrainerHeaders
ld de, PokemonMansion3F_ScriptPointers
@@ -8,27 +8,27 @@ PokemonMansion3F_Script:
ld [wPokemonMansion3FCurScript], a
ret

Mansion3Script_52204:
Mansion3CheckReplaceSwitchDoorBlocks:
ld hl, wCurrentMapScriptFlags
bit 5, [hl]
res 5, [hl]
ret z
CheckEvent EVENT_MANSION_SWITCH_ON
jr nz, .asm_52224
jr nz, .switchTurnedOn
ld a, $e
lb bc, 2, 7
call Mansion2Script_5202f
call Mansion2ReplaceBlock
ld a, $5f
lb bc, 5, 7
call Mansion2Script_5202f
call Mansion2ReplaceBlock
ret
.asm_52224
.switchTurnedOn
ld a, $5f
lb bc, 2, 7
call Mansion2Script_5202f
call Mansion2ReplaceBlock
ld a, $e
lb bc, 5, 7
call Mansion2Script_5202f
call Mansion2ReplaceBlock
ret

PokemonMansion3F_ScriptPointers:
@@ -38,8 +38,8 @@ PokemonMansion3F_ScriptPointers:
dw_const EndTrainerBattle, SCRIPT_POKEMONMANSION3F_END_BATTLE

PokemonMansion3FDefaultScript:
ld hl, CoordsData_52254
call Mansion3Script_5225b
ld hl, .holeCoords
call .isPlayerFallingDownHole
ld a, [wWhichDungeonWarp]
and a
jp z, CheckFightingMapTrainers
@@ -51,13 +51,13 @@ PokemonMansion3FDefaultScript:
ld [wDungeonWarpDestinationMap], a
ret

CoordsData_52254:
.holeCoords:
dbmapcoord 16, 14
dbmapcoord 17, 14
dbmapcoord 19, 14
db -1 ; end

Mansion3Script_5225b:
.isPlayerFallingDownHole:
xor a
ld [wWhichDungeonWarp], a
ld a, [wd72d]
24 changes: 12 additions & 12 deletions scripts/PokemonMansionB1F.asm
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
PokemonMansionB1F_Script:
call Mansion4Script_523cf
call MansionB1FCheckReplaceSwitchDoorBlocks
call EnableAutoTextBoxDrawing
ld hl, Mansion4TrainerHeaders
ld de, PokemonMansionB1F_ScriptPointers
@@ -8,39 +8,39 @@ PokemonMansionB1F_Script:
ld [wPokemonMansionB1FCurScript], a
ret

Mansion4Script_523cf:
MansionB1FCheckReplaceSwitchDoorBlocks:
ld hl, wCurrentMapScriptFlags
bit 5, [hl]
res 5, [hl]
ret z
CheckEvent EVENT_MANSION_SWITCH_ON
jr nz, .asm_523ff
jr nz, .switchTurnedOn
ld a, $e
ld bc, $80d
call Mansion2Script_5202f
call Mansion2ReplaceBlock
ld a, $e
ld bc, $b06
call Mansion2Script_5202f
call Mansion2ReplaceBlock
ld a, $5f
ld bc, $304
call Mansion2Script_5202f
call Mansion2ReplaceBlock
ld a, $54
ld bc, $808
call Mansion2Script_5202f
call Mansion2ReplaceBlock
ret
.asm_523ff
.switchTurnedOn
ld a, $2d
ld bc, $80d
call Mansion2Script_5202f
call Mansion2ReplaceBlock
ld a, $5f
ld bc, $b06
call Mansion2Script_5202f
call Mansion2ReplaceBlock
ld a, $e
ld bc, $304
call Mansion2Script_5202f
call Mansion2ReplaceBlock
ld a, $e
ld bc, $808
call Mansion2Script_5202f
call Mansion2ReplaceBlock
ret

Mansion4Script_Switches::
12 changes: 6 additions & 6 deletions scripts/SeafoamIslands1F.asm
Original file line number Diff line number Diff line change
@@ -4,34 +4,34 @@ SeafoamIslands1F_Script:
ld hl, wFlags_0xcd60
bit 7, [hl]
res 7, [hl]
jr z, .asm_4483b
jr z, .noBoulderWasPushed
ld hl, Seafoam1HolesCoords
call CheckBoulderCoords
ret nc
EventFlagAddress hl, EVENT_SEAFOAM1_BOULDER1_DOWN_HOLE
ld a, [wCoordIndex]
cp $1
jr nz, .asm_44819
jr nz, .boulder2FellDownHole
SetEventReuseHL EVENT_SEAFOAM1_BOULDER1_DOWN_HOLE
ld a, HS_SEAFOAM_ISLANDS_1F_BOULDER_1
ld [wObjectToHide], a
ld a, HS_SEAFOAM_ISLANDS_B1F_BOULDER_1
ld [wObjectToShow], a
jr .asm_44825
.asm_44819
jr .hideAndShowBoulderObjects
.boulder2FellDownHole
SetEventAfterBranchReuseHL EVENT_SEAFOAM1_BOULDER2_DOWN_HOLE, EVENT_SEAFOAM1_BOULDER1_DOWN_HOLE
ld a, HS_SEAFOAM_ISLANDS_1F_BOULDER_2
ld [wObjectToHide], a
ld a, HS_SEAFOAM_ISLANDS_B1F_BOULDER_2
ld [wObjectToShow], a
.asm_44825
.hideAndShowBoulderObjects
ld a, [wObjectToHide]
ld [wMissableObjectIndex], a
predef HideObject
ld a, [wObjectToShow]
ld [wMissableObjectIndex], a
predef_jump ShowObject
.asm_4483b
.noBoulderWasPushed
ld a, SEAFOAM_ISLANDS_B1F
ld [wDungeonWarpDestinationMap], a
ld hl, Seafoam1HolesCoords
12 changes: 6 additions & 6 deletions scripts/SeafoamIslandsB1F.asm
Original file line number Diff line number Diff line change
@@ -3,34 +3,34 @@ SeafoamIslandsB1F_Script:
ld hl, wFlags_0xcd60
bit 7, [hl]
res 7, [hl]
jr z, .asm_46362
jr z, .noBoulderWasPushed
ld hl, Seafoam2HolesCoords
call CheckBoulderCoords
ret nc
EventFlagAddress hl, EVENT_SEAFOAM2_BOULDER1_DOWN_HOLE
ld a, [wCoordIndex]
cp $1
jr nz, .asm_46340
jr nz, .boulder2FellDownHole
SetEventReuseHL EVENT_SEAFOAM2_BOULDER1_DOWN_HOLE
ld a, HS_SEAFOAM_ISLANDS_B1F_BOULDER_1
ld [wObjectToHide], a
ld a, HS_SEAFOAM_ISLANDS_B2F_BOULDER_1
ld [wObjectToShow], a
jr .asm_4634c
.asm_46340
jr .hideAndShowBoulderObjects
.boulder2FellDownHole
SetEventAfterBranchReuseHL EVENT_SEAFOAM2_BOULDER2_DOWN_HOLE, EVENT_SEAFOAM2_BOULDER1_DOWN_HOLE
ld a, HS_SEAFOAM_ISLANDS_B1F_BOULDER_2
ld [wObjectToHide], a
ld a, HS_SEAFOAM_ISLANDS_B2F_BOULDER_2
ld [wObjectToShow], a
.asm_4634c
.hideAndShowBoulderObjects
ld a, [wObjectToHide]
ld [wMissableObjectIndex], a
predef HideObject
ld a, [wObjectToShow]
ld [wMissableObjectIndex], a
predef_jump ShowObject
.asm_46362
.noBoulderWasPushed
ld a, SEAFOAM_ISLANDS_B2F
ld [wDungeonWarpDestinationMap], a
ld hl, Seafoam2HolesCoords
12 changes: 6 additions & 6 deletions scripts/SeafoamIslandsB2F.asm
Original file line number Diff line number Diff line change
@@ -3,34 +3,34 @@ SeafoamIslandsB2F_Script:
ld hl, wFlags_0xcd60
bit 7, [hl]
res 7, [hl]
jr z, .asm_4649e
jr z, .noBoulderWasPushed
ld hl, Seafoam3HolesCoords
call CheckBoulderCoords
ret nc
EventFlagAddress hl, EVENT_SEAFOAM3_BOULDER1_DOWN_HOLE
ld a, [wCoordIndex]
cp $1
jr nz, .asm_4647c
jr nz, .boulder2FellDownHole
SetEventReuseHL EVENT_SEAFOAM3_BOULDER1_DOWN_HOLE
ld a, HS_SEAFOAM_ISLANDS_B2F_BOULDER_1
ld [wObjectToHide], a
ld a, HS_SEAFOAM_ISLANDS_B3F_BOULDER_3
ld [wObjectToShow], a
jr .asm_46488
.asm_4647c
jr .hideAndShowBoulderObjects
.boulder2FellDownHole
SetEventAfterBranchReuseHL EVENT_SEAFOAM3_BOULDER2_DOWN_HOLE, EVENT_SEAFOAM3_BOULDER1_DOWN_HOLE
ld a, HS_SEAFOAM_ISLANDS_B2F_BOULDER_2
ld [wObjectToHide], a
ld a, HS_SEAFOAM_ISLANDS_B3F_BOULDER_4
ld [wObjectToShow], a
.asm_46488
.hideAndShowBoulderObjects
ld a, [wObjectToHide]
ld [wMissableObjectIndex], a
predef HideObject
ld a, [wObjectToShow]
ld [wMissableObjectIndex], a
predef_jump ShowObject
.asm_4649e
.noBoulderWasPushed
ld a, SEAFOAM_ISLANDS_B3F
ld [wDungeonWarpDestinationMap], a
ld hl, Seafoam3HolesCoords
Loading

0 comments on commit 2bf69e2

Please sign in to comment.