Compare commits
10 Commits
beta
...
pikit_mode
| Author | SHA1 | Date | |
|---|---|---|---|
| 0264a85511 | |||
| 0f36eca4ab | |||
| bd722bef33 | |||
| 9208d06f3a | |||
| 2a31b7763b | |||
| 779c9a27ce | |||
| 381868c3ce | |||
| f6c0de88fb | |||
| f609727647 | |||
| 2dcfd8e67a |
@@ -206,7 +206,6 @@ warnpc $A38000
|
|||||||
|
|
||||||
org $B98000
|
org $B98000
|
||||||
incsrc gk/crystalswitchbook.asm
|
incsrc gk/crystalswitchbook.asm
|
||||||
incsrc gk/orange_potion.asm
|
|
||||||
incsrc gk/mimicdash.asm
|
incsrc gk/mimicdash.asm
|
||||||
incsrc gk/gloom.asm
|
incsrc gk/gloom.asm
|
||||||
incsrc gk/special_weapons.asm
|
incsrc gk/special_weapons.asm
|
||||||
@@ -214,7 +213,7 @@ incsrc gk/variable_ganon_vulnerability.asm
|
|||||||
incsrc gk/pseudoflute.asm
|
incsrc gk/pseudoflute.asm
|
||||||
incsrc gk/fast_junk.asm
|
incsrc gk/fast_junk.asm
|
||||||
incsrc gk/dungeon_maps.asm
|
incsrc gk/dungeon_maps.asm
|
||||||
incsrc gk/dungeon_indicator.asm
|
incsrc pikit.asm
|
||||||
print "End of B9: ", pc
|
print "End of B9: ", pc
|
||||||
|
|
||||||
warnpc $B9EE00
|
warnpc $B9EE00
|
||||||
|
|||||||
@@ -53,13 +53,24 @@ RTL
|
|||||||
GiveBonkItem:
|
GiveBonkItem:
|
||||||
LDA.w SprItemMWPlayer, X : STA.l !MULTIWORLD_ITEM_PLAYER_ID
|
LDA.w SprItemMWPlayer, X : STA.l !MULTIWORLD_ITEM_PLAYER_ID
|
||||||
LDA.w SprSourceItemId, X
|
LDA.w SprSourceItemId, X
|
||||||
|
|
||||||
|
PHY : TAY
|
||||||
|
JSL ShieldCheck
|
||||||
|
TYA : PLY
|
||||||
|
BCS +
|
||||||
|
|
||||||
|
STZ.w $0DD0, X
|
||||||
|
PLA : PLA : PLA ; remove the stored return address
|
||||||
|
JML $85FC9D
|
||||||
|
|
||||||
|
+
|
||||||
JSR AbsorbKeyCheck : BCC .notKey
|
JSR AbsorbKeyCheck : BCC .notKey
|
||||||
PHY : LDY.b #$24 : JSL AddInventory : PLY ; do inventory processing for a small key
|
PHY : LDY.b #$24 : JSL AddInventory : PLY ; do inventory processing for a small key
|
||||||
LDA.l CurrentSmallKeys : INC A : STA.l CurrentSmallKeys
|
LDA.l CurrentSmallKeys : INC A : STA.l CurrentSmallKeys
|
||||||
LDA.b #$2F : JSL Sound_SetSfx3PanLong
|
LDA.b #$2F : JSL Sound_SetSfx3PanLong
|
||||||
LDA.b #$01 : STA.l UpdateHUDFlag
|
LDA.b #$01 : STA.l UpdateHUDFlag
|
||||||
RTL
|
RTL
|
||||||
.notKey
|
.notKey
|
||||||
PHY : TAY : JSL Link_ReceiveItem : PLY
|
PHY : TAY : JSL Link_ReceiveItem : PLY
|
||||||
RTL
|
RTL
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
|
|||||||
@@ -246,7 +246,7 @@ FixSwimBump:
|
|||||||
.normal
|
.normal
|
||||||
LDA.b LinkJumping : BNE .continue ; what we wrote over
|
LDA.b LinkJumping : BNE .continue ; what we wrote over
|
||||||
.not_diving
|
.not_diving
|
||||||
PLA : PLA : PEA.w $87964D ; skip ahead, not diving
|
PLA : PLA : PEA.w $87964E ; skip ahead, not diving
|
||||||
.continue
|
.continue
|
||||||
RTL
|
RTL
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
|
|||||||
@@ -49,14 +49,14 @@ InvertDPad_DPadLROnly:
|
|||||||
LDA.w JOY1L : STA.b Scrap00
|
LDA.w JOY1L : STA.b Scrap00
|
||||||
LDA.w JOY1H
|
LDA.w JOY1H
|
||||||
BIT.b #$03 : BEQ + : EOR.b #$03 : + ; swap left/right
|
BIT.b #$03 : BEQ + : EOR.b #$03 : + ; swap left/right
|
||||||
STA.b Scrap01
|
STA.b Scrap00
|
||||||
JML InvertDPadReturn
|
JML InvertDPadReturn
|
||||||
|
|
||||||
InvertDPad_DPadUDOnly:
|
InvertDPad_DPadUDOnly:
|
||||||
LDA.w JOY1L : STA.b Scrap00
|
LDA.w JOY1L : STA.b Scrap00
|
||||||
LDA.w JOY1H
|
LDA.w JOY1H
|
||||||
BIT.b #$0C : BEQ + : EOR.b #$0C : + ; swap up/down
|
BIT.b #$0C : BEQ + : EOR.b #$0C : + ; swap up/down
|
||||||
STA.b Scrap01
|
STA.b Scrap00
|
||||||
JML InvertDPadReturn
|
JML InvertDPadReturn
|
||||||
|
|
||||||
InvertDPad:
|
InvertDPad:
|
||||||
|
|||||||
@@ -146,57 +146,32 @@ macro SetMinimum(base,filler,compare)
|
|||||||
endmacro
|
endmacro
|
||||||
RefreshRainAmmo:
|
RefreshRainAmmo:
|
||||||
LDA.l ProgressIndicator : CMP.b #$01 : BEQ .rain ; check if we're in rain state
|
LDA.l ProgressIndicator : CMP.b #$01 : BEQ .rain ; check if we're in rain state
|
||||||
|
RTL
|
||||||
|
.rain
|
||||||
|
LDA.l StartingEntrance
|
||||||
|
+ CMP.b #$03 : BNE + ; Uncle
|
||||||
|
%SetMinimum(CurrentMagic,MagicFiller,RainDeathRefillMagic_Uncle)
|
||||||
|
%SetMinimum(BombsEquipment,BombsFiller,RainDeathRefillBombs_Uncle)
|
||||||
|
LDA.l ArrowMode : BEQ ++
|
||||||
|
LDA.l BowEquipment : BEQ +++
|
||||||
|
++ %SetMinimum(CurrentArrows,ArrowsFiller,RainDeathRefillArrows_Uncle)
|
||||||
|
+++ BRA .done
|
||||||
|
+ CMP.b #$02 : BNE + ; Cell
|
||||||
|
%SetMinimum(CurrentMagic,MagicFiller,RainDeathRefillMagic_Cell)
|
||||||
|
%SetMinimum(BombsEquipment,BombsFiller,RainDeathRefillBombs_Cell)
|
||||||
|
LDA.l ArrowMode : BEQ ++
|
||||||
|
LDA.l BowEquipment : BEQ .done
|
||||||
|
++ %SetMinimum(CurrentArrows,ArrowsFiller,RainDeathRefillArrows_Cell)
|
||||||
|
BRA .done
|
||||||
|
+ CMP.b #$04 : BNE + ; Mantle
|
||||||
|
%SetMinimum(CurrentMagic,MagicFiller,RainDeathRefillMagic_Mantle)
|
||||||
|
%SetMinimum(BombsEquipment,BombsFiller,RainDeathRefillBombs_Mantle)
|
||||||
|
LDA.l ArrowMode : BEQ ++
|
||||||
|
LDA.l BowEquipment : BEQ .done
|
||||||
|
++ %SetMinimum(CurrentArrows,ArrowsFiller,RainDeathRefillArrows_Mantle)
|
||||||
|
+
|
||||||
|
.done
|
||||||
RTL
|
RTL
|
||||||
.rain
|
|
||||||
LDA.l StartingEntrance : BEQ .uncle
|
|
||||||
CMP.b #$03 : BNE + ; Uncle
|
|
||||||
.uncle
|
|
||||||
LDA.l RainDeathRefillMagic_Uncle : JSR .refillMagic
|
|
||||||
LDA.l RainDeathRefillBombs_Uncle : JSR .refillBombs
|
|
||||||
LDA.l ArrowMode : BNE .rupeeBow
|
|
||||||
LDA.l RainDeathRefillArrows_Uncle : JSR .refillArrows
|
|
||||||
BRA .done
|
|
||||||
+ CMP.b #$02 : BNE + ; Cell
|
|
||||||
LDA.l RainDeathRefillMagic_Cell : JSR .refillMagic
|
|
||||||
LDA.l RainDeathRefillBombs_Cell : JSR .refillBombs
|
|
||||||
LDA.l ArrowMode : BNE .rupeeBow
|
|
||||||
LDA.l RainDeathRefillArrows_Cell : JSR .refillArrows
|
|
||||||
BRA .done
|
|
||||||
+ CMP.b #$04 : BNE + ; Mantle
|
|
||||||
LDA.l RainDeathRefillMagic_Mantle : JSR .refillMagic
|
|
||||||
LDA.l RainDeathRefillBombs_Mantle : JSR .refillBombs
|
|
||||||
LDA.l ArrowMode : BNE .rupeeBow
|
|
||||||
LDA.l RainDeathRefillArrows_Mantle : JSR .refillArrows
|
|
||||||
BRA .done
|
|
||||||
+ BRA .done
|
|
||||||
|
|
||||||
.rupeeBow
|
|
||||||
REP #$20
|
|
||||||
LDA.l RainDeathRefillRupeeBow : JSR .refillRupees
|
|
||||||
SEP #$20
|
|
||||||
|
|
||||||
.done
|
|
||||||
RTL
|
|
||||||
|
|
||||||
.refillMagic
|
|
||||||
SEC : SBC.l CurrentMagic : BCC +
|
|
||||||
STA.l MagicFiller
|
|
||||||
+ RTS
|
|
||||||
|
|
||||||
.refillBombs
|
|
||||||
SEC : SBC.l BombsEquipment : BCC +
|
|
||||||
STA.l BombsFiller
|
|
||||||
+ RTS
|
|
||||||
|
|
||||||
.refillArrows
|
|
||||||
SEC : SBC.l CurrentArrows : BCC +
|
|
||||||
STA.l ArrowsFiller
|
|
||||||
+ RTS
|
|
||||||
|
|
||||||
.refillRupees
|
|
||||||
CMP.l CurrentRupees : BCC +
|
|
||||||
STA.l CurrentRupees
|
|
||||||
+ RTS
|
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
SetEscapeAssist:
|
SetEscapeAssist:
|
||||||
LDA.l ProgressIndicator : CMP.b #$01 : BNE .no_train ; check if we're in rain state
|
LDA.l ProgressIndicator : CMP.b #$01 : BNE .no_train ; check if we're in rain state
|
||||||
|
|||||||
BIN
data/c2e3e.bin
BIN
data/c2e3e.bin
Binary file not shown.
BIN
data/c2e3e.gfx
BIN
data/c2e3e.gfx
Binary file not shown.
@@ -29,4 +29,3 @@ Z=33
|
|||||||
'=35
|
'=35
|
||||||
-=36
|
-=36
|
||||||
.=37
|
.=37
|
||||||
*=FF
|
|
||||||
|
|||||||
Binary file not shown.
BIN
data/i18n_en.bin
BIN
data/i18n_en.bin
Binary file not shown.
Binary file not shown.
@@ -78,10 +78,23 @@ JML Dungeon_OpenKeyedObject_nextChest
|
|||||||
|
|
||||||
LDA.l ChestData, X : ASL A : BCC .smallChest
|
LDA.l ChestData, X : ASL A : BCC .smallChest
|
||||||
|
|
||||||
JML Dungeon_OpenKeyedObject_bigChest ;(bank01.asm line #13783)
|
PHY
|
||||||
|
LDY.b Scrap0C
|
||||||
|
JSL ShieldCheck
|
||||||
|
STY.b Scrap0C
|
||||||
|
PLY
|
||||||
|
BCC .couldntFindChest
|
||||||
|
JML Dungeon_OpenKeyedObject_bigChest ;(bank01.asm line #13783)
|
||||||
|
|
||||||
.smallChest
|
.smallChest
|
||||||
JML Dungeon_OpenKeyedObject_smallChest
|
PHY
|
||||||
|
LDY.b Scrap0C
|
||||||
|
JSL ShieldCheck
|
||||||
|
STY.b Scrap0C
|
||||||
|
PLY
|
||||||
|
BCC .couldntFindChest
|
||||||
|
JML Dungeon_OpenKeyedObject_smallChest
|
||||||
|
|
||||||
.couldntFindChest
|
.couldntFindChest
|
||||||
JML Dungeon_OpenKeyedObject_couldntFindChest
|
JML Dungeon_OpenKeyedObject_couldntFindChest
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
|
|||||||
124
dialog.asm
124
dialog.asm
@@ -61,84 +61,73 @@ LoadDialogAddressIndirect:
|
|||||||
RTL
|
RTL
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
FreeDungeonItemNotice:
|
FreeDungeonItemNotice:
|
||||||
STA.l ScratchBufferV
|
STA.l ScratchBufferV
|
||||||
|
|
||||||
PHA : PHX : PHY
|
PHA : PHX : PHY
|
||||||
PHP
|
PHP
|
||||||
PHB : PHK : PLB
|
PHB : PHK : PLB
|
||||||
SEP #$20 ; set 8-bit accumulator
|
SEP #$20 ; set 8-bit accumulator
|
||||||
REP #$10 ; set 16-bit index registers
|
REP #$10 ; set 16-bit index registers
|
||||||
PEI.b (Scrap00)
|
PEI.b (Scrap00)
|
||||||
LDA.b Scrap02 : PHA
|
LDA.b Scrap02 : PHA
|
||||||
LDA.l ScratchBufferNV : PHA
|
LDA.l ScratchBufferNV : PHA
|
||||||
LDA.l ScratchBufferNV+1 : PHA
|
LDA.l ScratchBufferNV+1 : PHA
|
||||||
;--------------------------------
|
;--------------------------------
|
||||||
|
|
||||||
LDA.l !MULTIWORLD_ITEM_PLAYER_ID : BEQ +
|
LDA.l FreeItemText : BNE + : JMP .skip : +
|
||||||
LDA.b #$2F ; if not from our world, show all dungeon item and crystal notices
|
|
||||||
+ ORA.l FreeItemText : BNE + : JMP .skip : +
|
|
||||||
|
|
||||||
STA.b Scrap00
|
|
||||||
LDA.b #$00 : STA.l ScratchBufferNV ; initialize scratch
|
LDA.b #$00 : STA.l ScratchBufferNV ; initialize scratch
|
||||||
|
LDA.l FreeItemText : AND.b #$01 : BEQ + ; show message for general small key
|
||||||
LDA.b Scrap00 : AND.b #$01 : BEQ + ; show message for general small key
|
|
||||||
LDA.l ScratchBufferV : CMP.b #$24 : BNE + ; general small key
|
LDA.l ScratchBufferV : CMP.b #$24 : BNE + ; general small key
|
||||||
%CopyDialog(Notice_SmallKeyOf)
|
%CopyDialog(Notice_SmallKeyOf)
|
||||||
LDA.l DialogReturnPointer : DEC #2 : STA.l DialogOffsetPointer
|
LDA.l DialogReturnPointer : DEC #2 : STA.l DialogOffsetPointer
|
||||||
%CopyDialog(Notice_Self)
|
%CopyDialog(Notice_Self)
|
||||||
JMP .done
|
JMP .done
|
||||||
|
+ : LDA.l FreeItemText : AND.b #$02 : BEQ + ; show message for general compass
|
||||||
+ LDA.b Scrap00 : AND.b #$02 : BEQ + ; show message for general compass
|
|
||||||
LDA.l ScratchBufferV : CMP.b #$25 : BNE + ; general compass
|
LDA.l ScratchBufferV : CMP.b #$25 : BNE + ; general compass
|
||||||
%CopyDialog(Notice_CompassOf)
|
%CopyDialog(Notice_CompassOf)
|
||||||
LDA.l DialogReturnPointer : DEC #2 : STA.l DialogOffsetPointer
|
LDA.l DialogReturnPointer : DEC #2 : STA.l DialogOffsetPointer
|
||||||
%CopyDialog(Notice_Self)
|
%CopyDialog(Notice_Self)
|
||||||
JMP .done
|
JMP .done
|
||||||
|
+ : LDA.l FreeItemText : AND.b #$04 : BEQ + ; show message for general map
|
||||||
+ LDA.b Scrap00 : AND.b #$04 : BEQ + ; show message for general map
|
|
||||||
LDA.l ScratchBufferV : CMP.b #$33 : BNE + ; general map
|
LDA.l ScratchBufferV : CMP.b #$33 : BNE + ; general map
|
||||||
%CopyDialog(Notice_MapOf)
|
%CopyDialog(Notice_MapOf)
|
||||||
LDA.l DialogReturnPointer : DEC #2 : STA.l DialogOffsetPointer
|
LDA.l DialogReturnPointer : DEC #2 : STA.l DialogOffsetPointer
|
||||||
%CopyDialog(Notice_Self)
|
%CopyDialog(Notice_Self)
|
||||||
JMP .done
|
JMP .done
|
||||||
|
+ : LDA.l FreeItemText : AND.b #$08 : BEQ + ; show message for general big key
|
||||||
+ LDA.b Scrap00 : AND.b #$08 : BEQ + ; show message for general big key
|
|
||||||
LDA.l ScratchBufferV : CMP.b #$32 : BNE + ; general big key
|
LDA.l ScratchBufferV : CMP.b #$32 : BNE + ; general big key
|
||||||
%CopyDialog(Notice_BigKeyOf)
|
%CopyDialog(Notice_BigKeyOf)
|
||||||
LDA.l DialogReturnPointer : DEC #2 : STA.l DialogOffsetPointer
|
LDA.l DialogReturnPointer : DEC #2 : STA.l DialogOffsetPointer
|
||||||
%CopyDialog(Notice_Self)
|
%CopyDialog(Notice_Self)
|
||||||
JMP .done
|
JMP .done
|
||||||
|
+
|
||||||
+ LDA.b Scrap00 : AND.b #$04 : BEQ + ; show message for dungeon map
|
LDA.l FreeItemText : AND.b #$04 : BEQ + ; show message for dungeon map
|
||||||
LDA.l ScratchBufferV : AND.b #$F0 ; looking at high bits only
|
LDA.l ScratchBufferV : AND.b #$F0 ; looking at high bits only
|
||||||
CMP.b #$70 : BNE + ; map of...
|
CMP.b #$70 : BNE + ; map of...
|
||||||
%CopyDialog(Notice_MapOf)
|
%CopyDialog(Notice_MapOf)
|
||||||
JMP .dungeon
|
JMP .dungeon
|
||||||
|
+ : LDA.l FreeItemText : AND.b #$02 : BEQ + ; show message for dungeon compass
|
||||||
+ LDA.b Scrap00 : AND.b #$02 : BEQ + ; show message for dungeon compass
|
|
||||||
LDA.l ScratchBufferV : AND.b #$F0 : CMP.b #$80 : BNE + ; compass of...
|
LDA.l ScratchBufferV : AND.b #$F0 : CMP.b #$80 : BNE + ; compass of...
|
||||||
%CopyDialog(Notice_CompassOf)
|
%CopyDialog(Notice_CompassOf)
|
||||||
JMP .dungeon
|
JMP .dungeon
|
||||||
|
+ : LDA.l FreeItemText : AND.b #$08 : BEQ + ; show message for dungeon big key
|
||||||
+ LDA.b Scrap00 : AND.b #$08 : BEQ + ; show message for dungeon big key
|
|
||||||
LDA.l ScratchBufferV : AND.b #$F0 : CMP.b #$90 : BNE + ; big key of...
|
LDA.l ScratchBufferV : AND.b #$F0 : CMP.b #$90 : BNE + ; big key of...
|
||||||
%CopyDialog(Notice_BigKeyOf)
|
%CopyDialog(Notice_BigKeyOf)
|
||||||
JMP .dungeon
|
JMP .dungeon
|
||||||
|
+ : LDA.l FreeItemText : AND.b #$01 : BEQ + ; show message for dungeon small key
|
||||||
+ LDA.b Scrap00 : AND.b #$01 : BEQ + ; show message for dungeon small key
|
|
||||||
LDA.l ScratchBufferV : AND.b #$F0 : CMP.b #$A0 : BNE + ; small key of...
|
LDA.l ScratchBufferV : AND.b #$F0 : CMP.b #$A0 : BNE + ; small key of...
|
||||||
LDA.l ScratchBufferV : CMP.b #$AF : BNE ++ : JMP .skip : ++
|
LDA.l ScratchBufferV : CMP.b #$AF : BNE ++ : JMP .skip : ++
|
||||||
%CopyDialog(Notice_SmallKeyOf)
|
%CopyDialog(Notice_SmallKeyOf)
|
||||||
LDA.b #$01 : STA.l ScratchBufferNV ; set up a flip for small keys
|
LDA.b #$01 : STA.l ScratchBufferNV ; set up a flip for small keys
|
||||||
BRA .dungeon
|
BRA .dungeon
|
||||||
|
+ : LDA.l FreeItemText : AND.b #$20 : BEQ + ; show message for crystal
|
||||||
+ LDA.b Scrap00 : AND.b #$20 : BEQ + ; show message for crystal
|
|
||||||
LDA.l ScratchBufferV : CMP.b #$B0 : !BLT + ; crystal #
|
LDA.l ScratchBufferV : CMP.b #$B0 : !BLT + ; crystal #
|
||||||
CMP.b #$B7 : !BGE +
|
CMP.b #$B7 : !BGE +
|
||||||
%CopyDialog(Notice_Crystal)
|
%CopyDialog(Notice_Crystal)
|
||||||
JMP .crystal
|
JMP .crystal
|
||||||
|
+
|
||||||
+ JMP .skip ; it's not something we are going to give a notice for
|
JMP .skip ; it's not something we are going to give a notice for
|
||||||
|
|
||||||
.dungeon
|
.dungeon
|
||||||
LDA.l DialogReturnPointer : DEC #2 : STA.l DialogOffsetPointer
|
LDA.l DialogReturnPointer : DEC #2 : STA.l DialogOffsetPointer
|
||||||
@@ -150,26 +139,23 @@ FreeDungeonItemNotice:
|
|||||||
LDA.b #$0F : !SUB.l ScratchBufferNV+1 : STA.l ScratchBufferNV+1 ; flip the values for small keys
|
LDA.b #$0F : !SUB.l ScratchBufferNV+1 : STA.l ScratchBufferNV+1 ; flip the values for small keys
|
||||||
+
|
+
|
||||||
LDA.l ScratchBufferNV+1
|
LDA.l ScratchBufferNV+1
|
||||||
ASL : TAX
|
ASL : TAX
|
||||||
REP #$20
|
REP #$20
|
||||||
|
LDA.l DungeonItemIDMap,X : CMP.w #$0003 : BCC .hc_sewers
|
||||||
LDA.l !MULTIWORLD_ITEM_PLAYER_ID : AND.w #$00FF : BNE +
|
CMP.w DungeonID : BNE +
|
||||||
|
BRA .self_notice
|
||||||
LDA.l DungeonItemIDMap, X : CMP.w #$0003 : BCC .hc_sewers
|
.hc_sewers
|
||||||
CMP.w DungeonID : BNE +
|
LDA.w DungeonID : CMP.w #$0003 : BCS +
|
||||||
BRA .self_notice
|
.self_notice
|
||||||
.hc_sewers
|
SEP #$20
|
||||||
LDA.w DungeonID : CMP.w #$0003 : BCS +
|
LDA.l FreeItemText : AND.b #$40 : BEQ ++
|
||||||
.self_notice
|
LDA.b #$00 : STA.l DialogOffsetPointer : STA.l DialogOffsetPointer+1
|
||||||
SEP #$20
|
JMP .skip
|
||||||
LDA.l FreeItemText : AND.b #$40 : BEQ ++
|
++
|
||||||
LDA.b #$00 : STA.l DialogOffsetPointer : STA.l DialogOffsetPointer+1
|
%CopyDialog(Notice_Self)
|
||||||
JMP .skip
|
JMP .done
|
||||||
++
|
+
|
||||||
%CopyDialog(Notice_Self)
|
SEP #$20
|
||||||
JMP .done
|
|
||||||
+
|
|
||||||
SEP #$20
|
|
||||||
LDA.l ScratchBufferNV+1
|
LDA.l ScratchBufferNV+1
|
||||||
CMP.b #$00 : BNE + ; ...light world
|
CMP.b #$00 : BNE + ; ...light world
|
||||||
%CopyDialog(Notice_LightWorld) : JMP .done
|
%CopyDialog(Notice_LightWorld) : JMP .done
|
||||||
@@ -204,9 +190,9 @@ FreeDungeonItemNotice:
|
|||||||
+ : CMP.b #$0F : BNE + ; ...sewers
|
+ : CMP.b #$0F : BNE + ; ...sewers
|
||||||
%CopyDialog(Notice_Sewers)
|
%CopyDialog(Notice_Sewers)
|
||||||
+
|
+
|
||||||
JMP .done
|
JMP .done
|
||||||
|
|
||||||
.crystal
|
.crystal
|
||||||
LDA.l DialogReturnPointer : DEC #2 : STA.l DialogOffsetPointer
|
LDA.l DialogReturnPointer : DEC #2 : STA.l DialogOffsetPointer
|
||||||
LDA.l ScratchBufferV
|
LDA.l ScratchBufferV
|
||||||
AND.b #$0F ; looking at low bits only
|
AND.b #$0F ; looking at low bits only
|
||||||
@@ -224,7 +210,7 @@ FreeDungeonItemNotice:
|
|||||||
%CopyDialog(Notice_Four) : JMP .done
|
%CopyDialog(Notice_Four) : JMP .done
|
||||||
+ : CMP.b #$06 : BNE +
|
+ : CMP.b #$06 : BNE +
|
||||||
%CopyDialog(Notice_Three) : JMP .done
|
%CopyDialog(Notice_Three) : JMP .done
|
||||||
+
|
+
|
||||||
|
|
||||||
.done
|
.done
|
||||||
|
|
||||||
@@ -234,14 +220,14 @@ FreeDungeonItemNotice:
|
|||||||
|
|
||||||
;--------------------------------
|
;--------------------------------
|
||||||
.skip
|
.skip
|
||||||
PLA : STA.l ScratchBufferNV+1
|
PLA : STA.l ScratchBufferNV+1
|
||||||
PLA : STA.l ScratchBufferNV
|
PLA : STA.l ScratchBufferNV
|
||||||
PLA : STA.b Scrap02
|
PLA : STA.b Scrap02
|
||||||
REP #$20
|
REP #$20
|
||||||
PLA : STA.b Scrap00
|
PLA : STA.b Scrap00
|
||||||
PLB
|
PLB
|
||||||
PLP
|
PLP
|
||||||
PLY : PLX : PLA
|
PLY : PLX : PLA
|
||||||
RTL
|
RTL
|
||||||
|
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
@@ -252,14 +238,10 @@ RTL
|
|||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
DialogItemReceive:
|
DialogItemReceive:
|
||||||
BCS .nomessage ; if doubling the item value overflowed it must be a rando item
|
BCS .nomessage ; if doubling the item value overflowed it must be a rando item
|
||||||
CPY.b #$CC : BEQ .orange_potion
|
|
||||||
CPY.b #$98 : BCC ++ ;if the item is $4C or greater it must be a rando item
|
CPY.b #$98 : BCC ++ ;if the item is $4C or greater it must be a rando item
|
||||||
.nomessage
|
.nomessage
|
||||||
LDA.w #$FFFF
|
LDA.w #$FFFF
|
||||||
BRA .done
|
|
||||||
|
|
||||||
.orange_potion
|
|
||||||
LDA.w #$0198
|
|
||||||
BRA .done
|
BRA .done
|
||||||
|
|
||||||
++ LDA.w Ancilla_ReceiveItem_item_messages, Y
|
++ LDA.w Ancilla_ReceiveItem_item_messages, Y
|
||||||
@@ -308,7 +290,7 @@ DialogGanon2:
|
|||||||
BCS +
|
BCS +
|
||||||
LDA.w #$018D : JMP .done
|
LDA.w #$018D : JMP .done
|
||||||
+
|
+
|
||||||
LDA.l GanonVulnerabilityItem : AND.w #$007F
|
LDA.l GanonVulnerabilityItem : AND.w #$00FF
|
||||||
BEQ .silver_arrows
|
BEQ .silver_arrows
|
||||||
CMP.w #$0001 : BEQ .silver_arrows
|
CMP.w #$0001 : BEQ .silver_arrows
|
||||||
CMP.w #$0004 : BEQ .bombs
|
CMP.w #$0004 : BEQ .bombs
|
||||||
|
|||||||
@@ -599,7 +599,7 @@ skip $10
|
|||||||
BigKeyStatus: ;27f040 (status 2 indicate BnC guard)
|
BigKeyStatus: ;27f040 (status 2 indicate BnC guard)
|
||||||
dw $0002, $0002, $0001, $0001, $0000, $0001, $0001, $0001, $0001, $0001, $0001, $0001, $0001, $0001, $0000, $0000
|
dw $0002, $0002, $0001, $0001, $0000, $0001, $0001, $0001, $0001, $0001, $0001, $0001, $0001, $0001, $0000, $0000
|
||||||
DungeonReminderTable: ;27f060
|
DungeonReminderTable: ;27f060
|
||||||
dw $2DA4, $2DA4, $2DA5, $2DA6, $2DA8, $2DAA, $2DA9, $2DAE, $2DAB, $2DAD, $2DA7, $2DAC, $2DAF, $2DB0, $0000, $0000
|
dw $2D50, $2D50, $2D51, $2D52, $2D54, $2D56, $2D55, $2D5A, $2D57, $2D59, $2D53, $2D58, $2D5B, $2D5C, $0000, $0000
|
||||||
TotalLocationsLow: ;27f080
|
TotalLocationsLow: ;27f080
|
||||||
db $08, $08, $06, $06, $02, $00, $04, $08, $08, $08, $06, $08, $02, $07, $00, $00
|
db $08, $08, $06, $06, $02, $00, $04, $08, $08, $08, $06, $08, $02, $07, $00, $00
|
||||||
TotalLocationsHigh: ;27f090
|
TotalLocationsHigh: ;27f090
|
||||||
@@ -696,4 +696,4 @@ dw $ffff
|
|||||||
OldManDarkWorld:
|
OldManDarkWorld:
|
||||||
dw $ffff
|
dw $ffff
|
||||||
OldManRetrievalWorld:
|
OldManRetrievalWorld:
|
||||||
dw $0000
|
dw $0000
|
||||||
@@ -1,12 +1,10 @@
|
|||||||
!BlankTile = $207F
|
!BlankTile = $207F
|
||||||
!SlashTile = $2830
|
!SlashTile = $2830
|
||||||
!PlusTile = $2404
|
|
||||||
!HyphenTile = $2405
|
!HyphenTile = $2405
|
||||||
!LTile = $2D68
|
!LTile = $2D68
|
||||||
!DTile = $2D60
|
!DTile = $2D60
|
||||||
|
!RedSquare = $345E
|
||||||
!BlueSquare = $2C5E
|
!BlueSquare = $2C5E
|
||||||
!BossIcon = $253C
|
|
||||||
!NPCIcon = $253B
|
|
||||||
|
|
||||||
DrHudOverride:
|
DrHudOverride:
|
||||||
PHB
|
PHB
|
||||||
@@ -31,13 +29,6 @@ DRHUD_DrawIndicators:
|
|||||||
LDA.b FrameCounter : AND.b #$10 : BEQ DRHUD_EnemyDropIndicator
|
LDA.b FrameCounter : AND.b #$10 : BEQ DRHUD_EnemyDropIndicator
|
||||||
|
|
||||||
DRHUD_BossIndicator:
|
DRHUD_BossIndicator:
|
||||||
LDA.w DungeonID : CMP.b #$FF : BNE .in_dungeon
|
|
||||||
LDA.w NpcItemIndicator : BEQ .early_exit
|
|
||||||
LDA.l HudItems_enabled : BEQ .early_exit
|
|
||||||
REP #$10
|
|
||||||
LDY.w #!NPCIcon : STY.w HUDMultiIndicator
|
|
||||||
JMP DRHUD_Finished
|
|
||||||
.in_dungeon
|
|
||||||
LDA.l DRMode : BNE .continue
|
LDA.l DRMode : BNE .continue
|
||||||
.early_exit
|
.early_exit
|
||||||
REP #$10
|
REP #$10
|
||||||
@@ -55,7 +46,7 @@ DRHUD_BossIndicator:
|
|||||||
SEP #$20
|
SEP #$20
|
||||||
BEQ .draw_indicator
|
BEQ .draw_indicator
|
||||||
LDA.l CompassBossIndicator, x : CMP.b RoomIndex : BNE .draw_indicator
|
LDA.l CompassBossIndicator, x : CMP.b RoomIndex : BNE .draw_indicator
|
||||||
LDY.w #!BossIcon
|
LDY.w #!RedSquare
|
||||||
.draw_indicator
|
.draw_indicator
|
||||||
STY.w HUDMultiIndicator
|
STY.w HUDMultiIndicator
|
||||||
BRA DRHUD_DrawCurrentDungeonIndicator
|
BRA DRHUD_DrawCurrentDungeonIndicator
|
||||||
@@ -80,12 +71,13 @@ DRHUD_DrawCurrentDungeonIndicator: ; mX
|
|||||||
CMP.b #$06 : BEQ .draw_indicator
|
CMP.b #$06 : BEQ .draw_indicator
|
||||||
|
|
||||||
.get_indicator
|
.get_indicator
|
||||||
LDY.w #$2C28
|
REP #$20 : LDA.l DungeonReminderTable,X : TAY
|
||||||
|
SEP #$20
|
||||||
.draw_indicator
|
.draw_indicator
|
||||||
STY.w HUDCurrentDungeonWorld
|
STY.w HUDCurrentDungeonWorld
|
||||||
|
|
||||||
DRHUD_DrawKeyCounter:
|
DRHUD_DrawKeyCounter:
|
||||||
LDA.l DRFlags : AND.b #$04 : BEQ .to_finished
|
LDA.l DRFlags : AND.b #$04 : BEQ DRHUD_Finished
|
||||||
LDA.l CompassMode : BIT.b #$03 : BEQ DRHUD_Finished
|
LDA.l CompassMode : BIT.b #$03 : BEQ DRHUD_Finished
|
||||||
REP #$20
|
REP #$20
|
||||||
BIT.w #$0002 : BNE .skip_map_check
|
BIT.w #$0002 : BNE .skip_map_check
|
||||||
@@ -98,17 +90,8 @@ DRHUD_DrawKeyCounter:
|
|||||||
LDA.l GenericKeys : LSR : BCS .total_only
|
LDA.l GenericKeys : LSR : BCS .total_only
|
||||||
LDA.w DungeonCollectedKeys, X : JSR ConvertToDisplay : STA.w HUDKeysObtained
|
LDA.w DungeonCollectedKeys, X : JSR ConvertToDisplay : STA.w HUDKeysObtained
|
||||||
LDA.w #!SlashTile : STA.w HUDKeysSlash
|
LDA.w #!SlashTile : STA.w HUDKeysSlash
|
||||||
|
|
||||||
LDA.l ExtraChestKeys, X : AND.w #$00FF : BEQ .total_only
|
|
||||||
JSR ConvertToDisplay : STA.w HUDKeysExtraCount
|
|
||||||
LDA.w #!PlusTile : STA.w HUDKeysExtraPlus
|
|
||||||
|
|
||||||
.total_only
|
.total_only
|
||||||
SEP #$20
|
LDA.l ChestKeys, x : JSR ConvertToDisplay : STA.w HUDKeysTotal
|
||||||
LDA.l ChestKeys, X : SEC : SBC.l ExtraChestKeys, X
|
|
||||||
REP #$20
|
|
||||||
JSR ConvertToDisplay : STA.w HUDKeysTotal
|
|
||||||
.to_finished
|
|
||||||
JMP DRHUD_Finished
|
JMP DRHUD_Finished
|
||||||
|
|
||||||
OWRHUD_DrawWorldIndicator:
|
OWRHUD_DrawWorldIndicator:
|
||||||
@@ -309,29 +292,17 @@ BossStatus:
|
|||||||
; default palette 3 - white
|
; default palette 3 - white
|
||||||
LDA.l DungeonReminderTable, X : RTS
|
LDA.l DungeonReminderTable, X : RTS
|
||||||
|
|
||||||
ConvertToDisplay: ; transparent background
|
ConvertToDisplay:
|
||||||
AND.w #$00FF
|
and.w #$00ff : cmp.w #$000a : !BLT +
|
||||||
CMP.w #$000A : BCC .under10
|
!ADD.w #$2519 : rts
|
||||||
CMP.w #$000C : BCC .under12
|
+ !ADD.w #$2490 : rts
|
||||||
.over11
|
|
||||||
CLC : ADC.w #$2553 : RTS
|
|
||||||
.under12
|
|
||||||
CLC : ADC.w #$2519 : RTS
|
|
||||||
.under10
|
|
||||||
CLC : ADC.w #$2490 : RTS
|
|
||||||
|
|
||||||
ConvertToDisplay2: ; solid background
|
ConvertToDisplay2:
|
||||||
AND.w #$00FF : BEQ .zero
|
and.w #$00ff : beq ++
|
||||||
CMP.w #$000A : BCC .under10
|
cmp.w #$000a : !BLT +
|
||||||
CMP.w #$000C : BCC .under12
|
!ADD.w #$2517 : rts ; 2580 with 258A as "A" for non transparent digits
|
||||||
.over11
|
+ !ADD.w #$2816 : rts
|
||||||
CLC : ADC.w #$2580 : RTS
|
++ lda.w #$2827 : rts ; 0/O for 0 or placeholder digit ;2483
|
||||||
.under12
|
|
||||||
CLC : ADC.w #$2517 : RTS
|
|
||||||
.under10
|
|
||||||
CLC : ADC.w #$2816 : RTS
|
|
||||||
.zero
|
|
||||||
LDA.w #$2827 : RTS
|
|
||||||
|
|
||||||
CountAbsorbedKeys:
|
CountAbsorbedKeys:
|
||||||
JML IncrementSmallKeysNoPrimary
|
JML IncrementSmallKeysNoPrimary
|
||||||
|
|||||||
@@ -21,18 +21,14 @@ SpiralWarp: {
|
|||||||
lda.w $045e : cmp.b #$5e : beq .gtg ; abort if not spiral - intended room is in A!
|
lda.w $045e : cmp.b #$5e : beq .gtg ; abort if not spiral - intended room is in A!
|
||||||
cmp.b #$5f : beq .gtg
|
cmp.b #$5f : beq .gtg
|
||||||
cmp.b #$26 : beq .inroom
|
cmp.b #$26 : beq .inroom
|
||||||
.abort
|
.abort
|
||||||
SEP #$30
|
SEP #$30 : stz.w $045e : lda.b PreviousRoom : and.b #$0f : rtl ; clear,run hijacked code and get out
|
||||||
stz.w $045e
|
.inroom
|
||||||
lda.b PreviousRoom : and.b #$0f
|
|
||||||
rtl ; clear,run hijacked code and get out
|
|
||||||
|
|
||||||
.inroom
|
|
||||||
jsr InroomStairsWarp
|
jsr InroomStairsWarp
|
||||||
lda.b PreviousRoom : and.b #$0f ; this is the code we are hijacking
|
lda.b PreviousRoom : and.b #$0f ; this is the code we are hijacking
|
||||||
rtl
|
rtl
|
||||||
|
|
||||||
.gtg
|
.gtg
|
||||||
phb : phk : plb : phx : phy ; push stuff
|
phb : phk : plb : phx : phy ; push stuff
|
||||||
jsr LookupSpiralOffset
|
jsr LookupSpiralOffset
|
||||||
rep #$30 : and.w #$00FF : asl #2 : tax
|
rep #$30 : and.w #$00FF : asl #2 : tax
|
||||||
@@ -85,7 +81,6 @@ SpiralWarp: {
|
|||||||
ldy.b #$01 : jsr SetCamera
|
ldy.b #$01 : jsr SetCamera
|
||||||
|
|
||||||
jsr StairCleanup
|
jsr StairCleanup
|
||||||
|
|
||||||
ply : plx : plb ; pull the stuff we pushed
|
ply : plx : plb ; pull the stuff we pushed
|
||||||
lda.b PreviousRoom : and.b #$0f ; this is the code we are hijacking
|
lda.b PreviousRoom : and.b #$0f ; this is the code we are hijacking
|
||||||
rtl
|
rtl
|
||||||
@@ -266,7 +261,6 @@ InroomStairsWarp: {
|
|||||||
.skipCamera
|
.skipCamera
|
||||||
|
|
||||||
jsr StairCleanup
|
jsr StairCleanup
|
||||||
|
|
||||||
ply : plx : plb ; pull the stuff we pushed
|
ply : plx : plb ; pull the stuff we pushed
|
||||||
rts
|
rts
|
||||||
}
|
}
|
||||||
@@ -341,4 +335,4 @@ SpiralPriorityHack: {
|
|||||||
lda.b #$01 : rtl ; always skip the priority code - until I figure out how to fix it
|
lda.b #$01 : rtl ; always skip the priority code - until I figure out how to fix it
|
||||||
+ lda.w $0462 : and.b #$04 ; what we wrote over
|
+ lda.w $0462 : and.b #$04 ; what we wrote over
|
||||||
rtl
|
rtl
|
||||||
}
|
}
|
||||||
@@ -88,6 +88,7 @@ RTL
|
|||||||
|
|
||||||
PrizeReceiveItem:
|
PrizeReceiveItem:
|
||||||
PHA
|
PHA
|
||||||
|
LDA.b #$00 : STA.l BossDropTouched
|
||||||
JSL BossPrizeGetPlayer : STA.l !MULTIWORLD_ITEM_PLAYER_ID
|
JSL BossPrizeGetPlayer : STA.l !MULTIWORLD_ITEM_PLAYER_ID
|
||||||
PLA
|
PLA
|
||||||
CMP.b #$6A : BNE +
|
CMP.b #$6A : BNE +
|
||||||
@@ -105,7 +106,7 @@ RTL
|
|||||||
SetItemPose:
|
SetItemPose:
|
||||||
PHA
|
PHA
|
||||||
LDA.w DungeonID : BMI .one_handed
|
LDA.w DungeonID : BMI .one_handed
|
||||||
LDA.w RoomItemsTaken : BIT.b #$80 : BNE +
|
JSL CheckBossDropTouched : BNE +
|
||||||
.one_handed
|
.one_handed
|
||||||
PLA
|
PLA
|
||||||
JML Link_ReceiveItem_not_cool_pose
|
JML Link_ReceiveItem_not_cool_pose
|
||||||
@@ -134,7 +135,7 @@ SetCutsceneFlag:
|
|||||||
PHX
|
PHX
|
||||||
LDY.b #$01 ; wrote over
|
LDY.b #$01 ; wrote over
|
||||||
LDA.w DungeonID : BMI .no_cutscene
|
LDA.w DungeonID : BMI .no_cutscene
|
||||||
LDA.w RoomItemsTaken : BIT.b #$80 : BNE .dungeon_prize
|
JSL CheckBossDropTouched : BNE .dungeon_prize
|
||||||
.no_cutscene
|
.no_cutscene
|
||||||
SEP #$30
|
SEP #$30
|
||||||
PLX
|
PLX
|
||||||
@@ -155,7 +156,7 @@ AnimatePrizeCutscene:
|
|||||||
LDA.w ItemReceiptMethod : CMP.b #$03 : BNE +
|
LDA.w ItemReceiptMethod : CMP.b #$03 : BNE +
|
||||||
JSR CrystalOrPendantBehavior : BCC +
|
JSR CrystalOrPendantBehavior : BCC +
|
||||||
LDA.w DungeonID : BMI +
|
LDA.w DungeonID : BMI +
|
||||||
LDA.w RoomItemsTaken : BIT.b #$80 : BEQ +
|
JSL CheckBossDropTouched : BEQ +
|
||||||
SEC
|
SEC
|
||||||
RTL
|
RTL
|
||||||
+
|
+
|
||||||
@@ -172,13 +173,13 @@ PrizeDropSparkle:
|
|||||||
RTL
|
RTL
|
||||||
|
|
||||||
HandleDropSFX:
|
HandleDropSFX:
|
||||||
LDA.w RoomItemsTaken : BIT.b #$80 : BEQ .no_sound
|
JSL CheckBossDropTouched : BEQ .no_sound
|
||||||
JSR CrystalOrPendantBehavior : BCC .no_sound
|
JSR CrystalOrPendantBehavior : BCC .no_sound
|
||||||
SEC
|
SEC
|
||||||
RTL
|
RTL
|
||||||
.no_sound
|
.no_sound
|
||||||
CLC
|
CLC
|
||||||
RTL
|
RTL
|
||||||
|
|
||||||
HandleCrystalsField:
|
HandleCrystalsField:
|
||||||
TAX
|
TAX
|
||||||
@@ -192,7 +193,7 @@ RTL
|
|||||||
MaybeKeepLootID:
|
MaybeKeepLootID:
|
||||||
PHA
|
PHA
|
||||||
LDA.w DungeonID : BMI .no_prize
|
LDA.w DungeonID : BMI .no_prize
|
||||||
LDA.w RoomItemsTaken : BIT.b #$80 : BNE .prize
|
JSL CheckBossDropTouched : BNE .prize
|
||||||
.no_prize
|
.no_prize
|
||||||
STZ.w ItemReceiptID
|
STZ.w ItemReceiptID
|
||||||
STZ.w ItemReceiptPose
|
STZ.w ItemReceiptPose
|
||||||
@@ -216,6 +217,15 @@ CheckSpawnPrize:
|
|||||||
SEP #$21
|
SEP #$21
|
||||||
RTL
|
RTL
|
||||||
|
|
||||||
|
CheckBossDropTouched:
|
||||||
|
; Out: z - boss drop not touched
|
||||||
|
LDA.w RoomItemsTaken
|
||||||
|
AND.b #$80
|
||||||
|
BNE .done
|
||||||
|
LDA.l BossDropTouched
|
||||||
|
.done
|
||||||
|
RTL
|
||||||
|
|
||||||
CheckDungeonCompletion:
|
CheckDungeonCompletion:
|
||||||
LDX.w DungeonID
|
LDX.w DungeonID
|
||||||
REP #$20
|
REP #$20
|
||||||
|
|||||||
110
events.asm
110
events.asm
@@ -1,14 +1,14 @@
|
|||||||
OnPrepFileSelect:
|
OnPrepFileSelect:
|
||||||
LDA.b GameSubMode : CMP.b #$03 : BNE +
|
LDA.b GameSubMode : CMP.b #$03 : BNE +
|
||||||
LDA.b #$06 : STA.b NMISTRIPES ; thing we wrote over
|
LDA.b #$06 : STA.b NMISTRIPES ; thing we wrote over
|
||||||
RTL
|
RTL
|
||||||
+
|
+
|
||||||
PHA : PHX
|
PHA : PHX
|
||||||
REP #$10
|
REP #$10
|
||||||
JSL LoadAlphabetTilemap
|
JSL LoadAlphabetTilemap
|
||||||
JSL LoadFullItemTiles
|
JSL LoadFullItemTiles
|
||||||
SEP #$10
|
SEP #$10
|
||||||
PLX : PLA
|
PLX : PLA
|
||||||
RTL
|
RTL
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
OnDrawHud:
|
OnDrawHud:
|
||||||
@@ -22,81 +22,87 @@ JML ReturnFromOnDrawHud
|
|||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
OnDungeonEntrance:
|
OnDungeonEntrance:
|
||||||
STA.l PegColor ; thing we wrote over
|
STA.l PegColor ; thing we wrote over
|
||||||
JSL MaybeFlagDungeonTotalsEntrance
|
JSL MaybeFlagDungeonTotalsEntrance
|
||||||
LDA.w #$0001 : STA.l UpdateHUDFlag
|
LDA.w #$0001 : STA.l UpdateHUDFlag
|
||||||
SEP #$30
|
SEP #$30
|
||||||
JSL DynamicDropGFXClear
|
JSL DynamicDropGFXClear
|
||||||
REP #$30
|
REP #$30
|
||||||
RTL
|
RTL
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
OnDungeonBossExit:
|
OnDungeonBossExit:
|
||||||
JSL StatTransitionCounter
|
JSL StatTransitionCounter
|
||||||
JSL ClearMultiworldText
|
JSL ClearMultiworldText
|
||||||
JSL DynamicDropGFXClear
|
JSL DynamicDropGFXClear
|
||||||
RTL
|
RTL
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
OnPlayerDead:
|
OnPlayerDead:
|
||||||
PHA
|
PHA
|
||||||
JSL SetDeathWorldChecked
|
JSL SetDeathWorldChecked
|
||||||
JSL DynamicDropGFXClear
|
JSL DynamicDropGFXClear
|
||||||
JSL SetSilverBowMode
|
JSL SetSilverBowMode
|
||||||
JSL RefreshRainAmmo
|
JSL RefreshRainAmmo
|
||||||
LDA.b #$00
|
|
||||||
STA.l InfiniteMagic
|
|
||||||
PLA
|
PLA
|
||||||
RTL
|
RTL
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
OnDungeonExit:
|
OnDungeonExit:
|
||||||
PHA : PHP
|
PHA : PHP
|
||||||
SEP #$20 ; set 8-bit accumulator
|
SEP #$20 ; set 8-bit accumulator
|
||||||
JSL SQEGFix
|
JSL SQEGFix
|
||||||
JSL DynamicDropGFXClear
|
JSL DynamicDropGFXClear
|
||||||
PLP : PLA
|
PLP : PLA
|
||||||
|
|
||||||
STA.w DungeonID : STZ.w Map16ChangeIndex ; thing we wrote over
|
STA.w DungeonID : STZ.w Map16ChangeIndex ; thing we wrote over
|
||||||
|
|
||||||
PHA : PHP
|
PHA : PHP
|
||||||
LDA.w #$0001 : STA.l UpdateHUDFlag
|
LDA.w #$0001 : STA.l UpdateHUDFlag
|
||||||
JSL HUD_RebuildLong
|
JSL HUD_RebuildLong
|
||||||
JSL FloodGateResetInner
|
JSL FloodGateResetInner
|
||||||
JSL SetSilverBowMode
|
JSL SetSilverBowMode
|
||||||
PLP : PLA
|
PLP : PLA
|
||||||
RTL
|
RTL
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
OnSave:
|
OnSave:
|
||||||
LDA.b #$70 : PHA : PLB ; thing we wrote over - data bank change
|
LDA.b #$70 : PHA : PLB ; thing we wrote over - data bank change
|
||||||
JSL DarkWorldSaveFix
|
JSL DarkWorldSaveFix
|
||||||
JML MSUResumeReset
|
JML MSUResumeReset
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
OnQuit:
|
OnQuit:
|
||||||
JSL SQEGFix
|
JSL SQEGFix
|
||||||
LDA.b #$00 : STA.l AltTextFlag ; bandaid patch bug with mirroring away from text
|
LDA.b #$00 : STA.l AltTextFlag ; bandaid patch bug with mirroring away from text
|
||||||
LDA.b #$10 : STA.b MAINDESQ ; thing we wrote over
|
LDA.b #$10 : STA.b MAINDESQ ; thing we wrote over
|
||||||
LDA.b #$00
|
|
||||||
STA.l InfiniteMagic
|
|
||||||
RTL
|
RTL
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
OnDeathNoSave:
|
OnDeathNoSave:
|
||||||
JSL MSUResumeReset
|
JSL MSUResumeReset
|
||||||
LDA.b #$05 : STA.b $10 ; what we wrote over
|
LDA.b #$05 : STA.b $10 ; what we wrote over
|
||||||
RTL
|
RTL
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
OnUncleItemGet:
|
OnUncleItemGet:
|
||||||
PHA
|
PHA
|
||||||
|
|
||||||
|
LDA.l EscapeAssist
|
||||||
|
BIT.b #$04 : BEQ + : STA.l InfiniteMagic : +
|
||||||
|
BIT.b #$02 : BEQ + : STA.l InfiniteBombs : +
|
||||||
|
BIT.b #$01 : BEQ + : STA.l InfiniteArrows : +
|
||||||
|
|
||||||
LDA.l UncleItem_Player : STA.l !MULTIWORLD_ITEM_PLAYER_ID
|
LDA.l UncleItem_Player : STA.l !MULTIWORLD_ITEM_PLAYER_ID
|
||||||
PLA
|
PLA
|
||||||
JSL Link_ReceiveItem
|
JSL Link_ReceiveItem
|
||||||
|
|
||||||
LDA.l ProgressIndicator : BNE +
|
LDA.l UncleRefill : BIT.b #$04 : BEQ + : LDA.b #$80 : STA.l MagicFiller : + ; refill magic
|
||||||
LDA.b #$01 : STA.l ProgressIndicator ; set rain state
|
LDA.l UncleRefill : BIT.b #$02 : BEQ + : LDA.b #50 : STA.l BombsFiller : + ; refill bombs
|
||||||
JSL SetEscapeAssist
|
LDA.l UncleRefill : BIT.b #$01 : BEQ + ; refill arrows
|
||||||
JSL RefreshRainAmmo
|
LDA.b #70 : STA.l ArrowsFiller
|
||||||
|
|
||||||
; grant arrows if we started with a bow in retro mode
|
|
||||||
LDA.l ArrowMode : BEQ +
|
LDA.l ArrowMode : BEQ +
|
||||||
LDA.l RainDeathRefillRupeeBow : ORA.l RainDeathRefillRupeeBow+1 : BEQ +
|
LDA.l BowTracking : ORA.b #$80 : STA.l BowTracking ; enable bow toggle
|
||||||
LDA.b #$01 : STA.l ArrowsFiller
|
REP #$20 ; set 16-bit accumulator
|
||||||
|
LDA.l CurrentRupees : !ADD.l FreeUncleItemAmount : STA.l CurrentRupees ; rupee arrows, so also give the player some money to start
|
||||||
|
SEP #$20 ; set 8-bit accumulator
|
||||||
+
|
+
|
||||||
|
LDA.l ProgressIndicator : BNE +
|
||||||
|
LDA.b #$01 : STA.l ProgressIndicator ; handle rain state
|
||||||
|
+
|
||||||
RTL
|
RTL
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
OnAga1Defeated:
|
OnAga1Defeated:
|
||||||
@@ -195,12 +201,12 @@ OnNewFile:
|
|||||||
STZ.w TreePullKills
|
STZ.w TreePullKills
|
||||||
STZ.w TreePullHits
|
STZ.w TreePullHits
|
||||||
STZ.w PrizePackIndexes
|
STZ.w PrizePackIndexes
|
||||||
STZ.w PrizePackIndexes+1
|
STZ.w PrizePackIndexes+1
|
||||||
STZ.w PrizePackIndexes+2
|
STZ.w PrizePackIndexes+2
|
||||||
STZ.w PrizePackIndexes+3
|
STZ.w PrizePackIndexes+3
|
||||||
STZ.w PrizePackIndexes+4
|
STZ.w PrizePackIndexes+4
|
||||||
STZ.w PrizePackIndexes+5
|
STZ.w PrizePackIndexes+5
|
||||||
STZ.w PrizePackIndexes+6
|
STZ.w PrizePackIndexes+6
|
||||||
LDA.b #$00 : STA.l MosaicLevel
|
LDA.b #$00 : STA.l MosaicLevel
|
||||||
JSL InitRNGPointerTable
|
JSL InitRNGPointerTable
|
||||||
PLP : PLX
|
PLP : PLX
|
||||||
|
|||||||
@@ -82,10 +82,7 @@ DrawBottle:
|
|||||||
AND.w #$00FF : BNE +
|
AND.w #$00FF : BNE +
|
||||||
LDX.w #FileSelectItems_empty_bottle
|
LDX.w #FileSelectItems_empty_bottle
|
||||||
JMP DrawItemGray
|
JMP DrawItemGray
|
||||||
+ : DEC : BNE +
|
+ : DEC #2 : BNE +
|
||||||
LDX.w #FileSelectItems_orange_potion
|
|
||||||
JMP DrawItem
|
|
||||||
+ : DEC : BNE +
|
|
||||||
LDX.w #FileSelectItems_empty_bottle
|
LDX.w #FileSelectItems_empty_bottle
|
||||||
JMP DrawItem
|
JMP DrawItem
|
||||||
+ : DEC : BNE +
|
+ : DEC : BNE +
|
||||||
@@ -622,8 +619,6 @@ FileSelectItems:
|
|||||||
dw #$0282|!FS_COLOR_GREEN, #$0282|!FS_COLOR_GREEN|!FS_HFLIP, #$0292|!FS_COLOR_GREEN, #$0284|!FS_COLOR_GREEN
|
dw #$0282|!FS_COLOR_GREEN, #$0282|!FS_COLOR_GREEN|!FS_HFLIP, #$0292|!FS_COLOR_GREEN, #$0284|!FS_COLOR_GREEN
|
||||||
.blue_potion
|
.blue_potion
|
||||||
dw #$0282|!FS_COLOR_BLUE, #$0282|!FS_COLOR_BLUE|!FS_HFLIP, #$0292|!FS_COLOR_BLUE, #$0285|!FS_COLOR_BLUE
|
dw #$0282|!FS_COLOR_BLUE, #$0282|!FS_COLOR_BLUE|!FS_HFLIP, #$0292|!FS_COLOR_BLUE, #$0285|!FS_COLOR_BLUE
|
||||||
.orange_potion
|
|
||||||
dw #$0282|!FS_COLOR_BROWN, #$0282|!FS_COLOR_BROWN|!FS_HFLIP, #$0292|!FS_COLOR_BROWN, #$0286|!FS_COLOR_BROWN
|
|
||||||
.fairy_bottle
|
.fairy_bottle
|
||||||
dw #$0287|!FS_COLOR_YELLOW|!FS_HFLIP, #$0287|!FS_COLOR_YELLOW, #$0296|!FS_COLOR_BLUE, #$0297|!FS_COLOR_BLUE
|
dw #$0287|!FS_COLOR_YELLOW|!FS_HFLIP, #$0287|!FS_COLOR_YELLOW, #$0296|!FS_COLOR_BLUE, #$0297|!FS_COLOR_BLUE
|
||||||
.bee_bottle
|
.bee_bottle
|
||||||
|
|||||||
@@ -857,7 +857,6 @@ RTL
|
|||||||
Kiki_DontScareTheMonke:
|
Kiki_DontScareTheMonke:
|
||||||
LDA.b LinkJumping : BEQ .return
|
LDA.b LinkJumping : BEQ .return
|
||||||
CMP.b #$02 : BEQ .no_spook ; needed for quake usage
|
CMP.b #$02 : BEQ .no_spook ; needed for quake usage
|
||||||
LDA.b GameMode : CMP.b #$0F : BEQ .no_spook ; needed for entrance transitions
|
|
||||||
LDA.w NoDamage : BNE .no_spook
|
LDA.w NoDamage : BNE .no_spook
|
||||||
LDA.w LinkThud : BNE .no_spook
|
LDA.w LinkThud : BNE .no_spook
|
||||||
.spook
|
.spook
|
||||||
|
|||||||
@@ -2,28 +2,21 @@
|
|||||||
; Frame Hook
|
; Frame Hook
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
FrameHookAction:
|
FrameHookAction:
|
||||||
JSL Module_MainRouting
|
JSL Module_MainRouting
|
||||||
JSL CheckMusicLoadRequest
|
JSL CheckMusicLoadRequest
|
||||||
PHP : REP #$30 : PHA
|
PHP : REP #$30 : PHA
|
||||||
SEP #$20
|
SEP #$20
|
||||||
LDA.l StatsLocked : BNE ++
|
LDA.l StatsLocked : BNE ++
|
||||||
REP #$20 ; set 16-bit accumulator
|
REP #$20 ; set 16-bit accumulator
|
||||||
LDA.l LoopFrames : INC : STA.l LoopFrames : BNE +
|
LDA.l LoopFrames : INC : STA.l LoopFrames : BNE +
|
||||||
LDA.l LoopFrames+2 : INC : STA.l LoopFrames+2
|
LDA.l LoopFrames+2 : INC : STA.l LoopFrames+2
|
||||||
+
|
+
|
||||||
; move this to nmi hook?
|
LDA.l GameMode : CMP.w #$010E : BNE ++ ; move this to nmi hook?
|
||||||
LDA.l GameMode : CMP.w #$010E : BNE +
|
LDA.l MenuFrames : INC : STA.l MenuFrames : BNE ++
|
||||||
; item select menu
|
LDA.l MenuFrames+2 : INC : STA.l MenuFrames+2
|
||||||
LDA.l MenuFrames : INC : STA.l MenuFrames : BNE ++
|
++
|
||||||
LDA.l MenuFrames+2 : INC : STA.l MenuFrames+2
|
REP #$30 : PLA : PLP
|
||||||
+
|
|
||||||
LDA.l GameMode : CMP.w #$030E : BEQ .map ; underworld map
|
|
||||||
LDA.l GameMode : CMP.w #$070E : BNE ++ ; overworld map
|
|
||||||
.map
|
|
||||||
LDA.l MapFrames : INC : STA.l MapFrames : BNE ++
|
|
||||||
LDA.l MapFrames+2 : INC : STA.l MapFrames+2
|
|
||||||
++
|
|
||||||
REP #$30 : PLA : PLP
|
|
||||||
RTL
|
RTL
|
||||||
|
|
||||||
!NMI_MW = "$7F5047"
|
!NMI_MW = "$7F5047"
|
||||||
@@ -54,37 +47,37 @@ JML NMIHookReturn
|
|||||||
|
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
PostNMIHookAction:
|
PostNMIHookAction:
|
||||||
LDA.w NMIAux : BEQ +
|
LDA.w NMIAux : BEQ +
|
||||||
PHK : PEA.w .return-1 ; push stack for RTL return
|
PHK : PEA.w .return-1 ; push stack for RTL return
|
||||||
JMP.w [NMIAux]
|
JMP.w [NMIAux]
|
||||||
.return
|
.return
|
||||||
STZ.w NMIAux ; zero bank byte of NMI hook pointer
|
STZ.w NMIAux ; zero bank byte of NMI hook pointer
|
||||||
+
|
+
|
||||||
JSR TransferItemGFX
|
JSR TransferItemGFX
|
||||||
LDA.b INIDISPQ : STA.w INIDISP ; thing we wrote over, turn screen back on
|
LDA.b INIDISPQ : STA.w INIDISP ; thing we wrote over, turn screen back on
|
||||||
|
|
||||||
JML PostNMIHookReturn
|
JML PostNMIHookReturn
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
TransferItemGFX:
|
TransferItemGFX:
|
||||||
; Only used for shops now but could be used for anything. We should look at how door rando does this
|
; Only used for shops now but could be used for anything. We should look at how door rando does this
|
||||||
; and try to unify one approach.
|
; and try to unify one approach.
|
||||||
REP #$30
|
REP #$30
|
||||||
LDX.w ItemStackPtr : BEQ .done
|
LDX.w ItemStackPtr : BEQ .done
|
||||||
TXA : BIT.w #$0040 : BNE .fail ; Crash if we have more than 16 queued (should never happen.)
|
TXA : BIT.w #$0040 : BNE .fail ; Crash if we have more than 16 queued (should never happen.)
|
||||||
DEX #2
|
DEX #2
|
||||||
-
|
-
|
||||||
LDA.l ItemGFXStack,X : STA.w ItemGFXPtr
|
LDA.l ItemGFXStack,X : STA.w ItemGFXPtr
|
||||||
LDA.l ItemTargetStack,X : STA.w ItemGFXTarget
|
LDA.l ItemTargetStack,X : STA.w ItemGFXTarget
|
||||||
PHX
|
PHX
|
||||||
JSL TransferItemToVRAM
|
JSL TransferItemToVRAM
|
||||||
REP #$10
|
REP #$10
|
||||||
PLX
|
PLX
|
||||||
DEX #2
|
DEX #2
|
||||||
BPL -
|
BPL -
|
||||||
|
|
||||||
STZ.w ItemStackPtr
|
STZ.w ItemStackPtr
|
||||||
.done
|
.done
|
||||||
SEP #$30
|
SEP #$30
|
||||||
RTS
|
RTS
|
||||||
.fail
|
.fail
|
||||||
BRK #$00
|
BRK #$00
|
||||||
|
|||||||
@@ -1,43 +1,42 @@
|
|||||||
; A = room_id
|
; A = room_id
|
||||||
; out A = level of loot
|
; out A = level of loot
|
||||||
CheckMapLoot:
|
CheckLoot:
|
||||||
PHP
|
PHP
|
||||||
REP #$30
|
REP #$30
|
||||||
PHX
|
PHB : PHX : PHY
|
||||||
|
|
||||||
STA.b $CA
|
STA.b $CA
|
||||||
|
|
||||||
|
LDA.b $06 : PHA
|
||||||
LDA.b $0E : PHA
|
LDA.b $0E : PHA
|
||||||
|
|
||||||
LDA.l MapItems_default
|
STZ.b $02 ; best item class found
|
||||||
|
|
||||||
|
LDA.l ShowItems_default
|
||||||
AND.w #$00FF
|
AND.w #$00FF
|
||||||
STA.b $0E
|
STA.b $0E
|
||||||
|
|
||||||
LDA.b $CA
|
LDA.b $CA
|
||||||
AND.w #$01FF
|
AND.w #$00FF
|
||||||
ASL A
|
ASL A
|
||||||
TAX
|
TAX
|
||||||
|
|
||||||
LDA.l SaveDataWRAM, X
|
LDA.l SaveDataWRAM, X
|
||||||
AND.w #$000F
|
AND.w #$000F
|
||||||
BEQ +
|
BEQ +
|
||||||
LDA.l MapItems_visited_tile
|
LDA.l ShowItems_visited_tile
|
||||||
AND.w #$00FF
|
AND.w #$00FF
|
||||||
CMP.b $0E
|
CMP.b $0E
|
||||||
BCC +
|
BCC +
|
||||||
STA.b $0E
|
STA.b $0E
|
||||||
|
|
||||||
+ LDA.w DungeonID
|
+ LDA.w DungeonID
|
||||||
AND.w #$00FF
|
|
||||||
CMP.w #$00FF
|
|
||||||
BEQ .skip_dungeon_checks
|
|
||||||
|
|
||||||
TAX
|
TAX
|
||||||
|
|
||||||
LDA.l MapField
|
LDA.l MapField
|
||||||
AND.l DungeonMask, X
|
AND.l DungeonMask, X
|
||||||
BEQ +
|
BEQ +
|
||||||
LDA.l MapItems_have_map
|
LDA.l ShowItems_have_map
|
||||||
AND.w #$00FF
|
AND.w #$00FF
|
||||||
CMP.b $0E
|
CMP.b $0E
|
||||||
BCC +
|
BCC +
|
||||||
@@ -46,93 +45,13 @@ CheckMapLoot:
|
|||||||
+ LDA.l CompassField
|
+ LDA.l CompassField
|
||||||
AND.l DungeonMask, X
|
AND.l DungeonMask, X
|
||||||
BEQ +
|
BEQ +
|
||||||
LDA.l MapItems_have_compass
|
LDA.l ShowItems_have_compass
|
||||||
AND.w #$00FF
|
AND.w #$00FF
|
||||||
CMP.b $0E
|
CMP.b $0E
|
||||||
BCC +
|
BCC +
|
||||||
STA.b $0E
|
STA.b $0E
|
||||||
+
|
+
|
||||||
|
|
||||||
.skip_dungeon_checks
|
|
||||||
JMP GetLootLevelAndCleanUp
|
|
||||||
|
|
||||||
; A = room_id
|
|
||||||
; out A = level of loot
|
|
||||||
CheckHudLoot:
|
|
||||||
PHP
|
|
||||||
REP #$30
|
|
||||||
PHX
|
|
||||||
|
|
||||||
STA.b $CA
|
|
||||||
|
|
||||||
LDA.b $0E : PHA
|
|
||||||
|
|
||||||
+ LDA.w DungeonID
|
|
||||||
AND.w #$00FF
|
|
||||||
CMP.w #$00FF
|
|
||||||
BEQ .cave
|
|
||||||
|
|
||||||
TAX
|
|
||||||
|
|
||||||
LDA.l HudItems_default_dungeon
|
|
||||||
AND.w #$00FF
|
|
||||||
STA.b $0E
|
|
||||||
|
|
||||||
LDA.l MapField
|
|
||||||
AND.l DungeonMask, X
|
|
||||||
BEQ +
|
|
||||||
LDA.l HudItems_have_map
|
|
||||||
AND.w #$00FF
|
|
||||||
CMP.b $0E
|
|
||||||
BCC +
|
|
||||||
STA.b $0E
|
|
||||||
|
|
||||||
+ LDA.l CompassField
|
|
||||||
AND.l DungeonMask, X
|
|
||||||
BEQ +
|
|
||||||
LDA.l HudItems_have_compass
|
|
||||||
AND.w #$00FF
|
|
||||||
CMP.b $0E
|
|
||||||
BCC +
|
|
||||||
STA.b $0E
|
|
||||||
+
|
|
||||||
|
|
||||||
BRA GetLootLevelAndCleanUp
|
|
||||||
|
|
||||||
.cave
|
|
||||||
LDA.l HudItems_cave
|
|
||||||
AND.w #$00FF
|
|
||||||
STA.b $0E
|
|
||||||
; intentional fall-through
|
|
||||||
|
|
||||||
GetLootLevelAndCleanUp:
|
|
||||||
STZ.b $02
|
|
||||||
|
|
||||||
LDA.b $0E
|
|
||||||
AND.w #$00FF
|
|
||||||
BEQ +
|
|
||||||
JSL GetLootLevel
|
|
||||||
+
|
|
||||||
|
|
||||||
PLA : STA.b $0E
|
|
||||||
PLX
|
|
||||||
PLP
|
|
||||||
|
|
||||||
LDA.b $02
|
|
||||||
RTL
|
|
||||||
|
|
||||||
; $CA = room_id
|
|
||||||
; $0E = level of details to return
|
|
||||||
; (1 - presence, 2 - compass or presence, 3 - value)
|
|
||||||
; out $02 = level of loot
|
|
||||||
GetLootLevel:
|
|
||||||
PHP
|
|
||||||
REP #$30
|
|
||||||
PHB : PHX : PHY
|
|
||||||
LDA.b $06 : PHA
|
|
||||||
|
|
||||||
STZ.b $02 ; best item class found
|
|
||||||
|
|
||||||
LDA.l ItemSources : BIT.w #$0001 : BEQ +
|
LDA.l ItemSources : BIT.w #$0001 : BEQ +
|
||||||
JSR CheckChests
|
JSR CheckChests
|
||||||
+
|
+
|
||||||
@@ -146,25 +65,24 @@ GetLootLevel:
|
|||||||
+
|
+
|
||||||
|
|
||||||
LDA.l ItemSources : BIT.w #$0008 : BEQ +
|
LDA.l ItemSources : BIT.w #$0008 : BEQ +
|
||||||
JSR CheckMisc
|
JSR CheckBoss
|
||||||
JSR CheckMisc2
|
|
||||||
+
|
+
|
||||||
|
|
||||||
LDA.l ItemSources : BIT.w #$0010 : BEQ +
|
LDA.l ItemSources : BIT.w #$0010 : BEQ +
|
||||||
JSR CheckPrize
|
JSR CheckPrize
|
||||||
+
|
+
|
||||||
|
|
||||||
JSR CheckNpcs
|
|
||||||
|
|
||||||
.done
|
.done
|
||||||
|
PLA : STA.b $0E
|
||||||
PLA : STA.b $06
|
PLA : STA.b $06
|
||||||
PLY : PLX : PLB
|
PLY : PLX : PLB
|
||||||
PLP
|
PLP
|
||||||
|
LDA.b $02
|
||||||
RTL
|
RTL
|
||||||
|
|
||||||
CheckChests:
|
CheckChests:
|
||||||
LDA.b $CA
|
LDA.b $CA
|
||||||
AND.w #$01FF
|
AND.w #$00FF
|
||||||
STA.b $00
|
STA.b $00
|
||||||
ASL A
|
ASL A
|
||||||
TAX
|
TAX
|
||||||
@@ -209,22 +127,25 @@ CheckChests:
|
|||||||
.done
|
.done
|
||||||
RTS
|
RTS
|
||||||
|
|
||||||
CheckMisc:
|
CheckBoss:
|
||||||
; this includes bosses, bonk torches, and standing items (in caves + hera cage key)
|
; we assume all bosses are in section 1 of split sections
|
||||||
; all dungeon items in this section are in section 1 of split sections
|
; mainly to simplify hera cage key and GT torch
|
||||||
; for cave items we'll always know what section we're in
|
; which use the same flow
|
||||||
; but for dungeon items, we won't have a section specified in door rando
|
; and bosses are always in their own section anyway
|
||||||
; so if we don't have a section, assume it's 1, and it'll match all the dungeon items anyway
|
|
||||||
LDA.b $CA
|
LDA.b $CA
|
||||||
BIT.w #$F000
|
AND.w #$F000
|
||||||
BNE +
|
XBA
|
||||||
ORA.w #$1000
|
CMP.w #$0020
|
||||||
|
BCC +
|
||||||
|
RTS
|
||||||
|
|
||||||
+
|
+
|
||||||
AND.w #$F1FF
|
LDA.b $CA
|
||||||
|
AND.w #$00FF
|
||||||
STA.b $04
|
STA.b $04
|
||||||
|
|
||||||
LDX.w #$FFFA
|
LDX.w #$FFFA
|
||||||
.next_misc
|
.next_boss
|
||||||
INX #6
|
INX #6
|
||||||
LDA.l MiscLocations, X
|
LDA.l MiscLocations, X
|
||||||
BPL .check
|
BPL .check
|
||||||
@@ -232,10 +153,9 @@ CheckMisc:
|
|||||||
|
|
||||||
.check
|
.check
|
||||||
CMP.b $04
|
CMP.b $04
|
||||||
BNE .next_misc
|
BNE .next_boss
|
||||||
|
|
||||||
TXY
|
TXY
|
||||||
AND.w #$01FF
|
|
||||||
CMP.b RoomIndex
|
CMP.b RoomIndex
|
||||||
BEQ .current_room
|
BEQ .current_room
|
||||||
|
|
||||||
@@ -260,7 +180,7 @@ CheckMisc:
|
|||||||
|
|
||||||
TYX
|
TYX
|
||||||
BIT.b $04
|
BIT.b $04
|
||||||
BNE .next_misc ; continue checking if we already got the item
|
BNE .next_boss ; continue checking if we already got the item
|
||||||
|
|
||||||
LDA.l MiscLocations+4, X
|
LDA.l MiscLocations+4, X
|
||||||
STA.b $05
|
STA.b $05
|
||||||
@@ -272,28 +192,11 @@ CheckMisc:
|
|||||||
AND.w #$00FF
|
AND.w #$00FF
|
||||||
JSR GetLootClass
|
JSR GetLootClass
|
||||||
|
|
||||||
BRA .next_misc
|
BRA .next_boss
|
||||||
|
|
||||||
CheckMisc2:
|
|
||||||
; this currently only includes the library and Uncle
|
|
||||||
; so let's just hard-code them for now
|
|
||||||
LDA.b $CA
|
|
||||||
CMP.w #$2107 : BNE +
|
|
||||||
LDA.l NpcFlags : AND.w #$0080 : BNE +
|
|
||||||
LDA.l LibraryItem : AND.w #$00FF : JSR GetLootClass
|
|
||||||
+
|
|
||||||
|
|
||||||
LDA.b $CA
|
|
||||||
CMP.w #$1055 : BNE +
|
|
||||||
LDA.l ProgressFlags : AND.w #$0001 : BNE +
|
|
||||||
LDA.l UncleItem : AND.w #$00FF : JSR GetLootClass
|
|
||||||
+
|
|
||||||
|
|
||||||
RTS
|
|
||||||
|
|
||||||
CheckPrize:
|
CheckPrize:
|
||||||
LDA.b $CA
|
LDA.b $CA
|
||||||
AND.w #$01FF
|
AND.w #$00FF
|
||||||
STA.b $04
|
STA.b $04
|
||||||
|
|
||||||
LDX.w #$FFFD
|
LDX.w #$FFFD
|
||||||
@@ -327,44 +230,9 @@ CheckPrize:
|
|||||||
|
|
||||||
BRA .next_prize
|
BRA .next_prize
|
||||||
|
|
||||||
CheckNpcs:
|
|
||||||
LDA.b $CA
|
|
||||||
|
|
||||||
LDX.w #$FFFA
|
|
||||||
.next_npc
|
|
||||||
INX #6
|
|
||||||
LDA.l NpcItems, X
|
|
||||||
BMI .nope
|
|
||||||
|
|
||||||
CMP.b $CA
|
|
||||||
BNE .next_npc
|
|
||||||
|
|
||||||
LDA.l NpcItems+3, X ; get location of data to check
|
|
||||||
STA.b $05
|
|
||||||
|
|
||||||
LDA.l NpcItems+2, X
|
|
||||||
STA.b $04
|
|
||||||
|
|
||||||
LDA.b [$04]
|
|
||||||
AND.w #$00FF
|
|
||||||
AND.l NpcItems+5, X
|
|
||||||
BNE .next_npc
|
|
||||||
|
|
||||||
.yep
|
|
||||||
LDA.w NpcItemIndicator
|
|
||||||
ORA.w #$0001
|
|
||||||
STA.w NpcItemIndicator
|
|
||||||
RTS
|
|
||||||
|
|
||||||
.nope
|
|
||||||
LDA.w NpcItemIndicator
|
|
||||||
AND.w #$FF00
|
|
||||||
STA.w NpcItemIndicator
|
|
||||||
RTS
|
|
||||||
|
|
||||||
CheckPots:
|
CheckPots:
|
||||||
LDA.b $CA
|
LDA.b $CA
|
||||||
AND.w #$01FF
|
AND.w #$00FF
|
||||||
ASL A
|
ASL A
|
||||||
TAX
|
TAX
|
||||||
|
|
||||||
@@ -430,7 +298,7 @@ CheckPots:
|
|||||||
+
|
+
|
||||||
|
|
||||||
LDA.b $CA
|
LDA.b $CA
|
||||||
AND.w #$01FF
|
AND.w #$00FF
|
||||||
ASL A
|
ASL A
|
||||||
TAX
|
TAX
|
||||||
if !FEATURE_FIX_BASEROM
|
if !FEATURE_FIX_BASEROM
|
||||||
@@ -468,7 +336,7 @@ CheckJunkPot:
|
|||||||
+
|
+
|
||||||
|
|
||||||
LDA.b $CA
|
LDA.b $CA
|
||||||
AND.w #$01FF
|
AND.w #$00FF
|
||||||
ASL A
|
ASL A
|
||||||
TAX
|
TAX
|
||||||
LDA.l PotCollectionRateTable, X
|
LDA.l PotCollectionRateTable, X
|
||||||
@@ -496,7 +364,7 @@ endif
|
|||||||
|
|
||||||
CheckEnemies:
|
CheckEnemies:
|
||||||
LDA.b $CA
|
LDA.b $CA
|
||||||
AND.w #$01FF
|
AND.w #$00FF
|
||||||
ASL A
|
ASL A
|
||||||
TAX
|
TAX
|
||||||
|
|
||||||
@@ -586,7 +454,7 @@ CheckEnemies:
|
|||||||
+
|
+
|
||||||
|
|
||||||
LDA.b $CA
|
LDA.b $CA
|
||||||
AND.w #$01FF
|
AND.w #$00FF
|
||||||
ASL A
|
ASL A
|
||||||
TAX
|
TAX
|
||||||
|
|
||||||
@@ -616,19 +484,13 @@ GetLootClass:
|
|||||||
CMP.w #$0080 : BNE .not_compass
|
CMP.w #$0080 : BNE .not_compass
|
||||||
|
|
||||||
.compass
|
.compass
|
||||||
LDA.b $0E
|
LDA.l AlwaysShowCompass : BNE .check_value
|
||||||
AND.w #$00FF
|
|
||||||
CMP.w #$0002
|
|
||||||
BEQ .check_value
|
|
||||||
|
|
||||||
.not_compass
|
.not_compass
|
||||||
LDA.b $0E
|
LDA.b $0E
|
||||||
BEQ .done
|
BEQ .done
|
||||||
CMP.w #$0003
|
CMP.w #$0001
|
||||||
BCS .check_value
|
BEQ .value_set
|
||||||
|
|
||||||
LDA.w #$0001
|
|
||||||
BRA .value_set
|
|
||||||
|
|
||||||
.check_value
|
.check_value
|
||||||
LDA.l LootTypeMapping, X
|
LDA.l LootTypeMapping, X
|
||||||
@@ -651,13 +513,9 @@ GetPotJunkClass:
|
|||||||
|
|
||||||
LDA.b $0E
|
LDA.b $0E
|
||||||
BEQ .done
|
BEQ .done
|
||||||
CMP.w #$0003
|
CMP.w #$0001
|
||||||
BCS .check_value
|
BEQ .value_set
|
||||||
|
|
||||||
LDA.w #$0001
|
|
||||||
BRA .value_set
|
|
||||||
|
|
||||||
.check_value
|
|
||||||
; hardcode as junk for now
|
; hardcode as junk for now
|
||||||
LDA.w #$0002
|
LDA.w #$0002
|
||||||
|
|
||||||
@@ -674,7 +532,7 @@ macro DefineGetFooSection(type, offset)
|
|||||||
Get<type>Section:
|
Get<type>Section:
|
||||||
PHX
|
PHX
|
||||||
LDA.b $CA
|
LDA.b $CA
|
||||||
AND.w #$01FF
|
AND.w #$00FF
|
||||||
ASL A
|
ASL A
|
||||||
TAX
|
TAX
|
||||||
LDA.l SplitRooms, X
|
LDA.l SplitRooms, X
|
||||||
@@ -722,13 +580,13 @@ Check<type>Section:
|
|||||||
STA.b $CC
|
STA.b $CC
|
||||||
|
|
||||||
LDA.b $CB
|
LDA.b $CB
|
||||||
AND.w #$00F0
|
AND.w #$00FF
|
||||||
BEQ .yes
|
BEQ .yes
|
||||||
|
|
||||||
JSR Get<type>Section
|
JSR Get<type>Section
|
||||||
|
|
||||||
LDA.b $CB
|
LDA.b $CB
|
||||||
AND.w #$00F0
|
AND.w #$00FF
|
||||||
LSR A : LSR A : LSR A : LSR A
|
LSR A : LSR A : LSR A : LSR A
|
||||||
DEC A
|
DEC A
|
||||||
CMP.b $CE
|
CMP.b $CE
|
||||||
|
|||||||
@@ -3,8 +3,8 @@
|
|||||||
!TIER_LOW_KEY = $03
|
!TIER_LOW_KEY = $03
|
||||||
!TIER_HEALTH = $05
|
!TIER_HEALTH = $05
|
||||||
!TIER_MINOR = $06
|
!TIER_MINOR = $06
|
||||||
!TIER_COMPASS = $07
|
!TIER_MAP = $07
|
||||||
!TIER_MAP = $08
|
!TIER_COMPASS = $08
|
||||||
!TIER_SM_KEY = $09
|
!TIER_SM_KEY = $09
|
||||||
!TIER_BIG_KEY = $0A
|
!TIER_BIG_KEY = $0A
|
||||||
!TIER_MAJOR = $0B
|
!TIER_MAJOR = $0B
|
||||||
@@ -49,7 +49,7 @@ db !TIER_CRYSTAL ; 20 - Crystal
|
|||||||
db !TIER_MINOR ; 21 - Net
|
db !TIER_MINOR ; 21 - Net
|
||||||
db !TIER_MINOR ; 22 - Blue Mail
|
db !TIER_MINOR ; 22 - Blue Mail
|
||||||
db !TIER_MINOR ; 23 - Red Mail
|
db !TIER_MINOR ; 23 - Red Mail
|
||||||
db !TIER_SM_KEY ; 24 - Small Key
|
db !TIER_LOW_KEY ; 24 - Small Key
|
||||||
db !TIER_COMPASS ; 25 - Compass
|
db !TIER_COMPASS ; 25 - Compass
|
||||||
db !TIER_HEALTH ; 26 - Heart Container from 4/4
|
db !TIER_HEALTH ; 26 - Heart Container from 4/4
|
||||||
db !TIER_JUNK ; 27 - Bomb
|
db !TIER_JUNK ; 27 - Bomb
|
||||||
@@ -116,7 +116,7 @@ db !TIER_JUNK ; 62 - RNG pool item (single)
|
|||||||
db !TIER_JUNK ; 63 - RNG pool item (multi)
|
db !TIER_JUNK ; 63 - RNG pool item (multi)
|
||||||
db !TIER_MAJOR ; 64 - Progressive bow
|
db !TIER_MAJOR ; 64 - Progressive bow
|
||||||
db !TIER_MAJOR ; 65 - Progressive bow
|
db !TIER_MAJOR ; 65 - Progressive bow
|
||||||
db !TIER_HEALTH ; 66 - Potion refill (orange)
|
db !TIER_JUNK ; 66 -
|
||||||
db !TIER_JUNK ; 67 -
|
db !TIER_JUNK ; 67 -
|
||||||
db !TIER_JUNK ; 68 -
|
db !TIER_JUNK ; 68 -
|
||||||
db !TIER_JUNK ; 69 -
|
db !TIER_JUNK ; 69 -
|
||||||
|
|||||||
@@ -101,7 +101,7 @@ db $00 ; 62 - RNG pool item (single)
|
|||||||
db $00 ; 63 - RNG pool item (multi)
|
db $00 ; 63 - RNG pool item (multi)
|
||||||
db $00 ; 64 - Progressive bow
|
db $00 ; 64 - Progressive bow
|
||||||
db $00 ; 65 - Progressive bow
|
db $00 ; 65 - Progressive bow
|
||||||
db $00 ; 66 - Potion refill (orange)
|
db $00 ; 66 -
|
||||||
db $00 ; 67 -
|
db $00 ; 67 -
|
||||||
db $00 ; 68 -
|
db $00 ; 68 -
|
||||||
db $00 ; 69 -
|
db $00 ; 69 -
|
||||||
|
|||||||
@@ -61,24 +61,7 @@ SplitRooms:
|
|||||||
%d(.no) : %d(.d1) : %d(.no) : %d(.no) : %d(.no) : %d(.no) : %d(.d6) : %d(.no)
|
%d(.no) : %d(.d1) : %d(.no) : %d(.no) : %d(.no) : %d(.no) : %d(.d6) : %d(.no)
|
||||||
%d(.no) : %d(.no) : %d(.no) : %d(.db) : %d(.no) : %d(.no) : %d(.no) : %d(.no)
|
%d(.no) : %d(.no) : %d(.no) : %d(.db) : %d(.no) : %d(.no) : %d(.no) : %d(.no)
|
||||||
|
|
||||||
; E0
|
%d(.no)
|
||||||
%d(.no) : %d(.no) : %d(.no) : %d(.no) : %d(.no) : %d(.no) : %d(.no) : %d(.no)
|
|
||||||
%d(.no) : %d(.no) : %d(.no) : %d(.no) : %d(.no) : %d(.no) : %d(.no) : %d(.no)
|
|
||||||
|
|
||||||
; F0
|
|
||||||
%d(.no) : %d(.no) : %d(.no) : %d(.no) : %d(.no) : %d(.no) : %d(.no) : %d(.no)
|
|
||||||
%d(.no) : %d(.no) : %d(.no) : %d(.no) : %d(.no) : %d(.no) : %d(.no) : %d(.no)
|
|
||||||
|
|
||||||
; 100
|
|
||||||
%d(.no) : %d(.101) : %d(.no) : %d(.103) : %d(.no) : %d(.no) : %d(.106) : %d(.107)
|
|
||||||
%d(.no) : %d(.no) : %d(.no) : %d(.no) : %d(.10c) : %d(.no) : %d(.10e) : %d(.no)
|
|
||||||
|
|
||||||
; 110
|
|
||||||
%d(.no) : %d(.no) : %d(.112) : %d(.no) : %d(.114) : %d(.115) : %d(.no) : %d(.no)
|
|
||||||
%d(.no) : %d(.no) : %d(.no) : %d(.11b) : %d(.11c) : %d(.no) : %d(.11e) : %d(.11f)
|
|
||||||
|
|
||||||
; 120
|
|
||||||
%d(.120) : %d(.no) : %d(.122) : %d(.no) : %d(.124) : %d(.125) : %d(.126) : %d(.127)
|
|
||||||
|
|
||||||
.no
|
.no
|
||||||
db $00
|
db $00
|
||||||
@@ -452,7 +435,7 @@ db $01
|
|||||||
%d(..areas) : %d(..doors) : %d(.no_items) : %d(.no_items) : %d(.no_items) : %d(.no_items)
|
%d(..areas) : %d(..doors) : %d(.no_items) : %d(.no_items) : %d(.no_items) : %d(.no_items)
|
||||||
..areas
|
..areas
|
||||||
db $02, $00, $80, $00, $FF
|
db $02, $00, $80, $00, $FF
|
||||||
db $01, $34, $44, $B4, $FF
|
db $01, $34, $D4, $B8, $FF
|
||||||
db $FF
|
db $FF
|
||||||
..doors
|
..doors
|
||||||
db $03, $06
|
db $03, $06
|
||||||
@@ -586,344 +569,3 @@ db $FF
|
|||||||
..chests
|
..chests
|
||||||
db $01
|
db $01
|
||||||
db $FF
|
db $FF
|
||||||
|
|
||||||
.101 ; East Snitch House (2) // West Snitch House (1)
|
|
||||||
db $01
|
|
||||||
%sq($00)
|
|
||||||
%d(..areas) : %d(..doors) : %d(.no_items)
|
|
||||||
%d(.no_items) : %d(..pots) : %d(..enemies)
|
|
||||||
..areas
|
|
||||||
db $03, $00, $7F, $00, $FF
|
|
||||||
db $FF
|
|
||||||
..doors
|
|
||||||
db $06
|
|
||||||
db $FF
|
|
||||||
..pots
|
|
||||||
db $00
|
|
||||||
db $FF
|
|
||||||
..enemies
|
|
||||||
db $00
|
|
||||||
db $FF
|
|
||||||
|
|
||||||
.103 ; Man With Beds (3) // Front of Tavern (2) // Back of Tavern (1)
|
|
||||||
db $02
|
|
||||||
%sq($00)
|
|
||||||
%d(..areas3) : %d(..doors3) : %d(.no_items)
|
|
||||||
%d(.no_items) : %d(.no_items) : %d(..enemies3)
|
|
||||||
%sq($00)
|
|
||||||
%d(..areas2) : %d(..doors2) : %d(.no_items)
|
|
||||||
%d(.no_items) : %d(..pots2) : %d(..enemies2)
|
|
||||||
..areas3
|
|
||||||
db $03, $80, $FF, $00, $FF
|
|
||||||
db $FF
|
|
||||||
..doors3
|
|
||||||
db $08
|
|
||||||
db $FF
|
|
||||||
..enemies3
|
|
||||||
db $02
|
|
||||||
db $FF
|
|
||||||
..areas2
|
|
||||||
db $03, $00, $7F, $50, $FF
|
|
||||||
db $FF
|
|
||||||
..doors2
|
|
||||||
db $06
|
|
||||||
db $FF
|
|
||||||
..pots2
|
|
||||||
db $02
|
|
||||||
db $FF
|
|
||||||
..enemies2
|
|
||||||
db $00
|
|
||||||
db $01
|
|
||||||
db $FF
|
|
||||||
|
|
||||||
.106 ; VoO Chest Game (2) // Brewery (1)
|
|
||||||
db $01
|
|
||||||
%sq($00)
|
|
||||||
%d(..areas) : %d(..doors) : %d(.no_items)
|
|
||||||
%d(.no_items) : %d(.no_items) : %d(..enemies)
|
|
||||||
..areas
|
|
||||||
db $03, $00, $7F, $00, $FF
|
|
||||||
db $FF
|
|
||||||
..doors
|
|
||||||
db $06
|
|
||||||
db $FF
|
|
||||||
..enemies
|
|
||||||
db $00
|
|
||||||
db $FF
|
|
||||||
|
|
||||||
.107 ; Library (2) // Bomb Refill Hut (1)
|
|
||||||
db $01
|
|
||||||
%sq($00)
|
|
||||||
%d(..areas) : %d(..doors) : %d(.no_items)
|
|
||||||
%d(.no_items) : %d(.no_items) : %d(.no_items)
|
|
||||||
..areas
|
|
||||||
db $03, $00, $7F, $00, $FF
|
|
||||||
db $FF
|
|
||||||
..doors
|
|
||||||
db $06
|
|
||||||
db $FF
|
|
||||||
|
|
||||||
.10c ; Mimic Cave (2) // Hookshot Fairy Pot (1)
|
|
||||||
db $01
|
|
||||||
%sq($00)
|
|
||||||
%d(..areas) : %d(..doors) : %d(.no_items)
|
|
||||||
%d(..chests) : %d(.no_items) : %d(..enemies)
|
|
||||||
..areas
|
|
||||||
db $03, $00, $7F, $00, $FF
|
|
||||||
db $FF
|
|
||||||
..doors
|
|
||||||
db $06
|
|
||||||
db $FF
|
|
||||||
..chests
|
|
||||||
db $00
|
|
||||||
db $FF
|
|
||||||
..enemies
|
|
||||||
db $04
|
|
||||||
db $05
|
|
||||||
db $06
|
|
||||||
db $07
|
|
||||||
db $FF
|
|
||||||
|
|
||||||
.10e ; Storyteller (2) // Storyteller (1)
|
|
||||||
db $01
|
|
||||||
%sq($00)
|
|
||||||
%d(..areas) : %d(..doors) : %d(.no_items)
|
|
||||||
%d(.no_items) : %d(.no_items) : %d(..enemies)
|
|
||||||
..areas
|
|
||||||
db $03, $00, $7F, $00, $FF
|
|
||||||
db $FF
|
|
||||||
..doors
|
|
||||||
db $06
|
|
||||||
db $FF
|
|
||||||
..chests
|
|
||||||
db $FF
|
|
||||||
..pots
|
|
||||||
db $FF
|
|
||||||
..enemies
|
|
||||||
db $00
|
|
||||||
db $FF
|
|
||||||
|
|
||||||
.112 ; Dark Chapel (2) // Store (1)
|
|
||||||
db $01
|
|
||||||
%sq($00)
|
|
||||||
%d(..areas) : %d(..doors) : %d(.no_items)
|
|
||||||
%d(.no_items) : %d(.no_items) : %d(..enemies)
|
|
||||||
..areas
|
|
||||||
db $03, $00, $7F, $00, $FF
|
|
||||||
db $FF
|
|
||||||
..doors
|
|
||||||
db $06
|
|
||||||
db $FF
|
|
||||||
..enemies
|
|
||||||
db $00
|
|
||||||
db $FF
|
|
||||||
|
|
||||||
.114 ; Waterfall Fairy (2) // Hint NPC (1)
|
|
||||||
db $01
|
|
||||||
%sq($00)
|
|
||||||
%d(..areas) : %d(..doors) : %d(.no_items)
|
|
||||||
%d(..chests) : %d(.no_items) : %d(..enemies)
|
|
||||||
..areas
|
|
||||||
db $03, $00, $7F, $00, $FF
|
|
||||||
db $FF
|
|
||||||
..doors
|
|
||||||
db $06
|
|
||||||
db $FF
|
|
||||||
..chests
|
|
||||||
db $00
|
|
||||||
db $01
|
|
||||||
db $FF
|
|
||||||
..enemies
|
|
||||||
db $00
|
|
||||||
db $FF
|
|
||||||
|
|
||||||
.115 ; Capacity Fairy (1) // Healing Fairy (2)
|
|
||||||
db $01
|
|
||||||
%sq($00)
|
|
||||||
%d(..areas) : %d(..doors) : %d(.no_items)
|
|
||||||
%d(.no_items) : %d(.no_items) : %d(..enemies)
|
|
||||||
..areas
|
|
||||||
db $03, $80, $FF, $80, $FF
|
|
||||||
db $FF
|
|
||||||
..doors
|
|
||||||
db $08
|
|
||||||
db $FF
|
|
||||||
..enemies
|
|
||||||
db $00
|
|
||||||
db $FF
|
|
||||||
|
|
||||||
.11b ; Cave 45 (2) // Graveyard Ledge (1)
|
|
||||||
db $01
|
|
||||||
%sq($00)
|
|
||||||
%d(..areas) : %d(..doors) : %d(.no_items)
|
|
||||||
%d(.no_items) : %d(..pots) : %d(..enemies)
|
|
||||||
..areas
|
|
||||||
db $03, $00, $7F, $00, $FF
|
|
||||||
db $FF
|
|
||||||
..doors
|
|
||||||
db $06
|
|
||||||
db $FF
|
|
||||||
..pots
|
|
||||||
db $00
|
|
||||||
db $01
|
|
||||||
db $02
|
|
||||||
db $03
|
|
||||||
db $04
|
|
||||||
db $05
|
|
||||||
db $FF
|
|
||||||
..enemies
|
|
||||||
db $01
|
|
||||||
db $FF
|
|
||||||
|
|
||||||
.11c ; Bomb Shop (2) // C-Shaped House (1)
|
|
||||||
db $01
|
|
||||||
%sq($00)
|
|
||||||
%d(..areas) : %d(..doors) : %d(.no_items)
|
|
||||||
%d(.no_items) : %d(.no_items) : %d(..enemies)
|
|
||||||
..areas
|
|
||||||
db $03, $00, $7F, $00, $FF
|
|
||||||
db $FF
|
|
||||||
..doors
|
|
||||||
db $06
|
|
||||||
db $FF
|
|
||||||
..enemies
|
|
||||||
db $00
|
|
||||||
db $FF
|
|
||||||
|
|
||||||
.11e ; Long Fairy Cave (2) // Hype Cave (1)
|
|
||||||
db $01
|
|
||||||
%sq($00)
|
|
||||||
%d(..areas) : %d(..doors) : %d(.no_items)
|
|
||||||
%d(.no_items) : %d(.no_items) : %d(..enemies)
|
|
||||||
..areas
|
|
||||||
db $03, $00, $7F, $00, $FF
|
|
||||||
db $FF
|
|
||||||
..doors
|
|
||||||
db $06
|
|
||||||
db $FF
|
|
||||||
..enemies
|
|
||||||
db $00
|
|
||||||
db $01
|
|
||||||
db $02
|
|
||||||
db $03
|
|
||||||
db $FF
|
|
||||||
|
|
||||||
.11f ; Lumberjack House (1) // Store (2)
|
|
||||||
db $01
|
|
||||||
%sq($00)
|
|
||||||
%d(..areas) : %d(..doors) : %d(.no_items)
|
|
||||||
%d(.no_items) : %d(.no_items) : %d(..enemies)
|
|
||||||
..areas
|
|
||||||
db $03, $80, $FF, $00, $FF
|
|
||||||
db $FF
|
|
||||||
..doors
|
|
||||||
db $08
|
|
||||||
db $FF
|
|
||||||
..enemies
|
|
||||||
db $00
|
|
||||||
db $FF
|
|
||||||
|
|
||||||
.120 ; Ice Rod Cave (1) // Cool Bee Cave (2)
|
|
||||||
db $01
|
|
||||||
%sq($00)
|
|
||||||
%d(..areas) : %d(..doors) : %d(.no_items)
|
|
||||||
%d(.no_items) : %d(.no_items) : %d(..enemies)
|
|
||||||
..areas
|
|
||||||
db $03, $80, $FF, $00, $FF
|
|
||||||
db $03, $80, $FF, $00, $FF
|
|
||||||
db $FF
|
|
||||||
..doors
|
|
||||||
db $08
|
|
||||||
db $FF
|
|
||||||
..enemies
|
|
||||||
db $00
|
|
||||||
db $01
|
|
||||||
db $02
|
|
||||||
db $FF
|
|
||||||
|
|
||||||
.122 ; Fortune Teller (2) // Other Fortune Teller (1)
|
|
||||||
db $01
|
|
||||||
%sq($00)
|
|
||||||
%d(..areas) : %d(..doors) : %d(.no_items)
|
|
||||||
%d(.no_items) : %d(.no_items) : %d(..enemies)
|
|
||||||
..areas
|
|
||||||
db $03, $00, $7F, $00, $FF
|
|
||||||
db $FF
|
|
||||||
..doors
|
|
||||||
db $06
|
|
||||||
db $FF
|
|
||||||
..enemies
|
|
||||||
db $00
|
|
||||||
db $FF
|
|
||||||
|
|
||||||
.124 ; 50-Rupee Cave (1) // Bonk Rocks (2)
|
|
||||||
db $01
|
|
||||||
%sq($00)
|
|
||||||
%d(..areas) : %d(..doors) : %d(.no_items)
|
|
||||||
%d(..chests) : %d(.no_items) : %d(.no_items)
|
|
||||||
..areas
|
|
||||||
db $03, $80, $FF, $00, $FF
|
|
||||||
db $FF
|
|
||||||
..doors
|
|
||||||
db $08
|
|
||||||
db $FF
|
|
||||||
..chests
|
|
||||||
db $00
|
|
||||||
db $FF
|
|
||||||
|
|
||||||
.125 ; 20-Rupee Cave (2) // Spiky Hint Cave (1)
|
|
||||||
db $01
|
|
||||||
%sq($00)
|
|
||||||
%d(..areas) : %d(..doors) : %d(.no_items)
|
|
||||||
%d(.no_items) : %d(..pots) : %d(..enemies)
|
|
||||||
..areas
|
|
||||||
db $03, $00, $7F, $00, $FF
|
|
||||||
db $FF
|
|
||||||
..doors
|
|
||||||
db $06
|
|
||||||
db $FF
|
|
||||||
..pots
|
|
||||||
db $00
|
|
||||||
db $01
|
|
||||||
db $02
|
|
||||||
db $03
|
|
||||||
db $FF
|
|
||||||
..enemies
|
|
||||||
db $00
|
|
||||||
db $FF
|
|
||||||
|
|
||||||
.126 ; Bonk Fairy Pool (2) // Checkerboard Cave (1)
|
|
||||||
db $01
|
|
||||||
%sq($00)
|
|
||||||
%d(..areas) : %d(..doors) : %d(.no_items)
|
|
||||||
%d(.no_items) : %d(.no_items) : %d(..enemies)
|
|
||||||
..areas
|
|
||||||
db $03, $00, $7F, $00, $FF
|
|
||||||
db $FF
|
|
||||||
..doors
|
|
||||||
db $06
|
|
||||||
db $FF
|
|
||||||
..enemies
|
|
||||||
db $01
|
|
||||||
db $02
|
|
||||||
db $03
|
|
||||||
db $04
|
|
||||||
db $FF
|
|
||||||
|
|
||||||
.127 ; Hammer Pegs Cave (1) // Fake Dark Lake Hylia Spike Hint Cave (2)
|
|
||||||
db $01
|
|
||||||
%sq($00)
|
|
||||||
%d(..areas) : %d(..doors) : %d(.no_items)
|
|
||||||
%d(.no_items) : %d(..pots) : %d(.no_items)
|
|
||||||
..areas
|
|
||||||
db $03, $80, $FF, $00, $FF
|
|
||||||
db $FF
|
|
||||||
..doors
|
|
||||||
db $08
|
|
||||||
db $FF
|
|
||||||
..pots
|
|
||||||
db $04
|
|
||||||
db $05
|
|
||||||
db $06
|
|
||||||
db $07
|
|
||||||
db $FF
|
|
||||||
|
|||||||
@@ -150,10 +150,7 @@ DrawFullRoomTile:
|
|||||||
RTL
|
RTL
|
||||||
|
|
||||||
DrawSingleRoomLoot:
|
DrawSingleRoomLoot:
|
||||||
LDA.l MapItems_enabled : AND.w #$00FF : BNE +
|
PHX : PHY
|
||||||
RTL
|
|
||||||
|
|
||||||
+ PHX : PHY
|
|
||||||
|
|
||||||
TYX
|
TYX
|
||||||
|
|
||||||
@@ -175,8 +172,7 @@ DrawSingleRoomLoot:
|
|||||||
STA.w GFXStripes+$0C, Y
|
STA.w GFXStripes+$0C, Y
|
||||||
|
|
||||||
LDA.b $CA
|
LDA.b $CA
|
||||||
AND.w #$F0FF
|
JSL CheckLoot
|
||||||
JSL CheckMapLoot
|
|
||||||
|
|
||||||
ASL A : ASL A : ASL A
|
ASL A : ASL A : ASL A
|
||||||
|
|
||||||
@@ -691,13 +687,6 @@ GetSpecificRoomVisibility:
|
|||||||
STA.b $0A
|
STA.b $0A
|
||||||
+
|
+
|
||||||
|
|
||||||
SEP #$20
|
|
||||||
LDA.b $0A
|
|
||||||
CMP.b $0B
|
|
||||||
BCC +
|
|
||||||
STA.b $0B
|
|
||||||
+
|
|
||||||
|
|
||||||
REP #$20
|
REP #$20
|
||||||
LDA.b $CA
|
LDA.b $CA
|
||||||
AND.w #$00FF
|
AND.w #$00FF
|
||||||
@@ -1240,7 +1229,7 @@ DrawDoorsMapBlinker:
|
|||||||
AND.w #$01E0
|
AND.w #$01E0
|
||||||
ASL A : ASL A : ASL A
|
ASL A : ASL A : ASL A
|
||||||
XBA
|
XBA
|
||||||
CLC : ADC.w #$00A5
|
CLC : ADC.w #$00A4
|
||||||
STA.w OAMBuffer, X
|
STA.w OAMBuffer, X
|
||||||
|
|
||||||
LDA.b LinkPosY
|
LDA.b LinkPosY
|
||||||
@@ -1718,13 +1707,10 @@ DoorsMapChangeDungeon:
|
|||||||
BNE +
|
BNE +
|
||||||
INX
|
INX
|
||||||
+ LDA.l DungeonMapData.prev, X
|
+ LDA.l DungeonMapData.prev, X
|
||||||
STA.w DungeonID
|
|
||||||
CMP.b $00
|
CMP.b $00
|
||||||
BEQ .done
|
BEQ .done
|
||||||
|
|
||||||
JSL IsValidDungeonToSwapTo
|
STA.w DungeonID
|
||||||
BCC .next
|
|
||||||
|
|
||||||
JSL FindFirstEntrance
|
JSL FindFirstEntrance
|
||||||
CPY.b #$FF
|
CPY.b #$FF
|
||||||
BEQ .next
|
BEQ .next
|
||||||
@@ -2119,13 +2105,6 @@ DrawDoorsStairs:
|
|||||||
|
|
||||||
DetectLinksSection:
|
DetectLinksSection:
|
||||||
LDA.b RoomIndex
|
LDA.b RoomIndex
|
||||||
CMP.w #$0128
|
|
||||||
BCC +
|
|
||||||
|
|
||||||
LDA.w #$0000
|
|
||||||
RTL
|
|
||||||
+
|
|
||||||
|
|
||||||
ASL A
|
ASL A
|
||||||
TAX
|
TAX
|
||||||
LDA.l SplitRooms, X
|
LDA.l SplitRooms, X
|
||||||
|
|||||||
@@ -1,5 +1,4 @@
|
|||||||
RedrawLoot:
|
RedrawLoot:
|
||||||
SEP #$20
|
|
||||||
JSL DrawLoot
|
JSL DrawLoot
|
||||||
|
|
||||||
; what we wrote over
|
; what we wrote over
|
||||||
@@ -33,9 +32,6 @@ DrawLoot:
|
|||||||
LDA.l DRMode
|
LDA.l DRMode
|
||||||
BNE .skip
|
BNE .skip
|
||||||
|
|
||||||
LDA.l MapItems_enabled
|
|
||||||
BEQ .skip
|
|
||||||
|
|
||||||
REP #$30
|
REP #$30
|
||||||
PHX : PHY
|
PHX : PHY
|
||||||
|
|
||||||
@@ -129,7 +125,7 @@ DrawSingleFloorLoot:
|
|||||||
LDA.w #$0000
|
LDA.w #$0000
|
||||||
BRA +
|
BRA +
|
||||||
.valid_room
|
.valid_room
|
||||||
JSL CheckMapLoot
|
JSL CheckLoot
|
||||||
+
|
+
|
||||||
ASL A : ASL A : ASL A
|
ASL A : ASL A : ASL A
|
||||||
|
|
||||||
|
|||||||
@@ -1,59 +0,0 @@
|
|||||||
LoadDungeonIndicator:
|
|
||||||
; what we wrote over
|
|
||||||
JSL InitializeTilesets
|
|
||||||
|
|
||||||
LDA.w DungeonID
|
|
||||||
CMP.b #DungeonIndicatorMap_end-DungeonIndicatorMap : BCS .done
|
|
||||||
TAX
|
|
||||||
|
|
||||||
; mark dungeon as entered
|
|
||||||
REP #$20
|
|
||||||
LDA.w DungeonMask, X
|
|
||||||
ORA.l DungeonVisited
|
|
||||||
STA.l DungeonVisited
|
|
||||||
SEP #$20
|
|
||||||
|
|
||||||
; load indicator
|
|
||||||
LDA.l DungeonIndicatorMap, X
|
|
||||||
TAX
|
|
||||||
|
|
||||||
LDA.b #$80
|
|
||||||
STA.w $2115
|
|
||||||
|
|
||||||
REP #$20
|
|
||||||
LDA.w #$7140
|
|
||||||
STA.w $2116
|
|
||||||
|
|
||||||
LDY.b #$10
|
|
||||||
|
|
||||||
- LDA.l DungeonIndicatorGfx, X
|
|
||||||
STA.w $2118
|
|
||||||
INX #2
|
|
||||||
DEY #2
|
|
||||||
BNE -
|
|
||||||
|
|
||||||
SEP #$20
|
|
||||||
.done
|
|
||||||
RTL
|
|
||||||
|
|
||||||
DungeonIndicatorMap:
|
|
||||||
dw $0000
|
|
||||||
dw $0000
|
|
||||||
dw $0010
|
|
||||||
dw $0020
|
|
||||||
dw $0040
|
|
||||||
dw $0060
|
|
||||||
dw $0050
|
|
||||||
dw $00A0
|
|
||||||
dw $0070
|
|
||||||
dw $0090
|
|
||||||
dw $0030
|
|
||||||
dw $0080
|
|
||||||
dw $00B0
|
|
||||||
dw $00C0
|
|
||||||
.end
|
|
||||||
|
|
||||||
DungeonIndicatorGfx:
|
|
||||||
incbin "menu/dr_dungeon_indicators.2bpp"
|
|
||||||
.end
|
|
||||||
|
|
||||||
@@ -34,7 +34,6 @@ incsrc map_bg3.asm
|
|||||||
incsrc dungeon_switch.asm
|
incsrc dungeon_switch.asm
|
||||||
incsrc draw_loot.asm
|
incsrc draw_loot.asm
|
||||||
incsrc check_loot.asm
|
incsrc check_loot.asm
|
||||||
incsrc loot_hud.asm
|
|
||||||
incsrc blink_loot.asm
|
incsrc blink_loot.asm
|
||||||
incsrc data/doors_display.asm
|
incsrc data/doors_display.asm
|
||||||
incsrc data/spiral_stairs.asm
|
incsrc data/spiral_stairs.asm
|
||||||
|
|||||||
@@ -42,8 +42,6 @@ CheckSwitchMap:
|
|||||||
BRA .doors_done
|
BRA .doors_done
|
||||||
|
|
||||||
.change_dungeon
|
.change_dungeon
|
||||||
LDA.l MapSwapping
|
|
||||||
BEQ .doors_done
|
|
||||||
JSL DoorsMapChangeDungeon
|
JSL DoorsMapChangeDungeon
|
||||||
BRA .doors_done
|
BRA .doors_done
|
||||||
|
|
||||||
@@ -61,14 +59,10 @@ CheckSwitchMap:
|
|||||||
|
|
||||||
.not_fancy_door_map
|
.not_fancy_door_map
|
||||||
SEP #$20
|
SEP #$20
|
||||||
LDA.l MapSwapping
|
|
||||||
BEQ .no_swap
|
|
||||||
|
|
||||||
LDA.b $F6
|
LDA.b $F6
|
||||||
AND.b #$30
|
AND.b #$30
|
||||||
BNE .do_swap
|
BNE +
|
||||||
|
|
||||||
.no_swap
|
|
||||||
; what we wrote over
|
; what we wrote over
|
||||||
REP #$20
|
REP #$20
|
||||||
LDA.w DungeonMapFloorCountData, X
|
LDA.w DungeonMapFloorCountData, X
|
||||||
@@ -76,20 +70,15 @@ CheckSwitchMap:
|
|||||||
CLC : ADC.b $00
|
CLC : ADC.b $00
|
||||||
RTL
|
RTL
|
||||||
|
|
||||||
.do_swap
|
+ PHA
|
||||||
TXA
|
TXA
|
||||||
.try_next
|
|
||||||
ASL A
|
ASL A
|
||||||
TAX
|
TAX
|
||||||
LDA.b $F6
|
PLA
|
||||||
BIT.b #$20
|
BIT.b #$20
|
||||||
BNE +
|
BNE +
|
||||||
INX
|
INX
|
||||||
+
|
+ LDA.l DungeonMapData.prev, X
|
||||||
|
|
||||||
LDA.l DungeonMapData.prev, X
|
|
||||||
JSL IsValidDungeonToSwapTo
|
|
||||||
BCC .try_next
|
|
||||||
STA.w DungeonID
|
STA.w DungeonID
|
||||||
|
|
||||||
LDA.b #$04
|
LDA.b #$04
|
||||||
@@ -98,58 +87,6 @@ CheckSwitchMap:
|
|||||||
LDA.w #$0000
|
LDA.w #$0000
|
||||||
RTL
|
RTL
|
||||||
|
|
||||||
; in A = dungeon ID to check
|
|
||||||
; out C - CC = not valid, CS = valid
|
|
||||||
IsValidDungeonToSwapTo:
|
|
||||||
CMP.l CachedDungeonID ; dungeon we're in is always valid
|
|
||||||
BNE +
|
|
||||||
SEC
|
|
||||||
RTL
|
|
||||||
+
|
|
||||||
|
|
||||||
PHP
|
|
||||||
REP #$20
|
|
||||||
PHX : PHA
|
|
||||||
TAX
|
|
||||||
|
|
||||||
LDA.l MapSwapping
|
|
||||||
BIT.w #$0080
|
|
||||||
BNE .yes
|
|
||||||
|
|
||||||
BIT.w #$0001
|
|
||||||
BEQ +
|
|
||||||
; check visited flag
|
|
||||||
LDA.l SwapMasks, X
|
|
||||||
AND.l DungeonVisited
|
|
||||||
BNE .yes
|
|
||||||
+
|
|
||||||
|
|
||||||
LDA.l MapSwapping : BIT.w #$0002
|
|
||||||
BEQ +
|
|
||||||
; check map flag
|
|
||||||
LDA.l SwapMasks, X
|
|
||||||
AND.l MapField
|
|
||||||
BNE .yes
|
|
||||||
+
|
|
||||||
|
|
||||||
.no
|
|
||||||
PLA : PLX
|
|
||||||
PLP
|
|
||||||
CLC
|
|
||||||
RTL
|
|
||||||
|
|
||||||
.yes
|
|
||||||
PLA : PLX
|
|
||||||
PLP
|
|
||||||
SEC
|
|
||||||
RTL
|
|
||||||
|
|
||||||
SwapMasks:
|
|
||||||
dw $C000, $C000, $2000, $1000
|
|
||||||
dw $0800, $0400, $0200, $0100
|
|
||||||
dw $0080, $0040, $0020, $0010
|
|
||||||
dw $0008, $0004, $0002, $0001
|
|
||||||
|
|
||||||
DungeonMapSwitch_Submodule:
|
DungeonMapSwitch_Submodule:
|
||||||
JSL $80893D
|
JSL $80893D
|
||||||
JSL $80833F
|
JSL $80833F
|
||||||
@@ -287,32 +224,39 @@ DrawDungeonLabel:
|
|||||||
CLC : ADC.w #$0008
|
CLC : ADC.w #$0008
|
||||||
TAY
|
TAY
|
||||||
|
|
||||||
LDA.l MapSwapping
|
|
||||||
BEQ +
|
|
||||||
; L/R switch indicators
|
; L/R switch indicators
|
||||||
LDA.w #$E360
|
LDA.w #$E310
|
||||||
STA.w GFXStripes+$02, Y
|
STA.w GFXStripes+$02, Y
|
||||||
LDA.w #$E960
|
LDA.w #$E910
|
||||||
STA.w GFXStripes+$0A, Y
|
STA.w GFXStripes+$0A, Y
|
||||||
|
LDA.w #$E318
|
||||||
|
STA.w GFXStripes+$12, Y
|
||||||
|
LDA.w #$E918
|
||||||
|
STA.w GFXStripes+$1A, Y
|
||||||
|
|
||||||
LDA.w #$0300
|
LDA.w #$0300
|
||||||
STA.w GFXStripes+$04, Y
|
STA.w GFXStripes+$04, Y
|
||||||
STA.w GFXStripes+$0C, Y
|
STA.w GFXStripes+$0C, Y
|
||||||
|
STA.w GFXStripes+$14, Y
|
||||||
|
STA.w GFXStripes+$1C, Y
|
||||||
|
|
||||||
LDA.w #$65BF
|
LDA.w #$49AF
|
||||||
STA.w GFXStripes+$06, Y
|
STA.w GFXStripes+$06, Y
|
||||||
LDA.w #$25BD
|
STA.w GFXStripes+$16, Y
|
||||||
|
LDA.w #$099E
|
||||||
STA.w GFXStripes+$08, Y
|
STA.w GFXStripes+$08, Y
|
||||||
|
STA.w GFXStripes+$18, Y
|
||||||
|
|
||||||
LDA.w #$25BE
|
LDA.w #$099F
|
||||||
STA.w GFXStripes+$0E, Y
|
STA.w GFXStripes+$0E, Y
|
||||||
LDA.w #$25BF
|
STA.w GFXStripes+$1E, Y
|
||||||
|
LDA.w #$09AF
|
||||||
STA.w GFXStripes+$10, Y
|
STA.w GFXStripes+$10, Y
|
||||||
|
STA.w GFXStripes+$20, Y
|
||||||
|
|
||||||
TYA
|
TYA
|
||||||
CLC : ADC.w #$0010
|
CLC : ADC.w #$0020
|
||||||
TAY
|
TAY
|
||||||
+
|
|
||||||
|
|
||||||
LDA.l DRMode
|
LDA.l DRMode
|
||||||
BNE .doors
|
BNE .doors
|
||||||
|
|||||||
101
gk/loot_hud.asm
101
gk/loot_hud.asm
@@ -1,101 +0,0 @@
|
|||||||
pushpc
|
|
||||||
org $828C73
|
|
||||||
JSL EnterRoom
|
|
||||||
NOP
|
|
||||||
|
|
||||||
org $86C0AB
|
|
||||||
JSL CollectHeartPieceAndUpdate
|
|
||||||
|
|
||||||
org $86D1A8
|
|
||||||
JSL SetDeathFlagAndUpdate
|
|
||||||
|
|
||||||
pullpc
|
|
||||||
|
|
||||||
SetDeathFlagAndUpdate:
|
|
||||||
JSL UpdateLootHUD
|
|
||||||
JSL Sprite_ManuallySetDeathFlagUW
|
|
||||||
RTL
|
|
||||||
|
|
||||||
CollectHeartPieceAndUpdate:
|
|
||||||
JSL $85F018
|
|
||||||
JSL UpdateLootHUD
|
|
||||||
RTL
|
|
||||||
|
|
||||||
ClearLootHUD:
|
|
||||||
LDA.b GameMode
|
|
||||||
CMP.b #$07
|
|
||||||
BNE UpdateLootHUD
|
|
||||||
;
|
|
||||||
PHP
|
|
||||||
REP #$20
|
|
||||||
LDA.w #!BlankTile : STA.w EnemyDropIndicator
|
|
||||||
PLP
|
|
||||||
RTL
|
|
||||||
|
|
||||||
EnterRoom:
|
|
||||||
; what we wrote over
|
|
||||||
STZ.w $0200
|
|
||||||
STZ.b $B0
|
|
||||||
|
|
||||||
; fall into UpdateLootHUD
|
|
||||||
|
|
||||||
UpdateLootHUD:
|
|
||||||
PHP
|
|
||||||
REP #$30
|
|
||||||
PHX : PHY
|
|
||||||
SEP #$30
|
|
||||||
|
|
||||||
LDA.l HudItems_enabled : BEQ .setting_off
|
|
||||||
LDA.b IndoorsFlag : BEQ .done
|
|
||||||
|
|
||||||
REP #$30
|
|
||||||
LDA.b $00 : PHA
|
|
||||||
LDA.b $02 : PHA
|
|
||||||
LDA.b $04 : PHA
|
|
||||||
LDA.b $06 : PHA
|
|
||||||
LDA.b $08 : PHA
|
|
||||||
LDA.b $0E : PHA
|
|
||||||
|
|
||||||
; if if door rando, check for section of supertile
|
|
||||||
LDA.l DRMode
|
|
||||||
BNE +
|
|
||||||
|
|
||||||
; if not in door rando, check for section of supertile if we're not in a dungeon
|
|
||||||
LDA.w DungeonID
|
|
||||||
AND.w #$00FF
|
|
||||||
CMP.w #$00FF
|
|
||||||
BEQ +
|
|
||||||
|
|
||||||
; just load the room id, we don't care about sections
|
|
||||||
LDA.b RoomIndex
|
|
||||||
BRA .check
|
|
||||||
|
|
||||||
+ ; figure out section before checking
|
|
||||||
JSL DetectLinksSection
|
|
||||||
INC A
|
|
||||||
XBA
|
|
||||||
ASL A : ASL A : ASL A : ASL A
|
|
||||||
ORA.b RoomIndex
|
|
||||||
.check
|
|
||||||
JSL CheckHudLoot
|
|
||||||
|
|
||||||
ASL A : TAX
|
|
||||||
LDA.l HUDLootTypeIcons, X
|
|
||||||
STA.w EnemyDropIndicator
|
|
||||||
|
|
||||||
PLA : STA.b $0E
|
|
||||||
PLA : STA.b $08
|
|
||||||
PLA : STA.b $06
|
|
||||||
PLA : STA.b $04
|
|
||||||
PLA : STA.b $02
|
|
||||||
PLA : STA.b $00
|
|
||||||
BRA .done
|
|
||||||
|
|
||||||
.setting_off
|
|
||||||
JSL SetupEnemyDropIndicator
|
|
||||||
|
|
||||||
.done
|
|
||||||
REP #$30
|
|
||||||
PLY : PLX
|
|
||||||
PLP
|
|
||||||
RTL
|
|
||||||
@@ -1,31 +0,0 @@
|
|||||||
CheckOrangePotion:
|
|
||||||
LDA.l BottleContents, X
|
|
||||||
CMP.b #$01
|
|
||||||
BEQ .orange
|
|
||||||
|
|
||||||
; return to vanilla behavior
|
|
||||||
CMP.b #$00
|
|
||||||
RTL
|
|
||||||
|
|
||||||
.orange
|
|
||||||
LDA.l InfiniteMagic
|
|
||||||
BNE .nope
|
|
||||||
|
|
||||||
LDA.b #$02
|
|
||||||
STA.l BottleContents, X
|
|
||||||
|
|
||||||
STZ.w $0301
|
|
||||||
|
|
||||||
LDA.b #$01
|
|
||||||
STA.l InfiniteMagic
|
|
||||||
|
|
||||||
JSL RebuildHUD_update_long
|
|
||||||
LDA.b #$00
|
|
||||||
RTL
|
|
||||||
|
|
||||||
.nope
|
|
||||||
JSL Sound_SetSfxPanWithPlayerCoords
|
|
||||||
ORA.b #$3C
|
|
||||||
STA.w SFX2
|
|
||||||
LDA.b #$00
|
|
||||||
RTL
|
|
||||||
130
gk/settings.asm
130
gk/settings.asm
@@ -52,10 +52,10 @@ dw $2DCB, $6DCB, $ADCB, $EDCB ; 01 - unknown - dot
|
|||||||
dw $29EB, $69EB, $29FB, $69FB ; 02 - junk - pot
|
dw $29EB, $69EB, $29FB, $69FB ; 02 - junk - pot
|
||||||
dw $29CA, $69CA, $29DA, $29DB ; 03 - small key
|
dw $29CA, $69CA, $29DA, $29DB ; 03 - small key
|
||||||
dw $29E9, $69E9, $29F9, $69F9 ; 04 - triforce piece
|
dw $29E9, $69E9, $29F9, $69F9 ; 04 - triforce piece
|
||||||
dw $29DD, $69DD, $A9DD, $E9DD ; 05 - health - plus
|
dw $29DD, $69DD, $A9DD, $E9DD ; 05 - safety - plus
|
||||||
dw $29EC, $69EC, $29FC, $69FC ; 06 - less important item - small chest
|
dw $29EC, $69EC, $29FC, $69FC ; 06 - less important item - small chest
|
||||||
dw $29E8, $69E8, $29F8, $69F8 ; 07 - compass
|
dw $29CE, $29CF, $29DE, $29DF ; 07 - map
|
||||||
dw $29CE, $29CF, $29DE, $29DF ; 08 - map
|
dw $29E8, $69E8, $29F8, $69F8 ; 08 - compass
|
||||||
dw $29CA, $69CA, $29DA, $29DB ; 09 - small key
|
dw $29CA, $69CA, $29DA, $29DB ; 09 - small key
|
||||||
dw $29C8, $69C8, $29D8, $29D9 ; 0A - big key
|
dw $29C8, $69C8, $29D8, $29D9 ; 0A - big key
|
||||||
dw $29ED, $69ED, $29FD, $69FD ; 0B - important inventory item - big chest
|
dw $29ED, $69ED, $29FD, $69FD ; 0B - important inventory item - big chest
|
||||||
@@ -73,32 +73,29 @@ warnpc $B9FA00
|
|||||||
org $B9FA00
|
org $B9FA00
|
||||||
; Room ID mappings to bit to check for presence and address of item drop
|
; Room ID mappings to bit to check for presence and address of item drop
|
||||||
MiscLocations:
|
MiscLocations:
|
||||||
dw $10C8 : db $04 : dl HeartContainer_ArmosKnights
|
dw $00C8 : db $04 : dl HeartContainer_ArmosKnights
|
||||||
dw $1033 : db $04 : dl HeartContainer_Lanmolas
|
dw $0033 : db $04 : dl HeartContainer_Lanmolas
|
||||||
dw $1007 : db $04 : dl HeartContainer_Moldorm
|
dw $0007 : db $04 : dl HeartContainer_Moldorm
|
||||||
|
|
||||||
dw $105A : db $04 : dl HeartContainer_HelmasaurKing
|
dw $005A : db $04 : dl HeartContainer_HelmasaurKing
|
||||||
dw $1006 : db $04 : dl HeartContainer_Arrghus
|
dw $0006 : db $04 : dl HeartContainer_Arrghus
|
||||||
dw $1029 : db $04 : dl HeartContainer_Mothula
|
dw $0029 : db $04 : dl HeartContainer_Mothula
|
||||||
dw $10AC : db $04 : dl HeartContainer_Blind
|
dw $00AC : db $04 : dl HeartContainer_Blind
|
||||||
dw $10DE : db $04 : dl HeartContainer_Kholdstare
|
dw $00DE : db $04 : dl HeartContainer_Kholdstare
|
||||||
dw $1090 : db $04 : dl HeartContainer_Vitreous
|
dw $0090 : db $04 : dl HeartContainer_Vitreous
|
||||||
dw $10A4 : db $04 : dl HeartContainer_Trinexx
|
dw $00A4 : db $04 : dl HeartContainer_Trinexx
|
||||||
|
|
||||||
dw $1073 : db $05 : dl BonkKey_Desert ; torch
|
dw $0073 : db $05 : dl BonkKey_Desert ; torch
|
||||||
dw $108C : db $05 : dl BonkKey_GTower ; torch
|
dw $008C : db $05 : dl BonkKey_GTower ; torch
|
||||||
dw $1087 : db $05 : dl StandingKey_Hera
|
dw $0087 : db $05 : dl StandingKey_Hera
|
||||||
|
|
||||||
dw $10E1 : db $06 : dl HeartPiece_Forest_Thieves
|
|
||||||
dw $10E2 : db $06 : dl HeartPiece_Lumberjack_Tree
|
|
||||||
dw $10EA : db $05 : dl HeartPiece_Spectacle_Cave
|
|
||||||
dw $111B : db $06 : dl HeartPiece_Graveyard_Warp
|
|
||||||
dw $211B : db $05 : dl HeartPiece_Circle_Bushes
|
|
||||||
dw $111E : db $05 : dl RupeeNPC_NortheastDarkSwampCave
|
|
||||||
dw $1123 : db $05 : dl RupeeNPC_MoldormCave
|
|
||||||
dw $1126 : db $06 : dl HeartPiece_Mire_Warp
|
|
||||||
dw $1127 : db $05 : dl HeartPiece_Smith_Pegs
|
|
||||||
|
|
||||||
|
dw $FFFF : db $FF : dl $FFFFFF ; Placeholders
|
||||||
|
dw $FFFF : db $FF : dl $FFFFFF
|
||||||
|
dw $FFFF : db $FF : dl $FFFFFF ; Aga 1? ($0020)
|
||||||
|
dw $FFFF : db $FF : dl $FFFFFF ; Ice Armos? ($001C)
|
||||||
|
dw $FFFF : db $FF : dl $FFFFFF ; Lanmolas 2? ($0033)
|
||||||
|
dw $FFFF : db $FF : dl $FFFFFF ; Moldorm 2? ($004D)
|
||||||
|
dw $FFFF : db $FF : dl $FFFFFF ; Aga 2? ($000D)
|
||||||
dw $FFFF
|
dw $FFFF
|
||||||
|
|
||||||
warnpc $B9FA9A
|
warnpc $B9FA9A
|
||||||
@@ -131,7 +128,7 @@ pad $B9FB00
|
|||||||
|
|
||||||
; $B9FB00
|
; $B9FB00
|
||||||
DungeonLabels:
|
DungeonLabels:
|
||||||
dw $25A4, $2579 ; Sewers
|
dw $2550, $2579 ; Sewers
|
||||||
dw $2564, $255F ; Hyrule Castle
|
dw $2564, $255F ; Hyrule Castle
|
||||||
dw $2561, $256C ; Eastern Palace
|
dw $2561, $256C ; Eastern Palace
|
||||||
dw $2560, $256C ; Desert Palace
|
dw $2560, $256C ; Desert Palace
|
||||||
@@ -149,44 +146,6 @@ dw $25A4, $25A4 ; Reserved
|
|||||||
dw $25A4, $25A4 ; Reserved
|
dw $25A4, $25A4 ; Reserved
|
||||||
|
|
||||||
; $B9FB40
|
; $B9FB40
|
||||||
HUDLootTypeIcons:
|
|
||||||
dw $287F ; 00 - nothing
|
|
||||||
dw $295C ; 01 - unknown - dot
|
|
||||||
dw $2954 ; 02 - junk - pot
|
|
||||||
dw $2950 ; 03 - small key
|
|
||||||
dw $2952 ; 04 - triforce piece
|
|
||||||
dw $2955 ; 05 - health - plus
|
|
||||||
dw $2953 ; 06 - less important item - small chest
|
|
||||||
dw $2D56 ; 07 - compass
|
|
||||||
dw $2957 ; 08 - map
|
|
||||||
dw $2950 ; 09 - small key
|
|
||||||
dw $2951 ; 0A - big key
|
|
||||||
dw $295A ; 0B - important inventory item - big chest
|
|
||||||
dw $2D58 ; 0C - pendant
|
|
||||||
dw $2D59 ; 0D - crystal
|
|
||||||
dw $2952 ; 0E - triforce piece
|
|
||||||
dw $295B ; 0F - triforce
|
|
||||||
|
|
||||||
; $B9FB60
|
|
||||||
NpcItems:
|
|
||||||
dw $10E3 : dl $7EF411 : db $80 ; Magic Bat
|
|
||||||
dw $1102 : dl $7EF410 : db $04 ; Sick Kid
|
|
||||||
dw $1105 : dl $7EF410 : db $10 ; Sahasrahla
|
|
||||||
dw $1109 : dl $7EF411 : db $20 ; Potion Shop
|
|
||||||
dw $1121 : dl $7EF411 : db $04 ; Blacksmith
|
|
||||||
dw $FFFF
|
|
||||||
|
|
||||||
warnpc $B9FBA0
|
|
||||||
padbyte $FF
|
|
||||||
pad $B9FBA0
|
|
||||||
|
|
||||||
; $B9FBA0
|
|
||||||
; Currently these two are hard-coded checks
|
|
||||||
; but maybe that will change if more show up someday?
|
|
||||||
MiscLocations2:
|
|
||||||
dw $1055 : dw $7EF3C6 : db $01 : dl UncleItem
|
|
||||||
dw $2107 : dw $7EF410 : db $80 : dl LibraryItem
|
|
||||||
dw $FFFF
|
|
||||||
|
|
||||||
warnpc $B9FE00
|
warnpc $B9FE00
|
||||||
org $B9FE00
|
org $B9FE00
|
||||||
@@ -220,53 +179,30 @@ warnpc $B9FF08
|
|||||||
org $B9FF08
|
org $B9FF08
|
||||||
; $00 - do not show anything
|
; $00 - do not show anything
|
||||||
; $01 - show presence of unobtained items
|
; $01 - show presence of unobtained items
|
||||||
; $02 - show compass if presence, otherwise presence of unobtained items
|
; $02 - show category of item
|
||||||
; $03 - show category of item
|
ShowItems:
|
||||||
MapItems:
|
|
||||||
.default
|
.default
|
||||||
db $00
|
db $00
|
||||||
.have_map
|
.have_map
|
||||||
db $00
|
db $00
|
||||||
.have_compass
|
.have_compass
|
||||||
db $03
|
|
||||||
.visited_tile
|
|
||||||
db $02
|
db $02
|
||||||
.reserved
|
.visited_tile
|
||||||
skip 3
|
|
||||||
.enabled
|
|
||||||
db $01
|
db $01
|
||||||
|
.reserved
|
||||||
|
skip 4
|
||||||
warnpc $B9FF10
|
warnpc $B9FF10
|
||||||
|
|
||||||
org $B9FF10
|
org $B9FF10
|
||||||
HudItems:
|
; ---P bepc
|
||||||
.cave
|
|
||||||
db $00
|
|
||||||
.default_dungeon
|
|
||||||
db $00
|
|
||||||
.have_map
|
|
||||||
db $01
|
|
||||||
.have_compass
|
|
||||||
db $03
|
|
||||||
.reserved
|
|
||||||
skip 3
|
|
||||||
.enabled
|
|
||||||
db $01
|
|
||||||
warnpc $B9FF18
|
|
||||||
|
|
||||||
org $B9FF20
|
|
||||||
; ---P sepc
|
|
||||||
; P - dungeon prizes
|
; P - dungeon prizes
|
||||||
; s - standing items (plus torches in GT and desert and bosses)
|
; b - bosses (and torches in GT and desert, plus hera basement standing item)
|
||||||
; e - enemy drops
|
; e - enemy drops
|
||||||
; p - pots
|
; p - pots
|
||||||
; c - chests
|
; c - chests
|
||||||
ItemSources:
|
ItemSources:
|
||||||
db $09
|
db $09
|
||||||
|
|
||||||
; B9FF21
|
; $B9FF11
|
||||||
; a--- --mv
|
AlwaysShowCompass:
|
||||||
; a - always
|
|
||||||
; m - have map
|
|
||||||
; v - have visited dungeon
|
|
||||||
MapSwapping:
|
|
||||||
db $01
|
db $01
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
DamageClassCalc:
|
DamageClassCalc:
|
||||||
PHA
|
PHA
|
||||||
LDA.l GanonVulnerabilityItem : AND.b #$7F : BEQ +
|
LDA.l GanonVulnerabilityItem : BEQ +
|
||||||
LDA.w SpriteTypeTable, X : CMP.b #$D7 : BNE +
|
LDA.w SpriteTypeTable, X : CMP.b #$D7 : BNE +
|
||||||
PLA
|
PLA
|
||||||
JSL Ganon_CheckAncillaVulnerability
|
JSL Ganon_CheckAncillaVulnerability
|
||||||
|
|||||||
@@ -4,14 +4,12 @@ Ganon_CheckAncillaVulnerability:
|
|||||||
PLA
|
PLA
|
||||||
PHX : PHA
|
PHX : PHA
|
||||||
LDA.l GanonVulnerabilityItem
|
LDA.l GanonVulnerabilityItem
|
||||||
BVS .no_weakness
|
BMI .no_weakness
|
||||||
AND.b #$7F
|
|
||||||
TAX : PLA
|
TAX : PLA
|
||||||
CMP.l Ganon_CheckByAncilla, X : BNE +
|
CMP.l Ganon_CheckByAncilla, X : BNE +
|
||||||
PLX : BRA .vulnerable
|
PLX : BRA .vulnerable
|
||||||
+ PLX : PHA
|
+ PLX : PHA
|
||||||
LDA.l GanonVulnerabilityItem
|
LDA.l GanonVulnerabilityItem
|
||||||
AND.b #$7F
|
|
||||||
BEQ .silver_arrows
|
BEQ .silver_arrows
|
||||||
CMP.b #$01 : BEQ .silver_arrows
|
CMP.b #$01 : BEQ .silver_arrows
|
||||||
CMP.b #$11 : BEQ .somaria
|
CMP.b #$11 : BEQ .somaria
|
||||||
@@ -36,7 +34,6 @@ Ganon_CheckAncillaVulnerability:
|
|||||||
.vulnerable
|
.vulnerable
|
||||||
PHX
|
PHX
|
||||||
LDA.l GanonVulnerabilityItem
|
LDA.l GanonVulnerabilityItem
|
||||||
AND.b #$7F
|
|
||||||
TAX
|
TAX
|
||||||
LDA.l Ganon_IFrameDuration, X
|
LDA.l Ganon_IFrameDuration, X
|
||||||
PLX
|
PLX
|
||||||
@@ -55,7 +52,7 @@ Ganon_CheckAncillaVulnerability:
|
|||||||
RTL
|
RTL
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
Ganon_CheckPowderVulnerability:
|
Ganon_CheckPowderVulnerability:
|
||||||
LDA.l GanonVulnerabilityItem : AND.b #$7F : CMP.b #$05 : BNE .normal
|
LDA.l GanonVulnerabilityItem : CMP.b #$05 : BNE .normal
|
||||||
LDA.w SpriteTypeTable, X : CMP.b #$D7 : BNE .normal
|
LDA.w SpriteTypeTable, X : CMP.b #$D7 : BNE .normal
|
||||||
LDA.w $0EE0, X : BNE .normal ; ganon has i-frames
|
LDA.w $0EE0, X : BNE .normal ; ganon has i-frames
|
||||||
LDA.l Ganon_IFrameDuration+$05
|
LDA.l Ganon_IFrameDuration+$05
|
||||||
@@ -72,7 +69,7 @@ Ganon_CheckPowderVulnerability:
|
|||||||
Ganon_CheckBeeVulnerability:
|
Ganon_CheckBeeVulnerability:
|
||||||
; X is bee sprite index
|
; X is bee sprite index
|
||||||
; Y is target sprite index
|
; Y is target sprite index
|
||||||
LDA.l GanonVulnerabilityItem : AND.b #$7F : CMP.b #$10 : BNE .normal
|
LDA.l GanonVulnerabilityItem : CMP.b #$10 : BNE .normal
|
||||||
LDA.w SpriteTypeTable, Y : CMP.b #$D7 : BNE .normal
|
LDA.w SpriteTypeTable, Y : CMP.b #$D7 : BNE .normal
|
||||||
LDA.w $0EE0, Y : BNE .normal ; ganon has i-frames
|
LDA.w $0EE0, Y : BNE .normal ; ganon has i-frames
|
||||||
LDA.l Ganon_IFrameDuration+$10
|
LDA.l Ganon_IFrameDuration+$10
|
||||||
@@ -91,14 +88,14 @@ Ganon_CheckInvincible:
|
|||||||
LDA.w $04C5 : CMP.b #$02 : BEQ .not_transparent
|
LDA.w $04C5 : CMP.b #$02 : BEQ .not_transparent
|
||||||
LDA.w SpriteTypeTable, X : CMP.b #$D7 : BNE .transparent ; non-stunned ganon
|
LDA.w SpriteTypeTable, X : CMP.b #$D7 : BNE .transparent ; non-stunned ganon
|
||||||
LDA.w UseY1 : AND.b #$0A : BEQ .transparent ; normal behavior if not hammering
|
LDA.w UseY1 : AND.b #$0A : BEQ .transparent ; normal behavior if not hammering
|
||||||
LDA.l GanonVulnerabilityItem : AND.b #$7F : CMP.b #$0C : BNE .transparent
|
LDA.l GanonVulnerabilityItem : CMP.b #$0C : BNE .transparent
|
||||||
.not_transparent
|
.not_transparent
|
||||||
LDA.b #$00 : RTL
|
LDA.b #$00 : RTL
|
||||||
.transparent
|
.transparent
|
||||||
LDA.b #$01 : RTL
|
LDA.b #$01 : RTL
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
Ganon_CheckHammerVulnerability:
|
Ganon_CheckHammerVulnerability:
|
||||||
LDA.l GanonVulnerabilityItem : AND.b #$7F : CMP.b #$0C : BNE .normal
|
LDA.l GanonVulnerabilityItem : CMP.b #$0C : BNE .normal
|
||||||
LDA.w SpriteTypeTable, X : CMP.b #$D7 : BNE .normal
|
LDA.w SpriteTypeTable, X : CMP.b #$D7 : BNE .normal
|
||||||
LDA.w $0EE0, X : BNE .normal ; ganon has i-frames
|
LDA.w $0EE0, X : BNE .normal ; ganon has i-frames
|
||||||
LDA.l Ganon_IFrameDuration+$0C
|
LDA.l Ganon_IFrameDuration+$0C
|
||||||
@@ -111,7 +108,7 @@ Ganon_CheckHammerVulnerability:
|
|||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
CheckBeeBoss:
|
CheckBeeBoss:
|
||||||
; Y is sprite index
|
; Y is sprite index
|
||||||
LDA.l GanonVulnerabilityItem : AND.b #$7F : CMP.b #$10 : BNE .normal
|
LDA.l GanonVulnerabilityItem : CMP.b #$10 : BNE .normal
|
||||||
LDA.w SpriteTypeTable, Y : CMP.b #$D7 : BNE .normal
|
LDA.w SpriteTypeTable, Y : CMP.b #$D7 : BNE .normal
|
||||||
LDA.b #$00 : RTL
|
LDA.b #$00 : RTL
|
||||||
.normal
|
.normal
|
||||||
|
|||||||
@@ -13,8 +13,7 @@ GKRomVersion:
|
|||||||
; $01 = Dungeon Maps
|
; $01 = Dungeon Maps
|
||||||
; .., $01 = Dark rooms don't show on map from visition
|
; .., $01 = Dark rooms don't show on map from visition
|
||||||
; .., $02 = OW Fog and Grid modes
|
; .., $02 = OW Fog and Grid modes
|
||||||
; .., $03 = Loot level of current supertile in HUD
|
db $01, $02, $00
|
||||||
db $01, $03, $00
|
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
|
|
||||||
;================================================================================
|
;================================================================================
|
||||||
|
|||||||
@@ -70,7 +70,7 @@ GetAgahnimLightning:
|
|||||||
;1 = Forbid
|
;1 = Forbid
|
||||||
AllowJoypadInput:
|
AllowJoypadInput:
|
||||||
LDA.l PermitSQFromBosses : BEQ .fullCheck
|
LDA.l PermitSQFromBosses : BEQ .fullCheck
|
||||||
LDA.w RoomItemsTaken : AND.b #$80 : BEQ .fullCheck
|
JSL CheckBossDropTouched : BEQ .fullCheck
|
||||||
LDA.w MedallionFlag : ORA.w CutsceneFlag ; we have heart container, do short check
|
LDA.w MedallionFlag : ORA.w CutsceneFlag ; we have heart container, do short check
|
||||||
RTL
|
RTL
|
||||||
.fullCheck
|
.fullCheck
|
||||||
|
|||||||
@@ -1,8 +1,5 @@
|
|||||||
GoalItemGanonCheck:
|
GoalItemGanonCheck:
|
||||||
LDA.w SpriteTypeTable, X : CMP.b #$D6 : BNE .success ; skip if not ganon
|
LDA.w SpriteTypeTable, X : CMP.b #$D6 : BNE .success ; skip if not ganon
|
||||||
LDA.l GanonVulnerabilityItem : BPL +
|
|
||||||
LDA.w SpriteActivity, X : CMP.b #$12 : BEQ .fail
|
|
||||||
+
|
|
||||||
LDA.b #$01 : JSL CheckConditionPass
|
LDA.b #$01 : JSL CheckConditionPass
|
||||||
BCS .success
|
BCS .success
|
||||||
|
|
||||||
|
|||||||
@@ -2,13 +2,20 @@
|
|||||||
; Randomize Half Magic Bat
|
; Randomize Half Magic Bat
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
GetMagicBatItem:
|
GetMagicBatItem:
|
||||||
JSL ItemSet_MagicBat
|
|
||||||
%GetPossiblyEncryptedItem(MagicBatItem, SpriteItemValues)
|
%GetPossiblyEncryptedItem(MagicBatItem, SpriteItemValues)
|
||||||
CMP.b #$FF : BEQ .normalLogic
|
CMP.b #$FF : BEQ .normalLogic
|
||||||
TAY
|
TAY
|
||||||
PHA : LDA.l MagicBatItem_Player : STA.l !MULTIWORLD_ITEM_PLAYER_ID : PLA
|
PHA
|
||||||
|
JSL ShieldCheck
|
||||||
|
BCC .have_shield
|
||||||
|
LDA.l MagicBatItem_Player : STA.l !MULTIWORLD_ITEM_PLAYER_ID
|
||||||
|
JSL ItemSet_MagicBat
|
||||||
|
PLA
|
||||||
STZ.b ItemReceiptMethod ; 0 = Receiving item from an NPC or message
|
STZ.b ItemReceiptMethod ; 0 = Receiving item from an NPC or message
|
||||||
JML Link_ReceiveItem
|
JML Link_ReceiveItem
|
||||||
|
.have_shield
|
||||||
|
PLA
|
||||||
|
RTL
|
||||||
.normalLogic
|
.normalLogic
|
||||||
LDA.l HalfMagic
|
LDA.l HalfMagic
|
||||||
STA.l MagicConsumption
|
STA.l MagicConsumption
|
||||||
|
|||||||
@@ -5,8 +5,17 @@ HeartPieceGet:
|
|||||||
PHX : PHY
|
PHX : PHY
|
||||||
LDA.w SprItemMWPlayer, X : STA.l !MULTIWORLD_SPRITEITEM_PLAYER_ID
|
LDA.w SprItemMWPlayer, X : STA.l !MULTIWORLD_SPRITEITEM_PLAYER_ID
|
||||||
LDY.w SprSourceItemId, X
|
LDY.w SprSourceItemId, X
|
||||||
|
JSL HeartGet
|
||||||
|
BCC +
|
||||||
JSL MaybeMarkDigSpotCollected
|
JSL MaybeMarkDigSpotCollected
|
||||||
.skipLoad
|
+
|
||||||
|
PLY : PLX
|
||||||
|
RTL
|
||||||
|
;--------------------------------------------------------------------------------
|
||||||
|
HeartGet:
|
||||||
|
JSL ShieldCheck
|
||||||
|
BCC .skip
|
||||||
|
|
||||||
LDA.w SprItemMWPlayer, X : STA.l !MULTIWORLD_ITEM_PLAYER_ID
|
LDA.w SprItemMWPlayer, X : STA.l !MULTIWORLD_ITEM_PLAYER_ID
|
||||||
CPY.b #$26 : BNE .not_heart ; don't add a 1/4 heart if it's not a heart piece
|
CPY.b #$26 : BNE .not_heart ; don't add a 1/4 heart if it's not a heart piece
|
||||||
CMP.b #$00 : BNE .not_heart
|
CMP.b #$00 : BNE .not_heart
|
||||||
@@ -16,15 +25,27 @@ HeartPieceGet:
|
|||||||
STZ.w ItemReceiptMethod ; 0 = Receiving item from an NPC or message
|
STZ.w ItemReceiptMethod ; 0 = Receiving item from an NPC or message
|
||||||
JSL Link_ReceiveItem
|
JSL Link_ReceiveItem
|
||||||
JSL MaybeUnlockTabletAnimation
|
JSL MaybeUnlockTabletAnimation
|
||||||
|
SEC
|
||||||
PLY : PLX
|
RTL
|
||||||
RTL
|
.skip
|
||||||
|
JSL MaybeFreeLinkFromTablet
|
||||||
|
CLC
|
||||||
|
RTL
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
HeartContainerGet:
|
HeartContainerGet:
|
||||||
PHX : PHY
|
PHX : PHY
|
||||||
JSL IncrementBossSword
|
JSL IncrementBossSword
|
||||||
LDY.w SprSourceItemId, X
|
LDY.w SprSourceItemId, X
|
||||||
BRA HeartPieceGet_skipLoad
|
JSL HeartGet
|
||||||
|
PLY : PLX
|
||||||
|
BCC +
|
||||||
|
LDA.w RoomItemsTaken
|
||||||
|
ORA.b #$80
|
||||||
|
STA.w RoomItemsTaken
|
||||||
|
+
|
||||||
|
LDA.b #$01
|
||||||
|
STA.l BossDropTouched
|
||||||
|
RTL
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
DrawHeartPieceGFX:
|
DrawHeartPieceGFX:
|
||||||
PHP
|
PHP
|
||||||
|
|||||||
108
hooks.asm
108
hooks.asm
@@ -997,15 +997,6 @@ LDA.w BottleListExpanded, X
|
|||||||
|
|
||||||
org $89895C ; 4895C - ancilla_init.asm:1344 (LDA PotionList, X)
|
org $89895C ; 4895C - ancilla_init.asm:1344 (LDA PotionList, X)
|
||||||
LDA.w PotionListExpanded, X
|
LDA.w PotionListExpanded, X
|
||||||
|
|
||||||
org $898946
|
|
||||||
CMP.b #$00 : BNE + : skip 9 : +
|
|
||||||
|
|
||||||
org $89895A
|
|
||||||
LDX.b #$06
|
|
||||||
|
|
||||||
org $89896A
|
|
||||||
ADC.b #$01
|
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
org $86D1EB ; 351EB - sprite_absorbable.asm:364 (STA $7EF375) ; bugbug commented out until i figure out why it doesn't work
|
org $86D1EB ; 351EB - sprite_absorbable.asm:364 (STA $7EF375) ; bugbug commented out until i figure out why it doesn't work
|
||||||
JSL HandleBombAbsorbtion
|
JSL HandleBombAbsorbtion
|
||||||
@@ -1038,7 +1029,6 @@ JSL RefillHealth
|
|||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
org $80F922 ; <- 7922 - Bank00.asm:8543 - (JSL HUD.RefillMagicPower : BCC .beta)
|
org $80F922 ; <- 7922 - Bank00.asm:8543 - (JSL HUD.RefillMagicPower : BCC .beta)
|
||||||
JSL RefillMagic
|
JSL RefillMagic
|
||||||
;--------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
;================================================================================
|
;================================================================================
|
||||||
; Early Bottle Fix
|
; Early Bottle Fix
|
||||||
@@ -1063,8 +1053,12 @@ Overworld_Entrance_BRANCH_EPSILON: ; go here to lock doors
|
|||||||
org $81C50D : JSL CheckDungeonWorld
|
org $81C50D : JSL CheckDungeonWorld
|
||||||
org $81C517 : JSL CheckDungeonCompletion
|
org $81C517 : JSL CheckDungeonCompletion
|
||||||
org $81C523 : JSL CheckDungeonCompletion
|
org $81C523 : JSL CheckDungeonCompletion
|
||||||
org $81C710 : JSL CheckSpawnPrize
|
org $81C709 : JSL CheckBossDropTouched : NOP
|
||||||
BCS RoomTag_GetHeartForPrize_spawn_prize : BRA RoomTag_GetHeartForPrize_delete_tag
|
org $81C710
|
||||||
|
JSL CheckSpawnPrize
|
||||||
|
BCS RoomTag_GetHeartForPrize_spawn_prize
|
||||||
|
BRA RoomTag_GetHeartForPrize_delete_tag
|
||||||
|
warnpc $81C731
|
||||||
org $81C742 : JSL SpawnDungeonPrize : PLA : RTS
|
org $81C742 : JSL SpawnDungeonPrize : PLA : RTS
|
||||||
org $8799EA : JML SetItemPose
|
org $8799EA : JML SetItemPose
|
||||||
org $88C415 : JSL PendantMusicCheck
|
org $88C415 : JSL PendantMusicCheck
|
||||||
@@ -1076,6 +1070,7 @@ org $88C622 : BCC ItemReceipt_Animate_continue
|
|||||||
org $88C6BA : JSL CheckPoseItemCoordinates
|
org $88C6BA : JSL CheckPoseItemCoordinates
|
||||||
org $88C6C3 : JSL PrepPrizeVRAMHigh
|
org $88C6C3 : JSL PrepPrizeVRAMHigh
|
||||||
org $88C6F4 : JSL PrepPrizeVRAMLow
|
org $88C6F4 : JSL PrepPrizeVRAMLow
|
||||||
|
org $88CAC4 : JSL CheckBossDropTouched : NOP
|
||||||
org $88CAD6 : JSL HandleDropSFX : NOP #2
|
org $88CAD6 : JSL HandleDropSFX : NOP #2
|
||||||
org $88CADC : BCC Ancilla29_MilestoneItemReceipt_skip_crystal_sfx
|
org $88CADC : BCC Ancilla29_MilestoneItemReceipt_skip_crystal_sfx
|
||||||
org $88CAE9 : JSL PrepPrizeTile
|
org $88CAE9 : JSL PrepPrizeTile
|
||||||
@@ -1127,8 +1122,7 @@ JSL CompareBombsToMax : NOP #11
|
|||||||
org $85FC7E ; <- 2FC7E - sprite_dash_item.asm : 118 (LDA $7EF36F : INC A : STA $7EF36F)
|
org $85FC7E ; <- 2FC7E - sprite_dash_item.asm : 118 (LDA $7EF36F : INC A : STA $7EF36F)
|
||||||
JSL GiveBonkItem : NOP #5
|
JSL GiveBonkItem : NOP #5
|
||||||
org $85FC97 ; <- 2FC97 - sprite_dash_item.asm : 126 (LDA.b #$2F : JSL Sound_SetSfx3PanLong)
|
org $85FC97 ; <- 2FC97 - sprite_dash_item.asm : 126 (LDA.b #$2F : JSL Sound_SetSfx3PanLong)
|
||||||
JSL UpdateLootHUD
|
NOP #6
|
||||||
NOP #2
|
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
org $868D39 ; <- 30D39 - sprite_prep.asm : 1435 - (LDA.b #$08 : STA $0F50, X)
|
org $868D39 ; <- 30D39 - sprite_prep.asm : 1435 - (LDA.b #$08 : STA $0F50, X)
|
||||||
JSL LoadBonkItemGFX
|
JSL LoadBonkItemGFX
|
||||||
@@ -1175,8 +1169,6 @@ ORA.w #$8000 : STA.w $007E, Y
|
|||||||
ORA.w #$4000 : STA.w $0084, Y
|
ORA.w #$4000 : STA.w $0084, Y
|
||||||
JSL AddYMarker : NOP #2
|
JSL AddYMarker : NOP #2
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
org $8DF779 ; <- 6F779 (not in disassembly) - mushroom bottle hud tile
|
|
||||||
dw $20D2, $60D2, $20E2, $202D ; (Orig: $2044, $2045, $2046, $2047)
|
|
||||||
org $8DF789+6 ; <- 6F789+6 (not in disassembly) - red bottle hud tile, lower right
|
org $8DF789+6 ; <- 6F789+6 (not in disassembly) - red bottle hud tile, lower right
|
||||||
dw $2413 ; (Orig: #$24E3)
|
dw $2413 ; (Orig: #$24E3)
|
||||||
org $8DF789+6+8 ; green bottle hud tile, lower right
|
org $8DF789+6+8 ; green bottle hud tile, lower right
|
||||||
@@ -1530,8 +1522,9 @@ JSL DrawHeartPiecesMenu : BRA DrawEquipment_in_a_dungeon
|
|||||||
;================================================================================
|
;================================================================================
|
||||||
; 300 Rupee NPC
|
; 300 Rupee NPC
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
org $9EF060 ; <- F7060 - sprite_shopkeeper.asm:242 (INC $0D80, X)
|
org $9EF058 ; <- F7060 - sprite_shopkeeper.asm:242 (INC $0D80, X)
|
||||||
JSL Set300RupeeNPCItem : NOP
|
JSL Set300RupeeNPCItem
|
||||||
|
BCS + : RTS : NOP #6 : +
|
||||||
|
|
||||||
;================================================================================
|
;================================================================================
|
||||||
; Tree Kid Fix
|
; Tree Kid Fix
|
||||||
@@ -1656,8 +1649,7 @@ JSL FixAga2Bunny : NOP
|
|||||||
; Open Mode Fixes
|
; Open Mode Fixes
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
org $85DF65 ; <- 2DF65 - sprite_uncle_and_priest.asm:994 - (LDA.b #$01 : STA $7EF3C5)
|
org $85DF65 ; <- 2DF65 - sprite_uncle_and_priest.asm:994 - (LDA.b #$01 : STA $7EF3C5)
|
||||||
JSL UpdateLootHUD
|
NOP #6
|
||||||
NOP #2
|
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
org $85EDDF ; <- 2EDDF - sprite_zelda.asm:398 - (LDA.b #$02 : STA $7EF3C5)
|
org $85EDDF ; <- 2EDDF - sprite_zelda.asm:398 - (LDA.b #$02 : STA $7EF3C5)
|
||||||
JSL EndRainState : NOP #2
|
JSL EndRainState : NOP #2
|
||||||
@@ -2019,7 +2011,7 @@ org $85EE53 ; <- 2EE53 - mushroom.asm : 22
|
|||||||
JSL ItemCheck_Mushroom : NOP #2
|
JSL ItemCheck_Mushroom : NOP #2
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
org $85EE8C ; <- 2EE8C - mushroom.asm : 69
|
org $85EE8C ; <- 2EE8C - mushroom.asm : 69
|
||||||
JSL ItemSet_Mushroom : NOP
|
JSL ItemSet_Mushroom : NOP #5
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
org $85F53E ; <- 2F53E - sprite_potion_shop.asm : 40
|
org $85F53E ; <- 2F53E - sprite_potion_shop.asm : 40
|
||||||
JSL ItemCheck_Powder : CMP.b #$20
|
JSL ItemCheck_Powder : CMP.b #$20
|
||||||
@@ -2033,8 +2025,15 @@ JSL ItemCheck_MagicBat : BEQ + : RTS : NOP : +
|
|||||||
;================================================================================
|
;================================================================================
|
||||||
org $86BD6C ; <- 33D6C - sprite_middle_aged_man.asm:143 (JSL Link_ReceiveItem)
|
org $86BD6C ; <- 33D6C - sprite_middle_aged_man.asm:143 (JSL Link_ReceiveItem)
|
||||||
JSL Multiworld_MiddleAgedMan_ReactToSecretKeepingResponse
|
JSL Multiworld_MiddleAgedMan_ReactToSecretKeepingResponse
|
||||||
|
BRA + : NOP #8 : +
|
||||||
|
;--------------------------------------------------------------------------------
|
||||||
|
org $86BE70 ; <- 33E72 - bank_06.asm:11877
|
||||||
|
BRA + : NOP #10 : +
|
||||||
|
|
||||||
org $86BE81 ; <- 33E81 - sprite_hobo.asm:150 (JSL Link_ReceiveItem)
|
org $86BE81 ; <- 33E81 - sprite_hobo.asm:150 (JSL Link_ReceiveItem)
|
||||||
JSL Multiworld_Hobo_GrantBottle
|
JSL Multiworld_Hobo_GrantBottle
|
||||||
|
BRA + : NOP #8 : +
|
||||||
|
;--------------------------------------------------------------------------------
|
||||||
org $8589B4 ; <- 289B4 ; sprite_master_sword.asm:183 (JSL Link_ReceiveItem)
|
org $8589B4 ; <- 289B4 ; sprite_master_sword.asm:183 (JSL Link_ReceiveItem)
|
||||||
JSL Multiworld_MasterSword_GrantToPlayer
|
JSL Multiworld_MasterSword_GrantToPlayer
|
||||||
;================================================================================
|
;================================================================================
|
||||||
@@ -2047,7 +2046,10 @@ org $85EF79 ; <- 2EF79 - sprite_heart_upgrades.asm:128 (JSL Sprite_PrepAndDrawSi
|
|||||||
JSL DrawHeartContainerGFX
|
JSL DrawHeartContainerGFX
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
org $85EFCE ; <- 2EFCE - sprite_heart_upgrades.asm:176 (JSL Link_ReceiveItem)
|
org $85EFCE ; <- 2EFCE - sprite_heart_upgrades.asm:176 (JSL Link_ReceiveItem)
|
||||||
JSL HeartContainerGet
|
JSL HeartContainerGet ; this also handles setting the boss-killed flag if appropriate
|
||||||
|
PLX
|
||||||
|
RTS
|
||||||
|
warnpc $85EFDC
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
org $8799B1 ; 399B1 - Bank07.asm:4063 (CPY.b #$3E : BNE .notHeartContainer)
|
org $8799B1 ; 399B1 - Bank07.asm:4063 (CPY.b #$3E : BNE .notHeartContainer)
|
||||||
@@ -2073,10 +2075,13 @@ JSL HeartPieceSpawnDelayFix
|
|||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
org $85F08A ; <- 2F08A - sprite_heart_upgrades.asm : 324 - (LDA $7EF36B : INC A : AND.b #$03 : STA $7EF36B : BNE .got_4_piecese) item determination
|
org $85F08A ; <- 2F08A - sprite_heart_upgrades.asm : 324 - (LDA $7EF36B : INC A : AND.b #$03 : STA $7EF36B : BNE .got_4_piecese) item determination
|
||||||
JSL HeartPieceGet
|
JSL HeartPieceGet
|
||||||
|
PHP
|
||||||
JSL DynamicDrawCleanup
|
JSL DynamicDrawCleanup
|
||||||
|
PLP : BCC +
|
||||||
JSL IsMedallion
|
JSL IsMedallion
|
||||||
BCS + : BRA Sprite_EB_HeartPiece_handle_flags : + ; Don't change OW flags if we're
|
BCS + : BRA Sprite_EB_HeartPiece_handle_flags : + ; Don't change OW flags if we're
|
||||||
STZ.w SpriteAITable, X : RTS ; getting a tablet item
|
STZ.w SpriteAITable, X : RTS ; getting a tablet item
|
||||||
|
warnpc $85F0C0
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
org $86C0B0 ; <- 340B0 - sprite prep
|
org $86C0B0 ; <- 340B0 - sprite prep
|
||||||
JSL HeartPieceSpritePrep
|
JSL HeartPieceSpritePrep
|
||||||
@@ -2772,23 +2777,6 @@ JSL MimicDirection
|
|||||||
org $828068
|
org $828068
|
||||||
JSL AdjustDefaultGraphics
|
JSL AdjustDefaultGraphics
|
||||||
|
|
||||||
;================================================================================
|
|
||||||
;--------------------------------------------------------------------------------
|
|
||||||
; Remove Overwriting HUD gfx on game over
|
|
||||||
;--------------------------------------------------------------------------------
|
|
||||||
org $809038
|
|
||||||
RTS
|
|
||||||
|
|
||||||
;================================================================================
|
|
||||||
;--------------------------------------------------------------------------------
|
|
||||||
; Dungeon Indicator VRAM overwrite
|
|
||||||
;--------------------------------------------------------------------------------
|
|
||||||
org $828190
|
|
||||||
JSL LoadDungeonIndicator
|
|
||||||
|
|
||||||
org $829AA2
|
|
||||||
JSL LoadDungeonIndicator
|
|
||||||
|
|
||||||
;================================================================================
|
;================================================================================
|
||||||
; Special Weapons Modes
|
; Special Weapons Modes
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
@@ -2860,9 +2848,43 @@ JSL CheckFluteInHUD
|
|||||||
NOP #3
|
NOP #3
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
|
||||||
;================================================================================
|
;================================================================================
|
||||||
; Orange Potion (Chateau Romani)
|
; Pikit Nonsense
|
||||||
;--------------------------------------------------------------------------------
|
|
||||||
org $87A15C ; bank_07.asm@6963 (LDA.l $7EF35C, X)
|
|
||||||
JSL CheckOrangePotion
|
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
|
org $81EC39
|
||||||
|
JSL SmallChest_ShieldCheck
|
||||||
|
BCC Dungeon_OpenKeyedObject_couldntFindChest+1
|
||||||
|
|
||||||
|
org $81EC17
|
||||||
|
JSL BigChest_ShieldCheck
|
||||||
|
BCC Dungeon_OpenKeyedObject_couldntFindChest
|
||||||
|
NOP #2
|
||||||
|
|
||||||
|
org $9E8D6F
|
||||||
|
JML PikitSteal
|
||||||
|
|
||||||
|
org $9E8CF2
|
||||||
|
JSL PikitDigest
|
||||||
|
NOP #2
|
||||||
|
|
||||||
|
org $879A52
|
||||||
|
JSL LinkSnoring
|
||||||
|
|
||||||
|
org $879AAD
|
||||||
|
JSL LinkAwaken
|
||||||
|
|
||||||
|
org $879A31
|
||||||
|
JSL TuckLink
|
||||||
|
NOP #2
|
||||||
|
|
||||||
|
org $80F950
|
||||||
|
NOP #2
|
||||||
|
|
||||||
|
org $81EEB3
|
||||||
|
JSL MaybeFlagVoOChestGamePrize
|
||||||
|
BCS ContinueVoOCheck
|
||||||
|
PLB : RTL
|
||||||
|
|
||||||
|
org $81EEC7
|
||||||
|
ContinueVoOCheck:
|
||||||
|
|||||||
@@ -114,14 +114,15 @@ StartingGenericKeys: skip 1 ; PC 0x18338B
|
|||||||
InitInventoryTracking: skip 2 ; PC 0x18338C \ Need to set bits here for silver arrows,
|
InitInventoryTracking: skip 2 ; PC 0x18338C \ Need to set bits here for silver arrows,
|
||||||
InitBowTracking: skip 2 ; PC 0x18338E / boomerangs, powder/mushroom, etc
|
InitBowTracking: skip 2 ; PC 0x18338E / boomerangs, powder/mushroom, etc
|
||||||
InitItemLimitCounts: skip 16 ; PC 0x183390
|
InitItemLimitCounts: skip 16 ; PC 0x183390
|
||||||
skip 34 ;
|
skip 32 ;
|
||||||
|
InitPikitItem: dw $0004 ;
|
||||||
InitFluteBitfield: db $00 ;
|
InitFluteBitfield: db $00 ;
|
||||||
InitSpecialWeaponLevel: db $00 ;
|
InitSpecialWeaponLevel: db $00 ;
|
||||||
InitItemOnB: db $00 ;
|
InitItemOnB: db $00 ;
|
||||||
InitProgressIndicator: db $02 ; PC 0x1833C5 - Set to $80 for instant post-aga with standard
|
InitProgressIndicator: db $00 ; PC 0x1833C5 - Set to $80 for instant post-aga with standard
|
||||||
InitProgressFlags: db $14 ; PC 0x1833C6 - Set to $00 for standard
|
InitProgressFlags: db $04 ; PC 0x1833C6 - Set to $00 for standard
|
||||||
InitMapIcons: skip 1 ; PC 0x1833C7
|
InitMapIcons: skip 1 ; PC 0x1833C7
|
||||||
InitStartingEntrance: db $01 ; PC 0x1833C8 - Set to $00 for standard
|
InitStartingEntrance: db $00 ; PC 0x1833C8 - Set to $00 for standard
|
||||||
InitNpcFlagsVanilla: skip 1 ; PC 0x1833C9
|
InitNpcFlagsVanilla: skip 1 ; PC 0x1833C9
|
||||||
InitCurrentWorld: skip 1 ; PC 0x1833CA
|
InitCurrentWorld: skip 1 ; PC 0x1833CA
|
||||||
skip 1 ; PC 0x1833CB
|
skip 1 ; PC 0x1833CB
|
||||||
|
|||||||
@@ -165,7 +165,6 @@ AddInventory:
|
|||||||
LDA.l !MULTIWORLD_RECEIVING_ITEM : BNE .done
|
LDA.l !MULTIWORLD_RECEIVING_ITEM : BNE .done
|
||||||
REP #$30
|
REP #$30
|
||||||
LDA.l TotalItemCounter : INC : TAY
|
LDA.l TotalItemCounter : INC : TAY
|
||||||
JSL UpdateLootHUD
|
|
||||||
LDA.l BootsEquipment : AND.w #$00FF : BNE +
|
LDA.l BootsEquipment : AND.w #$00FF : BNE +
|
||||||
TYA : STA.l PreBootsLocations
|
TYA : STA.l PreBootsLocations
|
||||||
+
|
+
|
||||||
@@ -649,16 +648,23 @@ RTL
|
|||||||
CollectPowder:
|
CollectPowder:
|
||||||
LDY.w SprSourceItemId, X ; Retrieve stored item type
|
LDY.w SprSourceItemId, X ; Retrieve stored item type
|
||||||
BNE +
|
BNE +
|
||||||
; if for any reason the item value is 0 reload it, just in case
|
; if for any reason the item value is 0 reload it, just in case
|
||||||
%GetPossiblyEncryptedItem(WitchItem, SpriteItemValues) : TAY
|
%GetPossiblyEncryptedItem(WitchItem, SpriteItemValues) : TAY
|
||||||
+ PHA
|
+
|
||||||
LDA.l WitchItem_Player : STA.l !MULTIWORLD_ITEM_PLAYER_ID
|
PHA
|
||||||
LDA.b #$01 : STA.l ShopEnableCount
|
JSL ShieldCheck
|
||||||
|
BCC .skip
|
||||||
|
|
||||||
|
|
||||||
|
LDA.l WitchItem_Player : STA.l !MULTIWORLD_ITEM_PLAYER_ID
|
||||||
|
LDA.b #$01 : STA.l ShopEnableCount
|
||||||
PLA
|
PLA
|
||||||
STZ.w ItemReceiptMethod ; item from NPC
|
STZ.w ItemReceiptMethod ; item from NPC
|
||||||
JSL Link_ReceiveItem
|
JSL Link_ReceiveItem
|
||||||
PHA : LDA.b #$00 : STA.l ShopEnableCount : STA.l PowderFlag : PLA
|
PHA : LDA.b #$00 : STA.l ShopEnableCount : STA.l PowderFlag
|
||||||
JSL ItemSet_Powder
|
JSL ItemSet_Powder
|
||||||
|
.skip
|
||||||
|
PLA
|
||||||
RTL
|
RTL
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
|||||||
@@ -239,7 +239,7 @@ endmacro
|
|||||||
%ReceiptProps($63, -4, 0, $FF, $F36A, $FF, skip, rng_multi) ; 63 - RNG pool item (multi)
|
%ReceiptProps($63, -4, 0, $FF, $F36A, $FF, skip, rng_multi) ; 63 - RNG pool item (multi)
|
||||||
%ReceiptProps($64, -4, 0, $FF, $F340, $FF, skip, progressive_bow) ; 64 - Progressive bow
|
%ReceiptProps($64, -4, 0, $FF, $F340, $FF, skip, progressive_bow) ; 64 - Progressive bow
|
||||||
%ReceiptProps($65, -4, 0, $FF, $F340, $FF, skip, progressive_bow_2) ; 65 - Progressive bow
|
%ReceiptProps($65, -4, 0, $FF, $F340, $FF, skip, progressive_bow_2) ; 65 - Progressive bow
|
||||||
%ReceiptProps($66, -4, 0, $51, $F36E, $FF, skip, skip) ; 66 - Potion refill (yellow)
|
%ReceiptProps($66, -4, 0, $FF, $F36A, $FF, skip, skip) ; 66 -
|
||||||
%ReceiptProps($67, -4, 0, $FF, $F36A, $FF, skip, skip) ; 67 -
|
%ReceiptProps($67, -4, 0, $FF, $F36A, $FF, skip, skip) ; 67 -
|
||||||
%ReceiptProps($68, -4, 0, $FF, $F36A, $FF, skip, skip) ; 68 -
|
%ReceiptProps($68, -4, 0, $FF, $F36A, $FF, skip, skip) ; 68 -
|
||||||
%ReceiptProps($69, -4, 0, $FF, $F36A, $FF, skip, skip) ; 69 -
|
%ReceiptProps($69, -4, 0, $FF, $F36A, $FF, skip, skip) ; 69 -
|
||||||
@@ -416,40 +416,40 @@ macro SpriteProps(id, chest_width, standing_width, chest_pal, standing_pal, addr
|
|||||||
pullpc
|
pullpc
|
||||||
endmacro
|
endmacro
|
||||||
|
|
||||||
%SpriteProps($00, 0, 2, $05, $02, PalettesVanilla_blue_ice+$0E) ; 00 - Fighter sword & Shield
|
%SpriteProps($00, 0, 0, $05, $80, PalettesCustom_fighter_shield) ; 00 - Fighter sword & Shield
|
||||||
%SpriteProps($01, 0, 2, $05, $05, PalettesCustom_master_sword) ; 01 - Master sword
|
%SpriteProps($01, 0, 0, $05, $80, PalettesCustom_fighter_shield) ; 01 - Master sword
|
||||||
%SpriteProps($02, 0, 2, $05, $01, PalettesCustom_tempered_sword) ; 02 - Tempered sword
|
%SpriteProps($02, 0, 0, $05, $80, PalettesCustom_fighter_shield) ; 02 - Tempered sword
|
||||||
%SpriteProps($03, 0, 2, $05, $04, PalettesCustom_golden_sword) ; 03 - Golden sword
|
%SpriteProps($03, 0, 0, $05, $80, PalettesCustom_fighter_shield) ; 03 - Golden sword
|
||||||
%SpriteProps($04, 0, 0, $05, $80, PalettesCustom_fighter_shield) ; 04 - Fighter shield
|
%SpriteProps($04, 0, 0, $05, $80, PalettesCustom_fighter_shield) ; 04 - Fighter shield
|
||||||
%SpriteProps($05, 2, 2, $05, $80, PalettesCustom_red_shield) ; 05 - Fire shield
|
%SpriteProps($05, 2, 2, $05, $80, PalettesCustom_red_shield) ; 05 - Fire shield
|
||||||
%SpriteProps($06, 2, 2, $05, $80, PalettesCustom_mirror_shield) ; 06 - Mirror shield
|
%SpriteProps($06, 2, 2, $05, $80, PalettesCustom_mirror_shield) ; 06 - Mirror shield
|
||||||
%SpriteProps($07, 0, 0, $01, $01, PalettesVanilla_red_melon+$0E) ; 07 - Fire rod
|
%SpriteProps($07, 0, 0, $01, $80, PalettesCustom_fighter_shield) ; 07 - Fire rod
|
||||||
%SpriteProps($08, 0, 0, $02, $02, PalettesVanilla_blue_ice+$0E) ; 08 - Ice rod
|
%SpriteProps($08, 0, 0, $02, $80, PalettesCustom_fighter_shield) ; 08 - Ice rod
|
||||||
%SpriteProps($09, 0, 0, $01, $01, PalettesVanilla_red_melon+$0E) ; 09 - Hammer
|
%SpriteProps($09, 0, 0, $01, $80, PalettesCustom_fighter_shield) ; 09 - Hammer
|
||||||
%SpriteProps($0A, 0, 0, $01, $01, PalettesVanilla_red_melon+$0E) ; 0A - Hookshot
|
%SpriteProps($0A, 0, 0, $01, $80, PalettesCustom_fighter_shield) ; 0A - Hookshot
|
||||||
%SpriteProps($0B, 0, 0, $01, $01, PalettesVanilla_red_melon+$0E) ; 0B - Bow
|
%SpriteProps($0B, 0, 0, $01, $80, PalettesCustom_fighter_shield) ; 0B - Bow
|
||||||
%SpriteProps($0C, 0, 0, $02, $02, PalettesVanilla_blue_ice+$0E) ; 0C - Blue Boomerang
|
%SpriteProps($0C, 0, 0, $02, $80, PalettesCustom_fighter_shield) ; 0C - Blue Boomerang
|
||||||
%SpriteProps($0D, 2, 2, $02, $02, PalettesVanilla_blue_ice+$0E) ; 0D - Powder
|
%SpriteProps($0D, 2, 0, $02, $80, PalettesCustom_fighter_shield) ; 0D - Powder
|
||||||
%SpriteProps($0E, 2, 0, $02, $03, PalettesVanilla_blue_ice+$0E) ; 0E - Bottle refill (bee)
|
%SpriteProps($0E, 2, 0, $02, $03, PalettesVanilla_blue_ice+$0E) ; 0E - Bottle refill (bee)
|
||||||
%SpriteProps($0F, 2, 2, $04, $04, PalettesVanilla_green_blue_guard+$0E) ; 0F - Bombos
|
%SpriteProps($0F, 2, 0, $04, $80, PalettesCustom_fighter_shield) ; 0F - Bombos
|
||||||
%SpriteProps($10, 2, 2, $04, $04, PalettesVanilla_green_blue_guard+$0E) ; 10 - Ether
|
%SpriteProps($10, 2, 0, $04, $80, PalettesCustom_fighter_shield) ; 10 - Ether
|
||||||
%SpriteProps($11, 2, 2, $04, $04, PalettesVanilla_green_blue_guard+$0E) ; 11 - Quake
|
%SpriteProps($11, 2, 0, $04, $80, PalettesCustom_fighter_shield) ; 11 - Quake
|
||||||
%SpriteProps($12, 2, 2, $01, $01, PalettesVanilla_red_melon+$0E) ; 12 - Lamp
|
%SpriteProps($12, 2, 0, $01, $80, PalettesCustom_fighter_shield) ; 12 - Lamp
|
||||||
%SpriteProps($13, 0, 0, $01, $01, PalettesVanilla_red_melon+$0E) ; 13 - Shovel
|
%SpriteProps($13, 0, 0, $01, $80, PalettesCustom_fighter_shield) ; 13 - Shovel
|
||||||
%SpriteProps($14, 2, 2, $02, $02, PalettesVanilla_blue_ice+$0E) ; 14 - Flute
|
%SpriteProps($14, 2, 0, $02, $80, PalettesCustom_fighter_shield) ; 14 - Flute
|
||||||
%SpriteProps($15, 0, 0, $01, $01, PalettesVanilla_red_melon+$0E) ; 15 - Somaria
|
%SpriteProps($15, 0, 0, $01, $80, PalettesCustom_fighter_shield) ; 15 - Somaria
|
||||||
%SpriteProps($16, 2, 2, $01, $01, PalettesVanilla_red_melon+$0E) ; 16 - Bottle
|
%SpriteProps($16, 2, 0, $01, $80, PalettesCustom_fighter_shield) ; 16 - Bottle
|
||||||
%SpriteProps($17, 2, 2, $01, $01, PalettesVanilla_red_melon+$0E) ; 17 - Heart piece
|
%SpriteProps($17, 2, 2, $01, $01, PalettesVanilla_red_melon+$0E) ; 17 - Heart piece
|
||||||
%SpriteProps($18, 0, 0, $02, $02, PalettesVanilla_blue_ice+$0E) ; 18 - Byrna
|
%SpriteProps($18, 0, 0, $02, $80, PalettesCustom_fighter_shield) ; 18 - Byrna
|
||||||
%SpriteProps($19, 2, 2, $01, $01, PalettesVanilla_red_melon+$0E) ; 19 - Cape
|
%SpriteProps($19, 2, 0, $01, $80, PalettesCustom_fighter_shield) ; 19 - Cape
|
||||||
%SpriteProps($1A, 2, 2, $02, $02, PalettesVanilla_blue_ice+$0E) ; 1A - Mirror
|
%SpriteProps($1A, 2, 0, $02, $80, PalettesCustom_fighter_shield) ; 1A - Mirror
|
||||||
%SpriteProps($1B, 2, 2, $01, $01, PalettesVanilla_red_melon+$0E) ; 1B - Glove
|
%SpriteProps($1B, 2, 0, $01, $80, PalettesCustom_fighter_shield) ; 1B - Glove
|
||||||
%SpriteProps($1C, 2, 2, $04, $04, PalettesVanilla_green_blue_guard+$0E) ; 1C - Mitts
|
%SpriteProps($1C, 2, 0, $04, $80, PalettesCustom_fighter_shield) ; 1C - Mitts
|
||||||
%SpriteProps($1D, 2, 2, $04, $04, PalettesVanilla_green_blue_guard+$0E) ; 1D - Book
|
%SpriteProps($1D, 2, 0, $04, $80, PalettesCustom_fighter_shield) ; 1D - Book
|
||||||
%SpriteProps($1E, 2, 2, $02, $02, PalettesVanilla_blue_ice+$0E) ; 1E - Flippers
|
%SpriteProps($1E, 2, 0, $02, $80, PalettesCustom_fighter_shield) ; 1E - Flippers
|
||||||
%SpriteProps($1F, 2, 2, $01, $01, PalettesVanilla_red_melon+$0E) ; 1F - Pearl
|
%SpriteProps($1F, 2, 0, $01, $80, PalettesCustom_fighter_shield) ; 1F - Pearl
|
||||||
%SpriteProps($20, 2, 2, $86, $86, PalettesCustom_crystal) ; 20 - Crystal
|
%SpriteProps($20, 2, 2, $86, $86, PalettesCustom_crystal) ; 20 - Crystal
|
||||||
%SpriteProps($21, 2, 2, $01, $01, PalettesVanilla_red_melon+$0E) ; 21 - Net
|
%SpriteProps($21, 2, 0, $01, $80, PalettesCustom_fighter_shield) ; 21 - Net
|
||||||
%SpriteProps($22, 2, 2, $02, $02, PalettesVanilla_blue_ice+$0E) ; 22 - Blue mail
|
%SpriteProps($22, 2, 2, $02, $02, PalettesVanilla_blue_ice+$0E) ; 22 - Blue mail
|
||||||
%SpriteProps($23, 2, 2, $01, $01, PalettesVanilla_red_melon+$0E) ; 23 - Red mail
|
%SpriteProps($23, 2, 2, $01, $01, PalettesVanilla_red_melon+$0E) ; 23 - Red mail
|
||||||
%SpriteProps($24, 0, 0, $02, $04, PalettesVanilla_blue_ice+$0E) ; 24 - Small key
|
%SpriteProps($24, 0, 0, $02, $04, PalettesVanilla_blue_ice+$0E) ; 24 - Small key
|
||||||
@@ -457,11 +457,11 @@ endmacro
|
|||||||
%SpriteProps($26, 2, 2, $01, $01, PalettesVanilla_red_melon+$0E) ; 26 - Heart container from 4/4
|
%SpriteProps($26, 2, 2, $01, $01, PalettesVanilla_red_melon+$0E) ; 26 - Heart container from 4/4
|
||||||
%SpriteProps($27, 2, 2, $02, $02, PalettesVanilla_blue_ice+$0E) ; 27 - Bomb
|
%SpriteProps($27, 2, 2, $02, $02, PalettesVanilla_blue_ice+$0E) ; 27 - Bomb
|
||||||
%SpriteProps($28, 2, 2, $02, $02, PalettesVanilla_blue_ice+$0E) ; 28 - 3 bombs
|
%SpriteProps($28, 2, 2, $02, $02, PalettesVanilla_blue_ice+$0E) ; 28 - 3 bombs
|
||||||
%SpriteProps($29, 2, 2, $04, $04, PalettesVanilla_green_blue_guard+$0E) ; 29 - Mushroom
|
%SpriteProps($29, 2, 0, $04, $80, PalettesCustom_fighter_shield) ; 29 - Mushroom
|
||||||
%SpriteProps($2A, 0, 0, $01, $01, PalettesVanilla_red_melon+$0E) ; 2A - Red boomerang
|
%SpriteProps($2A, 0, 0, $01, $80, PalettesCustom_fighter_shield) ; 2A - Red boomerang
|
||||||
%SpriteProps($2B, 2, 2, $01, $01, PalettesVanilla_red_melon+$0E) ; 2B - Full bottle (red)
|
%SpriteProps($2B, 2, 0, $01, $80, PalettesCustom_fighter_shield) ; 2B - Full bottle (red)
|
||||||
%SpriteProps($2C, 2, 2, $04, $04, PalettesVanilla_green_blue_guard+$0E) ; 2C - Full bottle (green)
|
%SpriteProps($2C, 2, 0, $04, $80, PalettesCustom_fighter_shield) ; 2C - Full bottle (green)
|
||||||
%SpriteProps($2D, 2, 2, $02, $02, PalettesVanilla_blue_ice+$0E) ; 2D - Full bottle (blue)
|
%SpriteProps($2D, 2, 0, $02, $80, PalettesCustom_fighter_shield) ; 2D - Full bottle (blue)
|
||||||
%SpriteProps($2E, 2, 2, $01, $01, PalettesVanilla_red_melon+$0E) ; 2E - Potion refill (red)
|
%SpriteProps($2E, 2, 2, $01, $01, PalettesVanilla_red_melon+$0E) ; 2E - Potion refill (red)
|
||||||
%SpriteProps($2F, 2, 2, $04, $04, PalettesVanilla_green_blue_guard+$0E) ; 2F - Potion refill (green)
|
%SpriteProps($2F, 2, 2, $04, $04, PalettesVanilla_green_blue_guard+$0E) ; 2F - Potion refill (green)
|
||||||
%SpriteProps($30, 2, 2, $02, $02, PalettesVanilla_blue_ice+$0E) ; 30 - Potion refill (blue)
|
%SpriteProps($30, 2, 2, $02, $02, PalettesVanilla_blue_ice+$0E) ; 30 - Potion refill (blue)
|
||||||
@@ -474,10 +474,10 @@ endmacro
|
|||||||
%SpriteProps($37, 2, 2, $04, $04, PalettesVanilla_green_blue_guard+$0E) ; 37 - Green pendant
|
%SpriteProps($37, 2, 2, $04, $04, PalettesVanilla_green_blue_guard+$0E) ; 37 - Green pendant
|
||||||
%SpriteProps($38, 2, 2, $01, $01, PalettesVanilla_red_melon+$0E) ; 38 - Red pendant
|
%SpriteProps($38, 2, 2, $01, $01, PalettesVanilla_red_melon+$0E) ; 38 - Red pendant
|
||||||
%SpriteProps($39, 2, 2, $02, $02, PalettesVanilla_blue_ice+$0E) ; 39 - Blue pendant
|
%SpriteProps($39, 2, 2, $02, $02, PalettesVanilla_blue_ice+$0E) ; 39 - Blue pendant
|
||||||
%SpriteProps($3A, 2, 2, $02, $02, PalettesVanilla_blue_ice+$0E) ; 3A - Bow And Arrows
|
%SpriteProps($3A, 2, 0, $02, $80, PalettesCustom_fighter_shield) ; 3A - Bow And Arrows
|
||||||
%SpriteProps($3B, 2, 2, $01, $01, PalettesVanilla_red_melon+$0E) ; 3B - Silver Bow
|
%SpriteProps($3B, 2, 0, $01, $80, PalettesCustom_fighter_shield) ; 3B - Silver Bow
|
||||||
%SpriteProps($3C, 2, 2, $02, $02, PalettesVanilla_blue_ice+$0E) ; 3C - Full bottle (bee)
|
%SpriteProps($3C, 2, 0, $02, $80, PalettesCustom_fighter_shield) ; 3C - Full bottle (bee)
|
||||||
%SpriteProps($3D, 2, 2, $02, $02, PalettesVanilla_blue_ice+$0E) ; 3D - Full bottle (fairy)
|
%SpriteProps($3D, 2, 0, $02, $80, PalettesCustom_fighter_shield) ; 3D - Full bottle (fairy)
|
||||||
%SpriteProps($3E, 2, 2, $01, $01, PalettesVanilla_red_melon+$0E) ; 3E - Boss heart
|
%SpriteProps($3E, 2, 2, $01, $01, PalettesVanilla_red_melon+$0E) ; 3E - Boss heart
|
||||||
%SpriteProps($3F, 2, 2, $01, $01, PalettesVanilla_red_melon+$0E) ; 3F - Sanc heart
|
%SpriteProps($3F, 2, 2, $01, $01, PalettesVanilla_red_melon+$0E) ; 3F - Sanc heart
|
||||||
%SpriteProps($40, 2, 2, $04, $04, PalettesVanilla_green_blue_guard+$0E) ; 40 - 100 rupees
|
%SpriteProps($40, 2, 2, $04, $04, PalettesVanilla_green_blue_guard+$0E) ; 40 - 100 rupees
|
||||||
@@ -488,23 +488,23 @@ endmacro
|
|||||||
%SpriteProps($45, 0, 0, $04, $04, PalettesVanilla_green_blue_guard+$0E) ; 45 - Small magic
|
%SpriteProps($45, 0, 0, $04, $04, PalettesVanilla_green_blue_guard+$0E) ; 45 - Small magic
|
||||||
%SpriteProps($46, 2, 2, $04, $04, PalettesVanilla_green_blue_guard+$0E) ; 46 - 300 rupees
|
%SpriteProps($46, 2, 2, $04, $04, PalettesVanilla_green_blue_guard+$0E) ; 46 - 300 rupees
|
||||||
%SpriteProps($47, 2, 2, $04, $04, PalettesVanilla_green_blue_guard+$0E) ; 47 - 20 rupees green
|
%SpriteProps($47, 2, 2, $04, $04, PalettesVanilla_green_blue_guard+$0E) ; 47 - 20 rupees green
|
||||||
%SpriteProps($48, 2, 2, $02, $02, PalettesVanilla_blue_ice+$0E) ; 48 - Full bottle (good bee)
|
%SpriteProps($48, 2, 0, $02, $80, PalettesCustom_fighter_shield) ; 48 - Full bottle (good bee)
|
||||||
%SpriteProps($49, 0, 2, $05, $02, PalettesCustom_fighter_shield) ; 49 - Tossed fighter sword
|
%SpriteProps($49, 0, 0, $05, $80, PalettesCustom_fighter_shield) ; 49 - Tossed fighter sword
|
||||||
%SpriteProps($4A, 2, 2, $02, $02, PalettesVanilla_blue_ice+$0E) ; 4A - Active Flute
|
%SpriteProps($4A, 2, 0, $02, $80, PalettesCustom_fighter_shield) ; 4A - Active Flute
|
||||||
%SpriteProps($4B, 2, 2, $01, $01, PalettesVanilla_red_melon+$0E) ; 4B - Boots
|
%SpriteProps($4B, 2, 0, $01, $80, PalettesCustom_fighter_shield) ; 4B - Boots
|
||||||
%SpriteProps($4C, 2, 2, $04, $04, PalettesVanilla_green_blue_guard+$0E) ; 4C - Bomb capacity (50)
|
%SpriteProps($4C, 2, 2, $04, $04, PalettesVanilla_green_blue_guard+$0E) ; 4C - Bomb capacity (50)
|
||||||
%SpriteProps($4D, 2, 2, $04, $04, PalettesVanilla_green_blue_guard+$0E) ; 4D - Arrow capacity (70)
|
%SpriteProps($4D, 2, 2, $04, $04, PalettesVanilla_green_blue_guard+$0E) ; 4D - Arrow capacity (70)
|
||||||
%SpriteProps($4E, 2, 2, $04, $04, PalettesVanilla_green_blue_guard+$0E) ; 4E - 1/2 magic
|
%SpriteProps($4E, 2, 0, $04, $80, PalettesCustom_fighter_shield) ; 4E - 1/2 magic
|
||||||
%SpriteProps($4F, 2, 2, $04, $04, PalettesVanilla_green_blue_guard+$0E) ; 4F - 1/4 magic
|
%SpriteProps($4F, 2, 0, $04, $80, PalettesCustom_fighter_shield) ; 4F - 1/4 magic
|
||||||
%SpriteProps($50, 0, 2, $05, $02, PalettesCustom_master_sword) ; 50 - Safe master sword
|
%SpriteProps($50, 0, 0, $05, $80, PalettesCustom_fighter_shield) ; 50 - Safe master sword
|
||||||
%SpriteProps($51, 2, 2, $04, $04, PalettesVanilla_green_blue_guard+$0E) ; 51 - Bomb capacity (+5)
|
%SpriteProps($51, 2, 2, $04, $04, PalettesVanilla_green_blue_guard+$0E) ; 51 - Bomb capacity (+5)
|
||||||
%SpriteProps($52, 2, 2, $04, $04, PalettesVanilla_green_blue_guard+$0E) ; 52 - Bomb capacity (+10)
|
%SpriteProps($52, 2, 0, $04, $80, PalettesCustom_fighter_shield) ; 52 - Bomb capacity (+10)
|
||||||
%SpriteProps($53, 2, 2, $04, $04, PalettesVanilla_green_blue_guard+$0E) ; 53 - Arrow capacity (+5)
|
%SpriteProps($53, 2, 2, $04, $04, PalettesVanilla_green_blue_guard+$0E) ; 53 - Arrow capacity (+5)
|
||||||
%SpriteProps($54, 2, 2, $04, $04, PalettesVanilla_green_blue_guard+$0E) ; 54 - Arrow capacity (+10)
|
%SpriteProps($54, 2, 2, $04, $04, PalettesVanilla_green_blue_guard+$0E) ; 54 - Arrow capacity (+10)
|
||||||
%SpriteProps($55, 2, 2, $04, $04, $0000) ; 55 - Programmable item 1
|
%SpriteProps($55, 2, 2, $04, $04, $0000) ; 55 - Programmable item 1
|
||||||
%SpriteProps($56, 2, 2, $04, $04, $0000) ; 56 - Programmable item 2
|
%SpriteProps($56, 2, 2, $04, $04, $0000) ; 56 - Programmable item 2
|
||||||
%SpriteProps($57, 2, 2, $04, $04, $0000) ; 57 - Programmable item 3
|
%SpriteProps($57, 2, 2, $04, $04, $0000) ; 57 - Programmable item 3
|
||||||
%SpriteProps($58, 2, 2, $01, $01, PalettesVanilla_red_melon+$0E) ; 58 - Upgrade-only Silver Arrows
|
%SpriteProps($58, 2, 0, $01, $80, PalettesCustom_fighter_shield) ; 58 - Upgrade-only Silver Arrows
|
||||||
%SpriteProps($59, 0, 0, $03, $03, PalettesCustom_off_black) ; 59 - Rupoor
|
%SpriteProps($59, 0, 0, $03, $03, PalettesCustom_off_black) ; 59 - Rupoor
|
||||||
%SpriteProps($5A, 2, 2, $01, $01, $0000) ; 5A - Nothing
|
%SpriteProps($5A, 2, 2, $01, $01, $0000) ; 5A - Nothing
|
||||||
%SpriteProps($5B, 2, 2, $01, $01, PalettesVanilla_red_melon+$0E) ; 5B - Red clock
|
%SpriteProps($5B, 2, 2, $01, $01, PalettesVanilla_red_melon+$0E) ; 5B - Red clock
|
||||||
@@ -518,7 +518,7 @@ endmacro
|
|||||||
%SpriteProps($63, 2, 2, $FF, $FF, $0000) ; 63 - RNG pool item (multi)
|
%SpriteProps($63, 2, 2, $FF, $FF, $0000) ; 63 - RNG pool item (multi)
|
||||||
%SpriteProps($64, 2, 2, $FF, $FF, $0000) ; 64 - Progressive bow
|
%SpriteProps($64, 2, 2, $FF, $FF, $0000) ; 64 - Progressive bow
|
||||||
%SpriteProps($65, 2, 2, $FF, $FF, $0000) ; 65 - Progressive bow
|
%SpriteProps($65, 2, 2, $FF, $FF, $0000) ; 65 - Progressive bow
|
||||||
%SpriteProps($66, 2, 2, $02, $02, $0000) ; 66 - Potion refill (yellow)
|
%SpriteProps($66, 2, 2, $00, $00, $0000) ; 66 -
|
||||||
%SpriteProps($67, 2, 2, $00, $00, $0000) ; 67 -
|
%SpriteProps($67, 2, 2, $00, $00, $0000) ; 67 -
|
||||||
%SpriteProps($68, 2, 2, $00, $00, $0000) ; 68 -
|
%SpriteProps($68, 2, 2, $00, $00, $0000) ; 68 -
|
||||||
%SpriteProps($69, 2, 2, $00, $00, $0000) ; 69 -
|
%SpriteProps($69, 2, 2, $00, $00, $0000) ; 69 -
|
||||||
@@ -696,7 +696,7 @@ endmacro
|
|||||||
%InventoryItem($01, $0081, SwordTime, $0000) ; 01 - Master sword
|
%InventoryItem($01, $0081, SwordTime, $0000) ; 01 - Master sword
|
||||||
%InventoryItem($02, $0001, SwordTime, $0000) ; 02 - Tempered sword
|
%InventoryItem($02, $0001, SwordTime, $0000) ; 02 - Tempered sword
|
||||||
%InventoryItem($03, $0081, SwordTime, $0000) ; 03 - Butter sword
|
%InventoryItem($03, $0081, SwordTime, $0000) ; 03 - Butter sword
|
||||||
%InventoryItem($04, $0081, $0000, $0000) ; 04 - Fighter shield
|
%InventoryItem($04, $0080, $0000, $0000) ; 04 - Fighter shield
|
||||||
%InventoryItem($05, $0081, $0000, $0000) ; 05 - Fire shield
|
%InventoryItem($05, $0081, $0000, $0000) ; 05 - Fire shield
|
||||||
%InventoryItem($06, $0081, $0000, $0000) ; 06 - Mirror shield
|
%InventoryItem($06, $0081, $0000, $0000) ; 06 - Mirror shield
|
||||||
%InventoryItem($07, $0085, $0000, $0000) ; 07 - Fire rod
|
%InventoryItem($07, $0085, $0000, $0000) ; 07 - Fire rod
|
||||||
@@ -794,7 +794,7 @@ endmacro
|
|||||||
%InventoryItem($63, $0001, $0000, $0000) ; 63 - RNG pool item (multi)
|
%InventoryItem($63, $0001, $0000, $0000) ; 63 - RNG pool item (multi)
|
||||||
%InventoryItem($64, $00A5, $0000, $0000) ; 64 - Progressive bow
|
%InventoryItem($64, $00A5, $0000, $0000) ; 64 - Progressive bow
|
||||||
%InventoryItem($65, $00A5, $0000, $0000) ; 65 - Progressive bow
|
%InventoryItem($65, $00A5, $0000, $0000) ; 65 - Progressive bow
|
||||||
%InventoryItem($66, $0081, $0000, $0000) ; 66 - Potion refill (yellow)
|
%InventoryItem($66, $0001, $0000, $0000) ; 66 -
|
||||||
%InventoryItem($67, $0001, $0000, $0000) ; 67 -
|
%InventoryItem($67, $0001, $0000, $0000) ; 67 -
|
||||||
%InventoryItem($68, $0001, $0000, $0000) ; 68 -
|
%InventoryItem($68, $0001, $0000, $0000) ; 68 -
|
||||||
%InventoryItem($69, $0001, $0000, $0000) ; 69 -
|
%InventoryItem($69, $0001, $0000, $0000) ; 69 -
|
||||||
@@ -1054,7 +1054,7 @@ ItemReceiptGraphicsOffsets:
|
|||||||
dw $0 ; 63 - RNG pool item (multi)
|
dw $0 ; 63 - RNG pool item (multi)
|
||||||
dw $0 ; 64 - Progressive bow
|
dw $0 ; 64 - Progressive bow
|
||||||
dw $0 ; 65 - Progressive bow
|
dw $0 ; 65 - Progressive bow
|
||||||
dw $0CE0 ; 66 - Potion refill (yellow)
|
dw $0 ; 66 -
|
||||||
dw $0 ; 67 -
|
dw $0 ; 67 -
|
||||||
dw $0 ; 68 -
|
dw $0 ; 68 -
|
||||||
dw $0 ; 69 -
|
dw $0 ; 69 -
|
||||||
@@ -1220,40 +1220,40 @@ ItemReceiptGraphicsOffsets:
|
|||||||
; for receipt and non-receipt drawing.
|
; for receipt and non-receipt drawing.
|
||||||
;===================================================================================================
|
;===================================================================================================
|
||||||
StandingItemGraphicsOffsets:
|
StandingItemGraphicsOffsets:
|
||||||
dw $0860 ; 00 - Fighter Sword and Shield
|
dw BigDecompressionBuffer+$09E0 ; 00 - Fighter Sword and Shield
|
||||||
dw $00E0 ; 01 - Master Sword
|
dw BigDecompressionBuffer+$09E0 ; 01 - Master Sword
|
||||||
dw $0120 ; 02 - Tempered Sword
|
dw BigDecompressionBuffer+$09E0 ; 02 - Tempered Sword
|
||||||
dw $0160 ; 03 - Butter Sword
|
dw BigDecompressionBuffer+$09E0 ; 03 - Butter Sword
|
||||||
dw BigDecompressionBuffer+$09E0 ; 04 - Fighter Shield
|
dw BigDecompressionBuffer+$09E0 ; 04 - Fighter Shield
|
||||||
dw BigDecompressionBuffer+$1940 ; 05 - Fire Shield
|
dw BigDecompressionBuffer+$1940 ; 05 - Fire Shield
|
||||||
dw BigDecompressionBuffer+$0C80 ; 06 - Mirror Shield
|
dw BigDecompressionBuffer+$0C80 ; 06 - Mirror Shield
|
||||||
dw BigDecompressionBuffer+$1C80 ; 07 - Fire Rod
|
dw BigDecompressionBuffer+$09E0 ; 07 - Fire Rod
|
||||||
dw BigDecompressionBuffer+$1C80 ; 08 - Ice Rod
|
dw BigDecompressionBuffer+$09E0 ; 08 - Ice Rod
|
||||||
dw BigDecompressionBuffer+$1CA0 ; 09 - Hammer
|
dw BigDecompressionBuffer+$09E0 ; 09 - Hammer
|
||||||
dw BigDecompressionBuffer+$1C60 ; 0A - Hookshot
|
dw BigDecompressionBuffer+$09E0 ; 0A - Hookshot
|
||||||
dw BigDecompressionBuffer+$1C00 ; 0B - Bow
|
dw BigDecompressionBuffer+$09E0 ; 0B - Bow
|
||||||
dw BigDecompressionBuffer+$1DE0 ; 0C - Boomerang
|
dw BigDecompressionBuffer+$09E0 ; 0C - Boomerang
|
||||||
dw BigDecompressionBuffer+$1CC0 ; 0D - Powder
|
dw BigDecompressionBuffer+$09E0 ; 0D - Powder
|
||||||
dw 0 ; 0E - Bottle Refill (bee)
|
dw 0 ; 0E - Bottle Refill (bee)
|
||||||
dw BigDecompressionBuffer+$1440 ; 0F - Bombos
|
dw BigDecompressionBuffer+$09E0 ; 0F - Bombos
|
||||||
dw BigDecompressionBuffer+$1400 ; 10 - Ether
|
dw BigDecompressionBuffer+$09E0 ; 10 - Ether
|
||||||
dw BigDecompressionBuffer+$1480 ; 11 - Quake
|
dw BigDecompressionBuffer+$09E0 ; 11 - Quake
|
||||||
dw BigDecompressionBuffer+$10C0 ; 12 - Lamp
|
dw BigDecompressionBuffer+$09E0 ; 12 - Lamp
|
||||||
dw BigDecompressionBuffer+$11E0 ; 13 - Shovel
|
dw BigDecompressionBuffer+$09E0 ; 13 - Shovel
|
||||||
dw BigDecompressionBuffer+$0C40 ; 14 - Flute
|
dw BigDecompressionBuffer+$09E0 ; 14 - Flute
|
||||||
dw BigDecompressionBuffer+$1C40 ; 15 - Somaria
|
dw BigDecompressionBuffer+$09E0 ; 15 - Somaria
|
||||||
dw BigDecompressionBuffer+$14C0 ; 16 - Bottle
|
dw BigDecompressionBuffer+$09E0 ; 16 - Bottle
|
||||||
dw BigDecompressionBuffer+$0C00 ; 17 - Heartpiece
|
dw BigDecompressionBuffer+$0C00 ; 17 - Heartpiece
|
||||||
dw BigDecompressionBuffer+$1C40 ; 18 - Byrna
|
dw BigDecompressionBuffer+$09E0 ; 18 - Byrna
|
||||||
dw BigDecompressionBuffer+$1100 ; 19 - Cape
|
dw BigDecompressionBuffer+$09E0 ; 19 - Cape
|
||||||
dw BigDecompressionBuffer+$1040 ; 1A - Mirror
|
dw BigDecompressionBuffer+$09E0 ; 1A - Mirror
|
||||||
dw BigDecompressionBuffer+$1D40 ; 1B - Glove
|
dw BigDecompressionBuffer+$09E0 ; 1B - Glove
|
||||||
dw BigDecompressionBuffer+$1D40 ; 1C - Mitts
|
dw BigDecompressionBuffer+$09E0 ; 1C - Mitts
|
||||||
dw BigDecompressionBuffer+$1D80 ; 1D - Book
|
dw BigDecompressionBuffer+$09E0 ; 1D - Book
|
||||||
dw BigDecompressionBuffer+$1000 ; 1E - Flippers
|
dw BigDecompressionBuffer+$09E0 ; 1E - Flippers
|
||||||
dw BigDecompressionBuffer+$1180 ; 1F - Pearl
|
dw BigDecompressionBuffer+$09E0 ; 1F - Pearl
|
||||||
dw BigDecompressionBuffer+$08A0 ; 20 - Crystal
|
dw BigDecompressionBuffer+$08A0 ; 20 - Crystal
|
||||||
dw BigDecompressionBuffer+$0860 ; 21 - Net
|
dw BigDecompressionBuffer+$09E0 ; 21 - Net
|
||||||
dw BigDecompressionBuffer+$1900 ; 22 - Blue Mail
|
dw BigDecompressionBuffer+$1900 ; 22 - Blue Mail
|
||||||
dw BigDecompressionBuffer+$1900 ; 23 - Red Mail
|
dw BigDecompressionBuffer+$1900 ; 23 - Red Mail
|
||||||
dw BigDecompressionBuffer+$1DC0 ; 24 - Small Key
|
dw BigDecompressionBuffer+$1DC0 ; 24 - Small Key
|
||||||
@@ -1261,11 +1261,11 @@ StandingItemGraphicsOffsets:
|
|||||||
dw BigDecompressionBuffer+$18C0 ; 26 - Heart Container from 4/4
|
dw BigDecompressionBuffer+$18C0 ; 26 - Heart Container from 4/4
|
||||||
dw BigDecompressionBuffer+$1080 ; 27 - Bomb
|
dw BigDecompressionBuffer+$1080 ; 27 - Bomb
|
||||||
dw BigDecompressionBuffer+$1840 ; 28 - 3 bombs
|
dw BigDecompressionBuffer+$1840 ; 28 - 3 bombs
|
||||||
dw BigDecompressionBuffer+$1540 ; 29 - Mushroom
|
dw BigDecompressionBuffer+$09E0 ; 29 - Mushroom
|
||||||
dw BigDecompressionBuffer+$1DE0 ; 2A - Red boomerang
|
dw BigDecompressionBuffer+$09E0 ; 2A - Red boomerang
|
||||||
dw BigDecompressionBuffer+$1500 ; 2B - Full bottle (red)
|
dw BigDecompressionBuffer+$09E0 ; 2B - Full bottle (red)
|
||||||
dw BigDecompressionBuffer+$1500 ; 2C - Full bottle (green)
|
dw BigDecompressionBuffer+$09E0 ; 2C - Full bottle (green)
|
||||||
dw BigDecompressionBuffer+$1500 ; 2D - Full bottle (blue)
|
dw BigDecompressionBuffer+$09E0 ; 2D - Full bottle (blue)
|
||||||
dw $0920 ; 2E - Potion refill (red)
|
dw $0920 ; 2E - Potion refill (red)
|
||||||
dw $08A0 ; 2F - Potion refill (green)
|
dw $08A0 ; 2F - Potion refill (green)
|
||||||
dw $08E0 ; 30 - Potion refill (blue)
|
dw $08E0 ; 30 - Potion refill (blue)
|
||||||
@@ -1278,10 +1278,10 @@ StandingItemGraphicsOffsets:
|
|||||||
dw $0820 ; 37 - Green pendant
|
dw $0820 ; 37 - Green pendant
|
||||||
dw BigDecompressionBuffer+$0080 ; 38 - Blue pendant
|
dw BigDecompressionBuffer+$0080 ; 38 - Blue pendant
|
||||||
dw BigDecompressionBuffer+$0080 ; 39 - Red pendant
|
dw BigDecompressionBuffer+$0080 ; 39 - Red pendant
|
||||||
dw BigDecompressionBuffer+$0920 ; 3A - Tossed bow
|
dw BigDecompressionBuffer+$09E0 ; 3A - Tossed bow
|
||||||
dw BigDecompressionBuffer+$08E0 ; 3B - Silvers
|
dw BigDecompressionBuffer+$09E0 ; 3B - Silvers
|
||||||
dw BigDecompressionBuffer+$09A0 ; 3C - Full bottle (bee)
|
dw BigDecompressionBuffer+$09E0 ; 3C - Full bottle (bee)
|
||||||
dw BigDecompressionBuffer+$0960 ; 3D - Full bottle (fairy)
|
dw BigDecompressionBuffer+$09E0 ; 3D - Full bottle (fairy)
|
||||||
dw BigDecompressionBuffer+$18C0 ; 3E - Boss heart
|
dw BigDecompressionBuffer+$18C0 ; 3E - Boss heart
|
||||||
dw BigDecompressionBuffer+$18C0 ; 3F - Sanc heart
|
dw BigDecompressionBuffer+$18C0 ; 3F - Sanc heart
|
||||||
dw BigDecompressionBuffer+$0D20 ; 40 - 100 rupees
|
dw BigDecompressionBuffer+$0D20 ; 40 - 100 rupees
|
||||||
@@ -1292,25 +1292,25 @@ StandingItemGraphicsOffsets:
|
|||||||
dw BigDecompressionBuffer+$0CE0 ; 45 - Small magic
|
dw BigDecompressionBuffer+$0CE0 ; 45 - Small magic
|
||||||
dw BigDecompressionBuffer+$0DA0 ; 46 - 300 rupees
|
dw BigDecompressionBuffer+$0DA0 ; 46 - 300 rupees
|
||||||
dw BigDecompressionBuffer+$0000 ; 47 - 20 rupees green
|
dw BigDecompressionBuffer+$0000 ; 47 - 20 rupees green
|
||||||
dw BigDecompressionBuffer+$09A0 ; 48 - Full bottle (good bee)
|
dw BigDecompressionBuffer+$09E0 ; 48 - Full bottle (good bee)
|
||||||
dw $00A0 ; 49 - Tossed fighter sword
|
dw BigDecompressionBuffer+$09E0 ; 49 - Tossed fighter sword
|
||||||
dw BigDecompressionBuffer+$0C40 ; 4A - Active Flute
|
dw BigDecompressionBuffer+$09E0 ; 4A - Active Flute
|
||||||
dw BigDecompressionBuffer+$0040 ; 4B - Boots
|
dw BigDecompressionBuffer+$09E0 ; 4B - Boots
|
||||||
|
|
||||||
; Rando items
|
; Rando items
|
||||||
dw $04A0 ; 4C - Bomb capacity (50)
|
dw $04A0 ; 4C - Bomb capacity (50)
|
||||||
dw $05A0 ; 4D - Arrow capacity (70)
|
dw $05A0 ; 4D - Arrow capacity (70)
|
||||||
dw $01A0 ; 4E - 1/2 magic
|
dw BigDecompressionBuffer+$09E0 ; 4E - 1/2 magic
|
||||||
dw $01E0 ; 4F - 1/4 magic
|
dw BigDecompressionBuffer+$09E0 ; 4F - 1/4 magic
|
||||||
dw $00E0 ; 50 - Safe master sword
|
dw BigDecompressionBuffer+$09E0 ; 50 - Safe master sword
|
||||||
dw $0420 ; 51 - Bomb capacity (+5)
|
dw $0420 ; 51 - Bomb capacity (+5)
|
||||||
dw $0460 ; 52 - Bomb capacity (+10)
|
dw BigDecompressionBuffer+$09E0 ; 52 - Bomb capacity (+10)
|
||||||
dw $0520 ; 53 - Arrow capacity (+5)
|
dw $0520 ; 53 - Arrow capacity (+5)
|
||||||
dw $0560 ; 54 - Arrow capacity (+10)
|
dw $0560 ; 54 - Arrow capacity (+10)
|
||||||
dw $0 ; 55 - Programmable item 1
|
dw $0 ; 55 - Programmable item 1
|
||||||
dw $0 ; 56 - Programmable item 2
|
dw $0 ; 56 - Programmable item 2
|
||||||
dw $0 ; 57 - Programmable item 3
|
dw $0 ; 57 - Programmable item 3
|
||||||
dw $05E0 ; 58 - Upgrade-only silver arrows
|
dw BigDecompressionBuffer+$09E0 ; 58 - Upgrade-only silver arrows
|
||||||
dw $0 ; 59 - Rupoor
|
dw $0 ; 59 - Rupoor
|
||||||
dw $0020 ; 5A - Nothing
|
dw $0020 ; 5A - Nothing
|
||||||
dw $0DE0 ; 5B - Red clock
|
dw $0DE0 ; 5B - Red clock
|
||||||
@@ -1324,7 +1324,7 @@ StandingItemGraphicsOffsets:
|
|||||||
dw $0 ; 63 - RNG pool item (multi)
|
dw $0 ; 63 - RNG pool item (multi)
|
||||||
dw $0 ; 64 - Progressive bow
|
dw $0 ; 64 - Progressive bow
|
||||||
dw $0 ; 65 - Progressive bow
|
dw $0 ; 65 - Progressive bow
|
||||||
dw $0CA0 ; 66 - Potion refill (yellow)
|
dw $0 ; 66 -
|
||||||
dw $0 ; 67 -
|
dw $0 ; 67 -
|
||||||
dw $0 ; 68 -
|
dw $0 ; 68 -
|
||||||
dw $0 ; 69 -
|
dw $0 ; 69 -
|
||||||
@@ -1590,7 +1590,7 @@ VRAMAddressOffset:
|
|||||||
dw $0024 ; 63 - RNG pool item (multi)
|
dw $0024 ; 63 - RNG pool item (multi)
|
||||||
dw $0024 ; 64 - Progressive bow
|
dw $0024 ; 64 - Progressive bow
|
||||||
dw $0024 ; 65 - Progressive bow
|
dw $0024 ; 65 - Progressive bow
|
||||||
dw $0024 ; 66 - Potion refill (yellow)
|
dw $0024 ; 66 -
|
||||||
dw $0024 ; 67 -
|
dw $0024 ; 67 -
|
||||||
dw $0024 ; 68 -
|
dw $0024 ; 68 -
|
||||||
dw $0024 ; 69 -
|
dw $0024 ; 69 -
|
||||||
|
|||||||
@@ -46,7 +46,7 @@ dw $7F7F
|
|||||||
|
|
||||||
; Ganons Tower
|
; Ganons Tower
|
||||||
Notice_GTower:
|
Notice_GTower:
|
||||||
db $76 : dw "Ganon's Tower"
|
db $76 : dw "Ganons Tower"
|
||||||
dw $7F7F
|
dw $7F7F
|
||||||
|
|
||||||
; Turtle Rock
|
; Turtle Rock
|
||||||
@@ -81,7 +81,7 @@ dw $7F7F
|
|||||||
|
|
||||||
; Dark Palace
|
; Dark Palace
|
||||||
Notice_PoD:
|
Notice_PoD:
|
||||||
db $76 : dw "Palace of Darkness"
|
db $76 : dw "Dark Palace"
|
||||||
dw $7F7F
|
dw $7F7F
|
||||||
|
|
||||||
; Swamp Palace
|
; Swamp Palace
|
||||||
|
|||||||
@@ -221,8 +221,7 @@ RevealPotItem:
|
|||||||
STZ.w SpawnedItemIsMultiWorld
|
STZ.w SpawnedItemIsMultiWorld
|
||||||
BIT.b Scrap08
|
BIT.b Scrap08
|
||||||
BVS LoadMultiWorldPotItem
|
BVS LoadMultiWorldPotItem
|
||||||
BPL .normal_secret
|
BMI LoadMajorPotItem
|
||||||
JMP LoadMajorPotItem
|
|
||||||
|
|
||||||
.normal_secret
|
.normal_secret
|
||||||
STA.b Scrap08
|
STA.b Scrap08
|
||||||
@@ -243,7 +242,6 @@ RevealPotItem:
|
|||||||
; Could increment GT Tower Pre Big Key but we aren't showing that stat right now
|
; Could increment GT Tower Pre Big Key but we aren't showing that stat right now
|
||||||
+ REP #$10
|
+ REP #$10
|
||||||
LDA.l TotalItemCounter : INC : STA.l TotalItemCounter ; Increment Item Total
|
LDA.l TotalItemCounter : INC : STA.l TotalItemCounter ; Increment Item Total
|
||||||
JSL UpdateLootHUD
|
|
||||||
LDA.w #$0001 : STA.l UpdateHUDFlag
|
LDA.w #$0001 : STA.l UpdateHUDFlag
|
||||||
.obtained
|
.obtained
|
||||||
PLY : PLX
|
PLY : PLX
|
||||||
@@ -343,7 +341,6 @@ IncrementCountsForSubstitute:
|
|||||||
; Could increment GT Tower Pre Big Key but we aren't showing that stat right now
|
; Could increment GT Tower Pre Big Key but we aren't showing that stat right now
|
||||||
+
|
+
|
||||||
LDA.l TotalItemCounter : INC : STA.l TotalItemCounter ; Increment Item Total
|
LDA.l TotalItemCounter : INC : STA.l TotalItemCounter ; Increment Item Total
|
||||||
JSL UpdateLootHUD
|
|
||||||
LDA.w #$0001 : STA.l UpdateHUDFlag
|
LDA.w #$0001 : STA.l UpdateHUDFlag
|
||||||
.obtained
|
.obtained
|
||||||
SEP #$30 : PLX
|
SEP #$30 : PLX
|
||||||
@@ -360,7 +357,7 @@ ClearSpriteData:
|
|||||||
STZ.w SprSourceItemId, X : STZ.w SprItemReceipt, X : STZ.w SprItemMWPlayer, X
|
STZ.w SprSourceItemId, X : STZ.w SprItemReceipt, X : STZ.w SprItemMWPlayer, X
|
||||||
STZ.w SprRedrawFlag, X
|
STZ.w SprRedrawFlag, X
|
||||||
DEX : BPL .loop
|
DEX : BPL .loop
|
||||||
JSL ClearLootHUD
|
JSR SetupEnemyDropIndicator
|
||||||
PLX
|
PLX
|
||||||
RTL
|
RTL
|
||||||
|
|
||||||
@@ -407,7 +404,7 @@ SetupEnemyDropIndicator:
|
|||||||
|
|
||||||
.done
|
.done
|
||||||
SEP #$20
|
SEP #$20
|
||||||
RTL
|
RTS
|
||||||
|
|
||||||
|
|
||||||
; Runs during sprite load of the room
|
; Runs during sprite load of the room
|
||||||
@@ -574,7 +571,7 @@ IncrementCountForMinor:
|
|||||||
LDA.l SpriteDropData, X : BIT.b Scrap0A : BNE .obtained
|
LDA.l SpriteDropData, X : BIT.b Scrap0A : BNE .obtained
|
||||||
ORA.b Scrap0A : STA.l SpriteDropData, X
|
ORA.b Scrap0A : STA.l SpriteDropData, X
|
||||||
SEP #$10
|
SEP #$10
|
||||||
JSL UpdateLootHUD
|
JSR SetupEnemyDropIndicator
|
||||||
REP #$20
|
REP #$20
|
||||||
LDX.w DungeonID : CPX.b #$FF : BEQ +
|
LDX.w DungeonID : CPX.b #$FF : BEQ +
|
||||||
CPX.b #$00 : BNE ++
|
CPX.b #$00 : BNE ++
|
||||||
@@ -630,10 +627,10 @@ MarkSRAMForItem:
|
|||||||
TYX
|
TYX
|
||||||
LDA.w SpawnedItemFlag : CMP.w #$0001 : BEQ +
|
LDA.w SpawnedItemFlag : CMP.w #$0001 : BEQ +
|
||||||
LDA.l SpriteDropData, X : ORA.b Scrap00 : STA.l SpriteDropData, X
|
LDA.l SpriteDropData, X : ORA.b Scrap00 : STA.l SpriteDropData, X
|
||||||
|
SEP #$10 : JSR SetupEnemyDropIndicator
|
||||||
BRA .end
|
BRA .end
|
||||||
+ LDA.l RoomPotData, X : ORA.b Scrap00 : STA.l RoomPotData, X
|
+ LDA.l RoomPotData, X : ORA.b Scrap00 : STA.l RoomPotData, X
|
||||||
.end
|
.end
|
||||||
JSL UpdateLootHUD
|
|
||||||
SEP #$30 : PLY : PLX
|
SEP #$30 : PLY : PLX
|
||||||
LDA.w RoomItemsTaken
|
LDA.w RoomItemsTaken
|
||||||
RTL
|
RTL
|
||||||
@@ -699,6 +696,14 @@ KeyGet:
|
|||||||
LDA.l StandingItemsOn : BNE +
|
LDA.l StandingItemsOn : BNE +
|
||||||
PLA : RTL
|
PLA : RTL
|
||||||
+ LDY.w SprSourceItemId, X
|
+ LDY.w SprSourceItemId, X
|
||||||
|
|
||||||
|
JSL ShieldCheck
|
||||||
|
BCS .not_replaced
|
||||||
|
PLA : PLA : PLA ; remove stored address to jump back to
|
||||||
|
PLA ; restore the A value going into KeyGet
|
||||||
|
JML $86D1A8
|
||||||
|
.not_replaced
|
||||||
|
|
||||||
LDA.w SprItemIndex, X : STA.w SpawnedItemIndex
|
LDA.w SprItemIndex, X : STA.w SpawnedItemIndex
|
||||||
LDA.w SprItemFlags, X : STA.w SpawnedItemFlag
|
LDA.w SprItemFlags, X : STA.w SpawnedItemFlag
|
||||||
STY.b Scrap00
|
STY.b Scrap00
|
||||||
|
|||||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
menu/drfont.2bpp
BIN
menu/drfont.2bpp
Binary file not shown.
@@ -9,7 +9,7 @@ UploadMenuOnlyIcons:
|
|||||||
REP #$20
|
REP #$20
|
||||||
LDA.w #MenuOnlyIcons : STA.w $4342
|
LDA.w #MenuOnlyIcons : STA.w $4342
|
||||||
LDA.w #$1801 : STA.w $4340
|
LDA.w #$1801 : STA.w $4340
|
||||||
LDA.w #$0400 : STA.w $4345
|
LDA.w #$0240 : STA.w $4345
|
||||||
LDA.w #$0F800>>1 : STA.w $2116
|
LDA.w #$0F800>>1 : STA.w $2116
|
||||||
|
|
||||||
SEP #$20
|
SEP #$20
|
||||||
@@ -20,4 +20,4 @@ UploadMenuOnlyIcons:
|
|||||||
RTL
|
RTL
|
||||||
|
|
||||||
MenuOnlyIcons:
|
MenuOnlyIcons:
|
||||||
incbin "drfont.2bpp"
|
incbin "drfont.2bpp"
|
||||||
@@ -89,6 +89,9 @@ GetMultiworldItem:
|
|||||||
PHP
|
PHP
|
||||||
LDA.l !MULTIWORLD_ITEM : BNE +
|
LDA.l !MULTIWORLD_ITEM : BNE +
|
||||||
LDA.l !MULTIWORLD_HUD_TIMER : BNE +
|
LDA.l !MULTIWORLD_HUD_TIMER : BNE +
|
||||||
|
LDA.l ShieldEquipment : BNE ++
|
||||||
|
LDA.l PikitItem : CMP.b #$04 : BNE +
|
||||||
|
++
|
||||||
BRL .return
|
BRL .return
|
||||||
+
|
+
|
||||||
|
|
||||||
@@ -123,9 +126,32 @@ GetMultiworldItem:
|
|||||||
BRL .return
|
BRL .return
|
||||||
+
|
+
|
||||||
|
|
||||||
LDA.b LinkPushDirection
|
LDA.l ShieldEquipment : BNE +
|
||||||
BEQ +
|
LDA.l PikitItem : CMP.b #$04 : BEQ +
|
||||||
BRL .return
|
|
||||||
|
LDY.b #$10
|
||||||
|
-
|
||||||
|
DEY
|
||||||
|
BMI .restore_shield
|
||||||
|
LDA.w $0E20, Y
|
||||||
|
CMP.b #$AA
|
||||||
|
BNE - ; go to next sprite if this sprite isn't a pikit
|
||||||
|
LDA.w $0DD0, Y
|
||||||
|
BEQ - ; go to next sprite if this sprite is dead/inactive
|
||||||
|
LDA.w $0ED0, Y
|
||||||
|
CMP.b #$04
|
||||||
|
BNE - ; go to next sprite if this pikit isn't grabbing a shield
|
||||||
|
LDA.w $0E90, Y
|
||||||
|
CMP.b #$04
|
||||||
|
BNE - ; go to next sprite if this pikit isn't grabbing a shield
|
||||||
|
|
||||||
|
BRA + ; active pikit has a shield
|
||||||
|
|
||||||
|
.restore_shield
|
||||||
|
; we have a pikit item, but no shield, and there's no pikit actively
|
||||||
|
; eating a shield, so return the shield to prevent a softlock
|
||||||
|
LDA.b #$01
|
||||||
|
STA.l ShieldEquipment
|
||||||
+
|
+
|
||||||
|
|
||||||
LDA.l !MULTIWORLD_ITEM : BNE +
|
LDA.l !MULTIWORLD_ITEM : BNE +
|
||||||
@@ -207,35 +233,69 @@ RTL
|
|||||||
|
|
||||||
Multiworld_BottleVendor_GiveBottle:
|
Multiworld_BottleVendor_GiveBottle:
|
||||||
{
|
{
|
||||||
|
PHA
|
||||||
|
JSL ShieldCheck
|
||||||
|
PLA
|
||||||
|
BCC .no_take_shield
|
||||||
|
|
||||||
PHA : PHP
|
PHA : PHP
|
||||||
SEP #$20
|
SEP #$20
|
||||||
LDA.l BottleMerchant_Player : STA.l !MULTIWORLD_ITEM_PLAYER_ID
|
LDA.l BottleMerchant_Player : STA.l !MULTIWORLD_ITEM_PLAYER_ID
|
||||||
PLP : PLA
|
PLP : PLA
|
||||||
|
|
||||||
JSL Link_ReceiveItem ; thing we wrote over
|
JSL Link_ReceiveItem ; thing we wrote over
|
||||||
RTL
|
RTL
|
||||||
|
|
||||||
|
.no_take_shield
|
||||||
|
PLA : PLA : PLA : PLX
|
||||||
|
JML $85EB3A
|
||||||
}
|
}
|
||||||
|
|
||||||
Multiworld_MiddleAgedMan_ReactToSecretKeepingResponse:
|
Multiworld_MiddleAgedMan_ReactToSecretKeepingResponse:
|
||||||
{
|
{
|
||||||
|
PHA
|
||||||
|
JSL ShieldCheck
|
||||||
|
PLA
|
||||||
|
BCC .no_take_shield
|
||||||
|
|
||||||
PHA : PHP
|
PHA : PHP
|
||||||
SEP #$20
|
SEP #$20
|
||||||
LDA.l PurpleChest_Item_Player : STA.l !MULTIWORLD_ITEM_PLAYER_ID
|
LDA.l PurpleChest_Item_Player : STA.l !MULTIWORLD_ITEM_PLAYER_ID
|
||||||
PLP : PLA
|
PLP : PLA
|
||||||
|
|
||||||
JSL Link_ReceiveItem ; thing we wrote over
|
; what we wrote over
|
||||||
RTL
|
JSL Link_ReceiveItem
|
||||||
|
LDA.l NpcFlagsVanilla
|
||||||
|
ORA.b #$10
|
||||||
|
STA.l NpcFlagsVanilla
|
||||||
|
|
||||||
|
.no_take_shield
|
||||||
|
RTL
|
||||||
}
|
}
|
||||||
|
|
||||||
Multiworld_Hobo_GrantBottle:
|
Multiworld_Hobo_GrantBottle:
|
||||||
{
|
{
|
||||||
PHA : PHP
|
PHA
|
||||||
SEP #$20
|
JSL ShieldCheck
|
||||||
LDA.l HoboItem_Player : STA.l !MULTIWORLD_ITEM_PLAYER_ID
|
PLA
|
||||||
PLP : PLA
|
BCC .no_take_shield
|
||||||
|
|
||||||
JSL Link_ReceiveItem ; thing we wrote over
|
; first bit we wrote over
|
||||||
RTL
|
LDX.b OverworldIndex
|
||||||
|
LDA.l OverworldEventDataWRAM, X
|
||||||
|
ORA.b #$20
|
||||||
|
STA.l OverworldEventDataWRAM, X
|
||||||
|
|
||||||
|
LDA.l HoboItem_Player : STA.l !MULTIWORLD_ITEM_PLAYER_ID
|
||||||
|
|
||||||
|
; second bit we wrote over
|
||||||
|
JSL Link_ReceiveItem
|
||||||
|
LDA.l NpcFlagsVanilla
|
||||||
|
ORA.b #$01
|
||||||
|
STA.l NpcFlagsVanilla
|
||||||
|
|
||||||
|
.no_take_shield
|
||||||
|
RTL
|
||||||
}
|
}
|
||||||
|
|
||||||
Multiworld_MasterSword_GrantToPlayer:
|
Multiworld_MasterSword_GrantToPlayer:
|
||||||
|
|||||||
32
newhud.asm
32
newhud.asm
@@ -273,15 +273,10 @@ NewHUD_DrawMagicMeter:
|
|||||||
STA.w CurrentMagic
|
STA.w CurrentMagic
|
||||||
TAY
|
TAY
|
||||||
|
|
||||||
|
LDA.b FrameCounter
|
||||||
REP #$30
|
REP #$30
|
||||||
LDA.w #$0002
|
AND.w #$000C
|
||||||
|
LSR
|
||||||
; ; cycle through colors
|
|
||||||
; LDA.b FrameCounter
|
|
||||||
; REP #$30
|
|
||||||
; AND.w #$000C
|
|
||||||
; LSR
|
|
||||||
|
|
||||||
BRA .recolor
|
BRA .recolor
|
||||||
|
|
||||||
.set_index ; this branch is always 0000 when taken
|
.set_index ; this branch is always 0000 when taken
|
||||||
@@ -314,16 +309,16 @@ MagicMeterColorMasks:
|
|||||||
;================================================================================
|
;================================================================================
|
||||||
PrizeIconTiles_Transparent:
|
PrizeIconTiles_Transparent:
|
||||||
dw $0000 ; no icon
|
dw $0000 ; no icon
|
||||||
dw $2891 ; crystal 1
|
dw $2978 ; crystal 1
|
||||||
dw $2892 ; crystal 2
|
dw $2979 ; crystal 2
|
||||||
dw $2893 ; crystal 3
|
dw $297A ; crystal 3
|
||||||
dw $2894 ; crystal 4
|
dw $297B ; crystal 4
|
||||||
dw $2895 ; crystal 5
|
dw $297C ; crystal 5
|
||||||
dw $2896 ; crystal 6
|
dw $297D ; crystal 6
|
||||||
dw $2897 ; crystal 7
|
dw $297E ; crystal 7
|
||||||
dw $2935 ; green pendant
|
dw $2963 ; green pendant
|
||||||
dw $2936 ; blue pendant
|
dw $295E ; blue pendant
|
||||||
dw $2937 ; red pendant
|
dw $296E ; red pendant
|
||||||
|
|
||||||
;================================================================================
|
;================================================================================
|
||||||
DrawCompassCounts:
|
DrawCompassCounts:
|
||||||
@@ -391,7 +386,6 @@ RTS
|
|||||||
;================================================================================
|
;================================================================================
|
||||||
DrawMapCounts:
|
DrawMapCounts:
|
||||||
LDA.l MapHUDMode : BEQ .done
|
LDA.l MapHUDMode : BEQ .done
|
||||||
LDA.l GenericKeys : BNE .done ; generator don't have an accurrate count of key doors in this case
|
|
||||||
|
|
||||||
; no map needed if this bit is set
|
; no map needed if this bit is set
|
||||||
BIT.b #$02 : BNE .draw_map_count
|
BIT.b #$02 : BNE .draw_map_count
|
||||||
|
|||||||
196
newitems.asm
196
newitems.asm
@@ -155,8 +155,8 @@ AddReceivedItemExpandedGetItem:
|
|||||||
PHA : LDA.l !MULTIWORLD_ITEM_PLAYER_ID : BEQ +
|
PHA : LDA.l !MULTIWORLD_ITEM_PLAYER_ID : BEQ +
|
||||||
PLA : BRA .done
|
PLA : BRA .done
|
||||||
+ PLA
|
+ PLA
|
||||||
JSR ItemBehavior
|
JSR ItemBehavior
|
||||||
SEP #$30
|
SEP #$30
|
||||||
.done
|
.done
|
||||||
PLB : PLX
|
PLB : PLX
|
||||||
LDA.w ItemReceiptMethod : CMP.b #$01 ; thing we wrote over
|
LDA.w ItemReceiptMethod : CMP.b #$01 ; thing we wrote over
|
||||||
@@ -229,13 +229,13 @@ ItemBehavior:
|
|||||||
JSR .increment_sword
|
JSR .increment_sword
|
||||||
RTS
|
RTS
|
||||||
|
|
||||||
.fighter_shield
|
.fighter_shield
|
||||||
.red_shield
|
.red_shield
|
||||||
.mirror_shield
|
.mirror_shield
|
||||||
SEP #$10
|
SEP #$10
|
||||||
LDA.l ProgressiveFlag : BEQ +
|
LDA.l ProgressiveFlag : BEQ +
|
||||||
LDA.l HighestShield : INC : TAX
|
LDA.l HighestShield : INC : TAX
|
||||||
JSR .increment_shield
|
JSR .increment_shield
|
||||||
+ RTS
|
+ RTS
|
||||||
|
|
||||||
.blue_mail
|
.blue_mail
|
||||||
@@ -269,7 +269,7 @@ ItemBehavior:
|
|||||||
.prog_shield
|
.prog_shield
|
||||||
SEP #$10
|
SEP #$10
|
||||||
LDA.l HighestShield : INC : TAX
|
LDA.l HighestShield : INC : TAX
|
||||||
JSR .increment_shield
|
JSR .increment_shield
|
||||||
REP #$10
|
REP #$10
|
||||||
RTS
|
RTS
|
||||||
|
|
||||||
@@ -282,13 +282,13 @@ ItemBehavior:
|
|||||||
|
|
||||||
.bow
|
.bow
|
||||||
BIT.b #$40 : BNE .silversbow
|
BIT.b #$40 : BNE .silversbow
|
||||||
LDA.b #$01 : STA.l BowEquipment
|
LDA.b #$01 : STA.l BowEquipment
|
||||||
RTS
|
RTS
|
||||||
|
|
||||||
.silversbow
|
.silversbow
|
||||||
LDA.l BowTracking : ORA.b #$40 : STA.l BowTracking
|
LDA.l BowTracking : ORA.b #$40 : STA.l BowTracking
|
||||||
LDA.l SilverArrowsUseRestriction : BNE +
|
LDA.l SilverArrowsUseRestriction : BNE +
|
||||||
LDA.b #03 : STA.l BowEquipment ; set bow to silver
|
LDA.b #03 : STA.l BowEquipment ; set bow to silver
|
||||||
+
|
+
|
||||||
LDA.b #$01 : STA.l BowEquipment
|
LDA.b #$01 : STA.l BowEquipment
|
||||||
RTS
|
RTS
|
||||||
@@ -331,16 +331,16 @@ ItemBehavior:
|
|||||||
.bow_and_arrows
|
.bow_and_arrows
|
||||||
LDA.l BowTracking : BIT.b #$40 : BEQ .no_silvers
|
LDA.l BowTracking : BIT.b #$40 : BEQ .no_silvers
|
||||||
LDA.l SilverArrowsUseRestriction : BNE .no_silvers
|
LDA.l SilverArrowsUseRestriction : BNE .no_silvers
|
||||||
LDA.l CurrentArrows : BEQ +
|
LDA.l CurrentArrows : BEQ +
|
||||||
LDA.b #04 : STA.l BowEquipment
|
LDA.b #04 : STA.l BowEquipment
|
||||||
|
BRA .store_bow
|
||||||
|
+
|
||||||
|
LDA.b #$03
|
||||||
BRA .store_bow
|
BRA .store_bow
|
||||||
+
|
|
||||||
LDA.b #$03
|
|
||||||
BRA .store_bow
|
|
||||||
.no_silvers
|
.no_silvers
|
||||||
LDA.l CurrentArrows : BEQ +
|
LDA.l CurrentArrows : BEQ +
|
||||||
LDA.b #02
|
LDA.b #02
|
||||||
BRA .store_bow
|
BRA .store_bow
|
||||||
+
|
+
|
||||||
LDA.b #$01
|
LDA.b #$01
|
||||||
.store_bow
|
.store_bow
|
||||||
@@ -350,13 +350,13 @@ ItemBehavior:
|
|||||||
.silver_bow
|
.silver_bow
|
||||||
LDA.b #$40 : ORA.l BowTracking : STA.l BowTracking
|
LDA.b #$40 : ORA.l BowTracking : STA.l BowTracking
|
||||||
LDA.l SilverArrowsUseRestriction : BNE .noequip
|
LDA.l SilverArrowsUseRestriction : BNE .noequip
|
||||||
LDA.l SilverArrowsAutoEquip : AND.b #$01 : BEQ .noequip
|
LDA.l SilverArrowsAutoEquip : AND.b #$01 : BEQ .noequip
|
||||||
LDA.l CurrentArrows : BNE + ; check arrows
|
LDA.l CurrentArrows : BNE + ; check arrows
|
||||||
LDA.b #$03 : BRA ++ ; bow without arrow
|
LDA.b #$03 : BRA ++ ; bow without arrow
|
||||||
+
|
+
|
||||||
LDA.b #$04 ; bow with arrow
|
LDA.b #$04 ; bow with arrow
|
||||||
++
|
++
|
||||||
STA.l BowEquipment
|
STA.l BowEquipment
|
||||||
.noequip
|
.noequip
|
||||||
RTS
|
RTS
|
||||||
|
|
||||||
@@ -385,7 +385,7 @@ ItemBehavior:
|
|||||||
.master_sword_safe
|
.master_sword_safe
|
||||||
SEP #$10
|
SEP #$10
|
||||||
LDA.l SwordEquipment : CMP.b #$02 : !BGE + ; skip if we have a better sword
|
LDA.l SwordEquipment : CMP.b #$02 : !BGE + ; skip if we have a better sword
|
||||||
LDA.b #$02 : STA.l SwordEquipment ; set master sword
|
LDA.b #$02 : STA.l SwordEquipment ; set master sword
|
||||||
+
|
+
|
||||||
LDX.b #$02
|
LDX.b #$02
|
||||||
JSR .increment_sword
|
JSR .increment_sword
|
||||||
@@ -426,20 +426,20 @@ ItemBehavior:
|
|||||||
.silver_arrows
|
.silver_arrows
|
||||||
LDA.l BowTracking : ORA.b #$40 : STA.l BowTracking
|
LDA.l BowTracking : ORA.b #$40 : STA.l BowTracking
|
||||||
LDA.l SilverArrowsUseRestriction : BNE ++
|
LDA.l SilverArrowsUseRestriction : BNE ++
|
||||||
LDA.l SilverArrowsAutoEquip : AND.b #$01 : BEQ ++
|
LDA.l SilverArrowsAutoEquip : AND.b #$01 : BEQ ++
|
||||||
LDA.l BowEquipment : BEQ ++ : CMP.b #$03 : !BGE +
|
LDA.l BowEquipment : BEQ ++ : CMP.b #$03 : !BGE +
|
||||||
!ADD.b #$02 : STA.l BowEquipment ; switch to silver bow
|
!ADD.b #$02 : STA.l BowEquipment ; switch to silver bow
|
||||||
+
|
+
|
||||||
++
|
++
|
||||||
LDA.l ArrowMode : BEQ +
|
LDA.l ArrowMode : BEQ +
|
||||||
LDA.b #$01 : STA.l ArrowsFiller
|
LDA.b #$01 : STA.l ArrowsFiller
|
||||||
+
|
+
|
||||||
RTS
|
RTS
|
||||||
|
|
||||||
.single_arrow
|
.single_arrow
|
||||||
LDA.l ArrowMode : BEQ +
|
LDA.l ArrowMode : BEQ +
|
||||||
LDA.l CurrentArrows : INC : STA.l CurrentArrows ; Should be sole write to this address
|
LDA.l CurrentArrows : INC : STA.l CurrentArrows ; Should be sole write to this address
|
||||||
LDA.b #$01 : STA.l UpdateHUDFlag ; in retro/rupee bow mode.
|
LDA.b #$01 : STA.l UpdateHUDFlag ; in retro/rupee bow mode.
|
||||||
+
|
+
|
||||||
RTS
|
RTS
|
||||||
|
|
||||||
@@ -474,7 +474,7 @@ ItemBehavior:
|
|||||||
.triforce
|
.triforce
|
||||||
LDA.b OverworldIndex : CMP.b #$80 : BNE +
|
LDA.b OverworldIndex : CMP.b #$80 : BNE +
|
||||||
LDA.b LinkPosX+1 : BNE +
|
LDA.b LinkPosX+1 : BNE +
|
||||||
JSL ActivateGoal
|
JSL ActivateGoal
|
||||||
+
|
+
|
||||||
RTS
|
RTS
|
||||||
|
|
||||||
@@ -484,10 +484,10 @@ ItemBehavior:
|
|||||||
LDA.l GoalCounter : INC : STA.l GoalCounter
|
LDA.l GoalCounter : INC : STA.l GoalCounter
|
||||||
CMP.w GoalItemRequirement : BCC +
|
CMP.w GoalItemRequirement : BCC +
|
||||||
LDA.l TurnInGoalItems : AND.w #$00FF : BNE +
|
LDA.l TurnInGoalItems : AND.w #$00FF : BNE +
|
||||||
SEP #$20 ; set 8-bit accumulator
|
SEP #$20 ; set 8-bit accumulator
|
||||||
LDA.b OverworldIndex : CMP.b #$80 : BNE +
|
LDA.b OverworldIndex : CMP.b #$80 : BNE +
|
||||||
LDA.b LinkPosX+1 : BNE +
|
LDA.b LinkPosX+1 : BNE +
|
||||||
JSL ActivateGoal
|
JSL ActivateGoal
|
||||||
+
|
+
|
||||||
SEP #$20 ; set 8-bit accumulator
|
SEP #$20 ; set 8-bit accumulator
|
||||||
RTS
|
RTS
|
||||||
@@ -559,8 +559,8 @@ ItemBehavior:
|
|||||||
LSR
|
LSR
|
||||||
AND.w #$000F : TAX
|
AND.w #$000F : TAX
|
||||||
ASL : CMP.w DungeonID : BEQ .same_dungeon
|
ASL : CMP.w DungeonID : BEQ .same_dungeon
|
||||||
LDA.l DungeonKeys,X : INC : STA.l DungeonKeys,X
|
LDA.l DungeonKeys,X : INC : STA.l DungeonKeys,X
|
||||||
RTS
|
RTS
|
||||||
.same_dungeon
|
.same_dungeon
|
||||||
SEP #$20
|
SEP #$20
|
||||||
LDA.l CurrentSmallKeys : INC : STA.l CurrentSmallKeys : STA.l DungeonKeys,X
|
LDA.l CurrentSmallKeys : INC : STA.l CurrentSmallKeys : STA.l DungeonKeys,X
|
||||||
@@ -575,69 +575,69 @@ ItemBehavior:
|
|||||||
|
|
||||||
.hc_smallkey
|
.hc_smallkey
|
||||||
LDA.w DungeonID : CMP.b #$03 : BCC .same_dungeon_hc
|
LDA.w DungeonID : CMP.b #$03 : BCC .same_dungeon_hc
|
||||||
LDA.l HyruleCastleKeys : INC : STA.l HyruleCastleKeys
|
LDA.l HyruleCastleKeys : INC : STA.l HyruleCastleKeys
|
||||||
LDA.l SewerKeys : INC : STA.l SewerKeys
|
LDA.l SewerKeys : INC : STA.l SewerKeys
|
||||||
RTS
|
RTS
|
||||||
|
|
||||||
.generic_smallkey
|
.generic_smallkey
|
||||||
LDA.l GenericKeys : BEQ .normal
|
LDA.l GenericKeys : BEQ .normal
|
||||||
LDA.l CurrentSmallKeys : INC
|
LDA.l CurrentSmallKeys : INC
|
||||||
STA.l CurrentGenericKeys : STA.l CurrentSmallKeys
|
STA.l CurrentGenericKeys : STA.l CurrentSmallKeys
|
||||||
RTS
|
RTS
|
||||||
.normal
|
.normal
|
||||||
LDA.w DungeonID : BMI +
|
LDA.w DungeonID : BMI +
|
||||||
LDA.l CurrentSmallKeys : INC : STA.l CurrentSmallKeys
|
LDA.l CurrentSmallKeys : INC : STA.l CurrentSmallKeys
|
||||||
RTS
|
RTS
|
||||||
+
|
+
|
||||||
RTS
|
RTS
|
||||||
|
|
||||||
.increment_sword
|
.increment_sword
|
||||||
LDA.l HighestSword
|
LDA.l HighestSword
|
||||||
INC : STA.b Scrap04 : CPX.b Scrap04 : BCC + ; don't increment unless we're getting a better sword
|
INC : STA.b Scrap04 : CPX.b Scrap04 : BCC + ; don't increment unless we're getting a better sword
|
||||||
TXA : STA.l HighestSword
|
TXA : STA.l HighestSword
|
||||||
+
|
+
|
||||||
RTS
|
RTS
|
||||||
|
|
||||||
.increment_shield
|
.increment_shield
|
||||||
LDA.l HighestShield
|
LDA.l HighestShield
|
||||||
INC : STA.b Scrap04 : CPX.b Scrap04 : BCC + ; don't increment unless we're getting a better shield
|
INC : STA.b Scrap04 : CPX.b Scrap04 : BCC + ; don't increment unless we're getting a better shield
|
||||||
TXA : STA.l HighestShield
|
TXA : STA.l HighestShield
|
||||||
+
|
+
|
||||||
RTS
|
RTS
|
||||||
|
|
||||||
.increment_mail
|
.increment_mail
|
||||||
LDA.l HighestMail
|
LDA.l HighestMail
|
||||||
INC : STA.b Scrap04 : CPX.b Scrap04 : BCC + ; don't increment unless we're getting a better mail
|
INC : STA.b Scrap04 : CPX.b Scrap04 : BCC + ; don't increment unless we're getting a better mail
|
||||||
TXA : STA.l HighestMail
|
TXA : STA.l HighestMail
|
||||||
+
|
+
|
||||||
RTS
|
RTS
|
||||||
|
|
||||||
.increment_bigkey
|
.increment_bigkey
|
||||||
SEP #$20
|
SEP #$20
|
||||||
LDA.l StatsLocked : BNE +
|
LDA.l StatsLocked : BNE +
|
||||||
LDA.l BigKeysBigChests
|
LDA.l BigKeysBigChests
|
||||||
CLC : ADC.b #$10
|
CLC : ADC.b #$10
|
||||||
STA.l BigKeysBigChests
|
STA.l BigKeysBigChests
|
||||||
+
|
+
|
||||||
RTS
|
RTS
|
||||||
|
|
||||||
.increment_map
|
.increment_map
|
||||||
SEP #$20
|
SEP #$20
|
||||||
LDA.l StatsLocked : BNE +
|
LDA.l StatsLocked : BNE +
|
||||||
LDA.l MapsCompasses
|
LDA.l MapsCompasses
|
||||||
CLC : ADC.b #$10
|
CLC : ADC.b #$10
|
||||||
STA.l MapsCompasses
|
STA.l MapsCompasses
|
||||||
JSL MaybeFlagMapTotalPickup
|
JSL MaybeFlagMapTotalPickup
|
||||||
+
|
+
|
||||||
RTS
|
RTS
|
||||||
|
|
||||||
.increment_compass
|
.increment_compass
|
||||||
SEP #$20
|
SEP #$20
|
||||||
LDA.l StatsLocked : BNE +
|
LDA.l StatsLocked : BNE +
|
||||||
LDA.l MapsCompasses : INC : AND.b #$0F : TAX
|
LDA.l MapsCompasses : INC : AND.b #$0F : TAX
|
||||||
LDA.l MapsCompasses : AND.b #$F0 : STA.l MapsCompasses
|
LDA.l MapsCompasses : AND.b #$F0 : STA.l MapsCompasses
|
||||||
TXA : ORA.l MapsCompasses : STA.l MapsCompasses
|
TXA : ORA.l MapsCompasses : STA.l MapsCompasses
|
||||||
JSL MaybeFlagCompassTotalPickup
|
JSL MaybeFlagCompassTotalPickup
|
||||||
+
|
+
|
||||||
RTS
|
RTS
|
||||||
|
|
||||||
@@ -647,7 +647,7 @@ ItemBehavior:
|
|||||||
SEC : SBC.b #$37
|
SEC : SBC.b #$37
|
||||||
TAX
|
TAX
|
||||||
LDA.w PendantMasks,X : AND.l PendantsField : BNE +
|
LDA.w PendantMasks,X : AND.l PendantsField : BNE +
|
||||||
LDA.l PendantCounter : INC : STA.l PendantCounter
|
LDA.l PendantCounter : INC : STA.l PendantCounter
|
||||||
+
|
+
|
||||||
RTS
|
RTS
|
||||||
|
|
||||||
@@ -663,15 +663,15 @@ ItemBehavior:
|
|||||||
LDA.w #$0000
|
LDA.w #$0000
|
||||||
SEC
|
SEC
|
||||||
-
|
-
|
||||||
ROL
|
ROL
|
||||||
DEX
|
DEX
|
||||||
BPL -
|
BPL -
|
||||||
SEP #$20
|
SEP #$20
|
||||||
TAX
|
TAX
|
||||||
AND.l CrystalsField : BNE +
|
AND.l CrystalsField : BNE +
|
||||||
TXA
|
TXA
|
||||||
ORA.l CrystalsField : STA.l CrystalsField
|
ORA.l CrystalsField : STA.l CrystalsField
|
||||||
LDA.l CrystalCounter : INC : STA.l CrystalCounter
|
LDA.l CrystalCounter : INC : STA.l CrystalCounter
|
||||||
+
|
+
|
||||||
.done
|
.done
|
||||||
RTS
|
RTS
|
||||||
@@ -682,56 +682,56 @@ ItemBehavior:
|
|||||||
.bee_trap
|
.bee_trap
|
||||||
SEP #$30
|
SEP #$30
|
||||||
LDA.b #$79 : JSL Sprite_SpawnDynamically : BMI + ; DashBeeHive_SpawnBee
|
LDA.b #$79 : JSL Sprite_SpawnDynamically : BMI + ; DashBeeHive_SpawnBee
|
||||||
LDA.b LinkPosX : CLC : ADC.b #$03 : AND.b #$F8 : STA.w SpritePosXLow,Y
|
LDA.b LinkPosX : CLC : ADC.b #$03 : AND.b #$F8 : STA.w SpritePosXLow,Y
|
||||||
LDA.b LinkPosX+1 : ADC.b #$00 : STA.w SpritePosXHigh,Y ; round X to nearest 8
|
LDA.b LinkPosX+1 : ADC.b #$00 : STA.w SpritePosXHigh,Y ; round X to nearest 8
|
||||||
LDA.b LinkPosY : STA.w SpritePosYLow, Y : LDA.b LinkPosY+1 : STA.w SpritePosYHigh, Y
|
LDA.b LinkPosY : STA.w SpritePosYLow, Y : LDA.b LinkPosY+1 : STA.w SpritePosYHigh, Y
|
||||||
LDA.b LinkLayer : STA.w SpriteLayer,Y ; spawns on same layer as link
|
LDA.b LinkLayer : STA.w SpriteLayer,Y ; spawns on same layer as link
|
||||||
+
|
+
|
||||||
RTS
|
RTS
|
||||||
|
|
||||||
.good_bee
|
.good_bee
|
||||||
SEP #$30
|
SEP #$30
|
||||||
LDA.b #$79 : JSL Sprite_SpawnDynamically : BMI + ; DashBeeHive_SpawnBee
|
LDA.b #$79 : JSL Sprite_SpawnDynamically : BMI + ; DashBeeHive_SpawnBee
|
||||||
LDA.b LinkPosX : CLC : ADC.b #$03 : AND.b #$F8 : STA.w SpritePosXLow,Y
|
LDA.b LinkPosX : CLC : ADC.b #$03 : AND.b #$F8 : STA.w SpritePosXLow,Y
|
||||||
LDA.b LinkPosX+1 : ADC.b #$00 : STA.w SpritePosXHigh,Y ; round X to nearest 8
|
LDA.b LinkPosX+1 : ADC.b #$00 : STA.w SpritePosXHigh,Y ; round X to nearest 8
|
||||||
LDA.b LinkPosY : STA.w SpritePosYLow, Y : LDA.b LinkPosY+1 : STA.w SpritePosYHigh, Y
|
LDA.b LinkPosY : STA.w SpritePosYLow, Y : LDA.b LinkPosY+1 : STA.w SpritePosYHigh, Y
|
||||||
LDA.b LinkLayer : STA.w SpriteLayer,Y ; spawns on same layer as link
|
LDA.b LinkLayer : STA.w SpriteLayer,Y ; spawns on same layer as link
|
||||||
JSL GoldBee_SpawnSelf_SetProperties
|
JSL GoldBee_SpawnSelf_SetProperties
|
||||||
+
|
+
|
||||||
RTS
|
RTS
|
||||||
|
|
||||||
.apples
|
.apples
|
||||||
SEP #$30
|
SEP #$30
|
||||||
LDA.b #$AC : JSL Sprite_SpawnDynamically : BMI +
|
LDA.b #$AC : JSL Sprite_SpawnDynamically : BMI +
|
||||||
LDA.b LinkPosX : CLC : ADC.b #$03 : AND.b #$F8 : STA.w SpritePosXLow,Y
|
LDA.b LinkPosX : CLC : ADC.b #$03 : AND.b #$F8 : STA.w SpritePosXLow,Y
|
||||||
LDA.b LinkPosX+1 : ADC.b #$00 : STA.w SpritePosXHigh,Y ; round X to nearest 8
|
LDA.b LinkPosX+1 : ADC.b #$00 : STA.w SpritePosXHigh,Y ; round X to nearest 8
|
||||||
LDA.b LinkPosY : SEC : SBC.b #$10 : STA.w SpritePosYLow,Y
|
LDA.b LinkPosY : SEC : SBC.b #$10 : STA.w SpritePosYLow,Y
|
||||||
LDA.b LinkPosY+1 : SBC.b #$00 : STA.w SpritePosYHigh,Y ; move up 16 pixels
|
LDA.b LinkPosY+1 : SBC.b #$00 : STA.w SpritePosYHigh,Y ; move up 16 pixels
|
||||||
LDA.b LinkLayer : STA.w SpriteLayer,Y ; spawns on same layer as link
|
LDA.b LinkLayer : STA.w SpriteLayer,Y ; spawns on same layer as link
|
||||||
LDA.b #$FF : STA.w EnemyStunTimer,Y ; allows them to expire
|
LDA.b #$FF : STA.w EnemyStunTimer,Y ; allows them to expire
|
||||||
+
|
+
|
||||||
RTS
|
RTS
|
||||||
|
|
||||||
.fairy
|
.fairy
|
||||||
SEP #$30
|
SEP #$30
|
||||||
LDA.b #$E3 : JSL Sprite_SpawnDynamically : BMI +
|
LDA.b #$E3 : JSL Sprite_SpawnDynamically : BMI +
|
||||||
LDA.b LinkPosX : CLC : ADC.b #$03 : AND.b #$F8 : STA.w SpritePosXLow,Y
|
LDA.b LinkPosX : CLC : ADC.b #$03 : AND.b #$F8 : STA.w SpritePosXLow,Y
|
||||||
LDA.b LinkPosX+1 : ADC.b #$00 : STA.w SpritePosXHigh,Y ; round X to nearest 8
|
LDA.b LinkPosX+1 : ADC.b #$00 : STA.w SpritePosXHigh,Y ; round X to nearest 8
|
||||||
LDA.b LinkPosY : SEC : SBC.b #$10 : STA.w SpritePosYLow,Y
|
LDA.b LinkPosY : SEC : SBC.b #$10 : STA.w SpritePosYLow,Y
|
||||||
LDA.b LinkPosY+1 : SBC.b #$00 : STA.w SpritePosYHigh,Y ; move up 16 pixels
|
LDA.b LinkPosY+1 : SBC.b #$00 : STA.w SpritePosYHigh,Y ; move up 16 pixels
|
||||||
LDA.b LinkLayer : STA.w SpriteLayer,Y ; spawns on same layer as link
|
LDA.b LinkLayer : STA.w SpriteLayer,Y ; spawns on same layer as link
|
||||||
LDA.b #$FF : STA.w EnemyStunTimer,Y ; allows them to expire
|
LDA.b #$FF : STA.w EnemyStunTimer,Y ; allows them to expire
|
||||||
+
|
+
|
||||||
RTS
|
RTS
|
||||||
|
|
||||||
.chicken
|
.chicken
|
||||||
SEP #$30
|
SEP #$30
|
||||||
LDA.b #$0B : JSL Sprite_SpawnDynamically : BMI +
|
LDA.b #$0B : JSL Sprite_SpawnDynamically : BMI +
|
||||||
LDA.b LinkPosX : CLC : ADC.b #$03 : AND.b #$F8 : STA.w SpritePosXLow,Y
|
LDA.b LinkPosX : CLC : ADC.b #$03 : AND.b #$F8 : STA.w SpritePosXLow,Y
|
||||||
LDA.b LinkPosX+1 : ADC.b #$00 : STA.w SpritePosXHigh,Y ; round X to nearest 8
|
LDA.b LinkPosX+1 : ADC.b #$00 : STA.w SpritePosXHigh,Y ; round X to nearest 8
|
||||||
LDA.b LinkPosY : SEC : SBC.b #$08 : STA.w SpritePosYLow,Y
|
LDA.b LinkPosY : SEC : SBC.b #$08 : STA.w SpritePosYLow,Y
|
||||||
LDA.b LinkPosY+1 : SBC.b #$00 : STA.w SpritePosYHigh,Y ; move up 8 pixels
|
LDA.b LinkPosY+1 : SBC.b #$00 : STA.w SpritePosYHigh,Y ; move up 8 pixels
|
||||||
LDA.b LinkLayer : STA.w SpriteLayer,Y ; spawns on same layer as link
|
LDA.b LinkLayer : STA.w SpriteLayer,Y ; spawns on same layer as link
|
||||||
+
|
+
|
||||||
RTS
|
RTS
|
||||||
|
|
||||||
@@ -804,7 +804,7 @@ ResolveLootID:
|
|||||||
CMP.l ProgressiveSwordLimit : BCC +
|
CMP.l ProgressiveSwordLimit : BCC +
|
||||||
LDA.l ProgressiveSwordReplacement
|
LDA.l ProgressiveSwordReplacement
|
||||||
JMP .get_item
|
JMP .get_item
|
||||||
++ LDA.l SwordEquipment
|
++ LDA.l SwordEquipment
|
||||||
+
|
+
|
||||||
TAX
|
TAX
|
||||||
LDA.w .prog_sword_ids,X
|
LDA.w .prog_sword_ids,X
|
||||||
@@ -820,7 +820,7 @@ ResolveLootID:
|
|||||||
CMP.l ProgressiveShieldLimit : BCC +
|
CMP.l ProgressiveShieldLimit : BCC +
|
||||||
LDA.l ProgressiveShieldReplacement
|
LDA.l ProgressiveShieldReplacement
|
||||||
JMP .get_item
|
JMP .get_item
|
||||||
++ LDA.l HighestShield
|
++ LDA.l HighestShield
|
||||||
+
|
+
|
||||||
TAX
|
TAX
|
||||||
LDA.w .shields_ids,X
|
LDA.w .shields_ids,X
|
||||||
@@ -836,7 +836,7 @@ ResolveLootID:
|
|||||||
LDA.l ProgressiveArmorReplacement
|
LDA.l ProgressiveArmorReplacement
|
||||||
JMP .get_item
|
JMP .get_item
|
||||||
+
|
+
|
||||||
++ LDA.l ArmorEquipment
|
++ LDA.l ArmorEquipment
|
||||||
TAX
|
TAX
|
||||||
LDA.w .armor_ids,X
|
LDA.w .armor_ids,X
|
||||||
JMP .have_item
|
JMP .have_item
|
||||||
@@ -935,7 +935,7 @@ BottleListExpanded:
|
|||||||
db $16, $2B, $2C, $2D, $3D, $3C, $48
|
db $16, $2B, $2C, $2D, $3D, $3C, $48
|
||||||
|
|
||||||
PotionListExpanded:
|
PotionListExpanded:
|
||||||
db $66, $FF, $2E, $2F, $30, $FF, $0E
|
db $2E, $2F, $30, $FF, $0E
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
HandleBowTracking:
|
HandleBowTracking:
|
||||||
; In: A - Item Receipt ID
|
; In: A - Item Receipt ID
|
||||||
@@ -1159,12 +1159,12 @@ JML StatsFinalPrep
|
|||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
ChestPrep:
|
ChestPrep:
|
||||||
LDA.b #$01 : STA.w ItemReceiptMethod
|
LDA.b #$01 : STA.w ItemReceiptMethod
|
||||||
JSL IncrementChestCounter
|
JSL IncrementChestCounter
|
||||||
LDA.l ServerRequestMode : BEQ +
|
LDA.l ServerRequestMode : BEQ +
|
||||||
JSL ChestItemServiceRequest
|
JSL ChestItemServiceRequest
|
||||||
RTL
|
RTL
|
||||||
+
|
+
|
||||||
LDY.b Scrap0C ; get item value
|
LDY.b Scrap0C ; get item value
|
||||||
SEC
|
SEC
|
||||||
RTL
|
RTL
|
||||||
|
|
||||||
|
|||||||
112
npcitems.asm
112
npcitems.asm
@@ -90,23 +90,25 @@ ItemSet_FairySword:
|
|||||||
RTL
|
RTL
|
||||||
|
|
||||||
ItemSet_SmithSword:
|
ItemSet_SmithSword:
|
||||||
PHA
|
PHA : LDA.l NpcFlags+1 : ORA.b #$04 : STA.l NpcFlags+1 : PLA
|
||||||
LDA.l NpcFlags+1 : ORA.b #$04 : STA.l NpcFlags+1
|
|
||||||
JSL UpdateLootHUD
|
|
||||||
PLA
|
|
||||||
RTL
|
RTL
|
||||||
|
|
||||||
ItemSet_MagicBat:
|
ItemSet_MagicBat:
|
||||||
PHA
|
PHA : LDA.l NpcFlags+1 : ORA.b #$80 : STA.l NpcFlags+1 : PLA
|
||||||
LDA.l NpcFlags+1 : ORA.b #$80 : STA.l NpcFlags+1
|
|
||||||
JSL UpdateLootHUD
|
|
||||||
PLA
|
|
||||||
RTL
|
RTL
|
||||||
|
|
||||||
ItemSet_OldMan:
|
ItemSet_OldMan:
|
||||||
PHA : LDA.l OldManItem_Player : STA.l !MULTIWORLD_ITEM_PLAYER_ID : PLA
|
PHA
|
||||||
|
JSL ShieldCheck
|
||||||
|
BCC .skip
|
||||||
|
|
||||||
|
LDA.l OldManItem_Player : STA.l !MULTIWORLD_ITEM_PLAYER_ID
|
||||||
|
PLA
|
||||||
JSL Link_ReceiveItem ; thing we wrote over
|
JSL Link_ReceiveItem ; thing we wrote over
|
||||||
PHA : LDA.l NpcFlags : ORA.b #$01 : STA.l NpcFlags : PLA
|
PHA
|
||||||
|
LDA.l NpcFlags : ORA.b #$01 : STA.l NpcFlags
|
||||||
|
.skip
|
||||||
|
PLA
|
||||||
RTL
|
RTL
|
||||||
|
|
||||||
ItemSet_ZoraKing:
|
ItemSet_ZoraKing:
|
||||||
@@ -114,26 +116,44 @@ ItemSet_ZoraKing:
|
|||||||
RTL
|
RTL
|
||||||
|
|
||||||
ItemSet_SickKid:
|
ItemSet_SickKid:
|
||||||
PHA : LDA.l SickKidItem_Player : STA.l !MULTIWORLD_ITEM_PLAYER_ID : PLA
|
PHA
|
||||||
|
JSL ShieldCheck
|
||||||
|
BCC .skip
|
||||||
|
|
||||||
|
LDA.l SickKidItem_Player : STA.l !MULTIWORLD_ITEM_PLAYER_ID
|
||||||
|
PLA
|
||||||
JSL Link_ReceiveItem ; thing we wrote over
|
JSL Link_ReceiveItem ; thing we wrote over
|
||||||
PHA
|
PHA
|
||||||
LDA.l NpcFlags : ORA.b #$04 : STA.l NpcFlags
|
LDA.l NpcFlags : ORA.b #$04 : STA.l NpcFlags
|
||||||
JSL UpdateLootHUD
|
.skip
|
||||||
PLA
|
PLA
|
||||||
RTL
|
RTL
|
||||||
|
|
||||||
ItemSet_TreeKid:
|
ItemSet_TreeKid:
|
||||||
PHA : LDA.l TreeKidItem_Player : STA.l !MULTIWORLD_ITEM_PLAYER_ID : PLA
|
PHA
|
||||||
|
JSL ShieldCheck
|
||||||
|
BCC .skip
|
||||||
|
|
||||||
|
LDA.l TreeKidItem_Player : STA.l !MULTIWORLD_ITEM_PLAYER_ID
|
||||||
|
PLA
|
||||||
JSL Link_ReceiveItem ; thing we wrote over
|
JSL Link_ReceiveItem ; thing we wrote over
|
||||||
PHA : LDA.l NpcFlags : ORA.b #$08 : STA.l NpcFlags : PLA
|
PHA
|
||||||
|
LDA.l NpcFlags : ORA.b #$08 : STA.l NpcFlags
|
||||||
|
.skip
|
||||||
|
PLA
|
||||||
RTL
|
RTL
|
||||||
|
|
||||||
ItemSet_Sahasrala:
|
ItemSet_Sahasrala:
|
||||||
PHA : LDA.l SahasralaItem_Player : STA.l !MULTIWORLD_ITEM_PLAYER_ID : PLA
|
PHA
|
||||||
|
JSL ShieldCheck
|
||||||
|
BCC .skip
|
||||||
|
|
||||||
|
LDA.l SahasralaItem_Player : STA.l !MULTIWORLD_ITEM_PLAYER_ID
|
||||||
|
PLA
|
||||||
JSL Link_ReceiveItem ; thing we wrote over
|
JSL Link_ReceiveItem ; thing we wrote over
|
||||||
PHA
|
PHA
|
||||||
LDA.l NpcFlags : ORA.b #$10 : STA.l NpcFlags
|
LDA.l NpcFlags : ORA.b #$10 : STA.l NpcFlags
|
||||||
JSL UpdateLootHUD
|
.skip
|
||||||
PLA
|
PLA
|
||||||
RTL
|
RTL
|
||||||
|
|
||||||
@@ -142,32 +162,42 @@ ItemSet_Catfish:
|
|||||||
RTL
|
RTL
|
||||||
|
|
||||||
ItemSet_Library:
|
ItemSet_Library:
|
||||||
PHA : LDA.l LibraryItem_Player : STA.l !MULTIWORLD_ITEM_PLAYER_ID : PLA
|
PHA
|
||||||
|
JSL ShieldCheck
|
||||||
|
BCC .skip
|
||||||
|
|
||||||
|
LDA.l LibraryItem_Player : STA.l !MULTIWORLD_ITEM_PLAYER_ID
|
||||||
|
PLA
|
||||||
JSL Link_ReceiveItem ; thing we wrote over
|
JSL Link_ReceiveItem ; thing we wrote over
|
||||||
PHA
|
PHA
|
||||||
LDA.l NpcFlags : ORA.b #$80 : STA.l NpcFlags
|
LDA.l NpcFlags : ORA.b #$80 : STA.l NpcFlags
|
||||||
JSL UpdateLootHUD
|
.skip
|
||||||
PLA
|
PLA
|
||||||
RTL
|
RTL
|
||||||
|
|
||||||
ItemSet_Mushroom:
|
ItemSet_Mushroom:
|
||||||
PHA
|
PHA
|
||||||
LDA.l NpcFlags+1 : ORA.b #$10 : STA.l NpcFlags+1
|
|
||||||
LDY.w SprSourceItemId, X ; Retrieve stored item type
|
LDY.w SprSourceItemId, X ; Retrieve stored item type
|
||||||
BNE +
|
BNE +
|
||||||
; if for any reason the item value is 0 reload it, just in case
|
; if for any reason the item value is 0 reload it, just in case
|
||||||
%GetPossiblyEncryptedItem(MushroomItem, SpriteItemValues) : TAY
|
%GetPossiblyEncryptedItem(MushroomItem, SpriteItemValues) : TAY
|
||||||
+
|
+
|
||||||
|
|
||||||
|
JSL ShieldCheck
|
||||||
|
BCC .skip
|
||||||
LDA.l MushroomItem_Player : STA.l !MULTIWORLD_ITEM_PLAYER_ID
|
LDA.l MushroomItem_Player : STA.l !MULTIWORLD_ITEM_PLAYER_ID
|
||||||
PLA
|
|
||||||
STZ.w ItemReceiptMethod ; thing we wrote over - the mushroom is an npc for item purposes apparently
|
STZ.w ItemReceiptMethod ; thing we wrote over - the mushroom is an npc for item purposes apparently
|
||||||
|
PLA
|
||||||
|
|
||||||
|
JSL Link_ReceiveItem
|
||||||
|
PHA
|
||||||
|
LDA.l NpcFlags+1 : ORA.b #$10 : STA.l NpcFlags+1
|
||||||
|
.skip
|
||||||
|
PLA
|
||||||
RTL
|
RTL
|
||||||
|
|
||||||
ItemSet_Powder:
|
ItemSet_Powder:
|
||||||
PHA
|
PHA : LDA.l NpcFlags+1 : ORA.b #$20 : STA.l NpcFlags+1 : PLA
|
||||||
LDA.l NpcFlags+1 : ORA.b #$20 : STA.l NpcFlags+1
|
|
||||||
JSL UpdateLootHUD
|
|
||||||
PLA
|
|
||||||
RTL
|
RTL
|
||||||
;================================================================================
|
;================================================================================
|
||||||
|
|
||||||
@@ -193,11 +223,25 @@ Set300RupeeNPCItem:
|
|||||||
+
|
+
|
||||||
LDA.w #$0000
|
LDA.w #$0000
|
||||||
LDY.b #$46 ; default to a normal 300 rupees
|
LDY.b #$46 ; default to a normal 300 rupees
|
||||||
.done
|
|
||||||
|
.done
|
||||||
SEP #$20
|
SEP #$20
|
||||||
STA.l !MULTIWORLD_ITEM_PLAYER_ID
|
STA.l !MULTIWORLD_ITEM_PLAYER_ID
|
||||||
|
JSL ShieldCheck
|
||||||
|
BCC .cant_take
|
||||||
|
|
||||||
|
LDA.w RoomItemsTaken
|
||||||
|
ORA.b #$40
|
||||||
|
STA.w RoomItemsTaken
|
||||||
|
|
||||||
PLP : PLA
|
PLP : PLA
|
||||||
RTL
|
SEC
|
||||||
|
RTL
|
||||||
|
|
||||||
|
.cant_take
|
||||||
|
PLP : PLA
|
||||||
|
CLC
|
||||||
|
RTL
|
||||||
|
|
||||||
;================================================================================
|
;================================================================================
|
||||||
; Randomize Zora King
|
; Randomize Zora King
|
||||||
@@ -241,16 +285,26 @@ MarkThrownItem:
|
|||||||
LDA.b OverworldIndex : CMP.b #$81 : BNE .catfish
|
LDA.b OverworldIndex : CMP.b #$81 : BNE .catfish
|
||||||
|
|
||||||
.zora
|
.zora
|
||||||
JSL ItemSet_ZoraKing
|
JSL ShieldCheck
|
||||||
|
BCC .skip
|
||||||
|
|
||||||
|
JSL ItemSet_ZoraKing
|
||||||
LDA.l ZoraItem_Player : STA.l !MULTIWORLD_ITEM_PLAYER_ID
|
LDA.l ZoraItem_Player : STA.l !MULTIWORLD_ITEM_PLAYER_ID
|
||||||
BRA .done
|
BRA .done
|
||||||
|
|
||||||
.catfish
|
.catfish
|
||||||
JSL ItemSet_Catfish
|
JSL ShieldCheck
|
||||||
|
BCC .skip
|
||||||
|
JSL ItemSet_Catfish
|
||||||
|
|
||||||
LDA.l CatfishItem_Player : STA.l !MULTIWORLD_ITEM_PLAYER_ID
|
LDA.l CatfishItem_Player : STA.l !MULTIWORLD_ITEM_PLAYER_ID
|
||||||
|
|
||||||
.done
|
.done
|
||||||
PLA
|
PLA
|
||||||
JSL Link_ReceiveItem ; thing we wrote over
|
JSL Link_ReceiveItem ; thing we wrote over
|
||||||
RTL
|
RTL
|
||||||
|
|
||||||
|
.skip
|
||||||
|
PLA
|
||||||
|
RTL
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
|
|||||||
@@ -291,10 +291,10 @@ RTL
|
|||||||
REP #$30
|
REP #$30
|
||||||
;-------------------------------------------------------------------------------
|
;-------------------------------------------------------------------------------
|
||||||
; dungeon names
|
; dungeon names
|
||||||
LDA.w #$2DA4
|
LDA.w #$2D50
|
||||||
LDY.w #00
|
LDY.w #00
|
||||||
|
|
||||||
.next_dungeon_name
|
.next_dungeon_name
|
||||||
LDX.w .dungeon_positions,Y
|
LDX.w .dungeon_positions,Y
|
||||||
STA.w GFXStripes+$0646,X
|
STA.w GFXStripes+$0646,X
|
||||||
INC
|
INC
|
||||||
@@ -310,10 +310,10 @@ RTL
|
|||||||
STA.w GFXStripes+$0706,X
|
STA.w GFXStripes+$0706,X
|
||||||
|
|
||||||
DEX : DEX
|
DEX : DEX
|
||||||
BPL --
|
BPL --
|
||||||
|
|
||||||
LDA.l HudFlag : AND.w #$0020 : BEQ +
|
LDA.l HudFlag : AND.w #$0020 : BEQ +
|
||||||
JMP .maps_and_compasses
|
JMP .maps_and_compasses
|
||||||
;-------------------------------------------------------------------------------
|
;-------------------------------------------------------------------------------
|
||||||
+
|
+
|
||||||
LDA.l HUDDungeonItems : AND.w #$0001 : BNE +
|
LDA.l HUDDungeonItems : AND.w #$0001 : BNE +
|
||||||
|
|||||||
471
pikit.asm
Normal file
471
pikit.asm
Normal file
@@ -0,0 +1,471 @@
|
|||||||
|
pushpc
|
||||||
|
org $89EB78
|
||||||
|
db $18, $1A, $AA ; replace uncle with pikit
|
||||||
|
|
||||||
|
org $80DCCE
|
||||||
|
db $1B ; load sprite sheet for pikit in link's house
|
||||||
|
|
||||||
|
org $80FC74
|
||||||
|
NOP #2 ; do not load rain-state sprites
|
||||||
|
|
||||||
|
org $8A8029
|
||||||
|
; move table slightly to center under pikit
|
||||||
|
db $C9, $C0, $DD
|
||||||
|
db $D0, $B8, $3C
|
||||||
|
pullpc
|
||||||
|
|
||||||
|
TuckLink:
|
||||||
|
; what we wrote over
|
||||||
|
STZ.w $037C
|
||||||
|
STZ.w $037D
|
||||||
|
|
||||||
|
LDA.b #$40 : STA.w $0FC2
|
||||||
|
LDA.b #$09 : STA.w $0FC3
|
||||||
|
|
||||||
|
LDA.b #$5A : STA.w $0FC4
|
||||||
|
LDA.b #$21 : STA.w $0FC5
|
||||||
|
|
||||||
|
RTL
|
||||||
|
|
||||||
|
LinkSnoring:
|
||||||
|
LDA.l ProgressIndicator
|
||||||
|
BNE +
|
||||||
|
|
||||||
|
LDA.b #$02
|
||||||
|
STA.l ProgressIndicator
|
||||||
|
LDA.b #$1D
|
||||||
|
LDY.b #$00
|
||||||
|
JSL Sprite_ShowMessageUnconditional
|
||||||
|
BRA ++
|
||||||
|
|
||||||
|
+
|
||||||
|
LDA.b FrameCounter
|
||||||
|
AND.b #$03
|
||||||
|
BNE ++
|
||||||
|
|
||||||
|
LDA.b $9C
|
||||||
|
CMP.b #$20
|
||||||
|
BEQ .lightened
|
||||||
|
|
||||||
|
DEC.b $9C
|
||||||
|
DEC.b $9D
|
||||||
|
|
||||||
|
++
|
||||||
|
; what we wrote over
|
||||||
|
LDA.b FrameCounter
|
||||||
|
AND.b #$1F
|
||||||
|
RTL
|
||||||
|
|
||||||
|
.lightened
|
||||||
|
INC.w $037C
|
||||||
|
INC.w $037D
|
||||||
|
RTL
|
||||||
|
|
||||||
|
LinkAwaken:
|
||||||
|
; what we wrote over
|
||||||
|
LDA.b #$06
|
||||||
|
STA.b LinkState
|
||||||
|
|
||||||
|
LDA.l ProgressFlags
|
||||||
|
ORA.b #$10
|
||||||
|
STA.l ProgressFlags
|
||||||
|
LDA.b #$01
|
||||||
|
STA.l StartingEntrance
|
||||||
|
RTL
|
||||||
|
|
||||||
|
BigChest_ShieldCheck:
|
||||||
|
PHY
|
||||||
|
LDY.b $0C
|
||||||
|
JSL ShieldCheck
|
||||||
|
STY.b $0C
|
||||||
|
PLY
|
||||||
|
BCC .no_open
|
||||||
|
LDA.l BigKeyField
|
||||||
|
AND.l BitMasks, X
|
||||||
|
.no_open
|
||||||
|
RTL
|
||||||
|
|
||||||
|
SmallChest_ShieldCheck:
|
||||||
|
PHY
|
||||||
|
LDY.b $0C
|
||||||
|
JSL ShieldCheck
|
||||||
|
STY.b $0C
|
||||||
|
PLY
|
||||||
|
BCC .no_open
|
||||||
|
LDA.w $0402
|
||||||
|
ORA.w RoomFlagMask, Y
|
||||||
|
.no_open
|
||||||
|
RTL
|
||||||
|
|
||||||
|
ShieldCheck:
|
||||||
|
PHP
|
||||||
|
REP #$30
|
||||||
|
PHX
|
||||||
|
TYA
|
||||||
|
AND.w #$00FF
|
||||||
|
TAX
|
||||||
|
LDA.l PikitItemList, X
|
||||||
|
AND.w #$00FF
|
||||||
|
BNE .replace
|
||||||
|
PLX
|
||||||
|
PLP
|
||||||
|
SEC
|
||||||
|
RTL
|
||||||
|
|
||||||
|
.replace
|
||||||
|
LDA.l ShieldEquipment
|
||||||
|
AND.w #$00FF
|
||||||
|
BNE .already_have_shield
|
||||||
|
TXA
|
||||||
|
STA.l PikitItem
|
||||||
|
LDY.w #$0004
|
||||||
|
PLX
|
||||||
|
PLP
|
||||||
|
SEC
|
||||||
|
RTL
|
||||||
|
|
||||||
|
.already_have_shield
|
||||||
|
SEP #$30
|
||||||
|
LDA.b #$3C
|
||||||
|
STA.w $012E
|
||||||
|
|
||||||
|
PHY
|
||||||
|
LDA.b #$98
|
||||||
|
LDY.b #$01
|
||||||
|
JSL Sprite_ShowMessageUnconditional
|
||||||
|
PLY
|
||||||
|
|
||||||
|
REP #$30
|
||||||
|
|
||||||
|
PLX
|
||||||
|
PLP
|
||||||
|
CLC
|
||||||
|
RTL
|
||||||
|
|
||||||
|
PikitSteal:
|
||||||
|
LDA.l ShieldEquipment
|
||||||
|
BNE .has_shield
|
||||||
|
JSL GetRandomInt
|
||||||
|
JML $9E8D73
|
||||||
|
|
||||||
|
.has_shield
|
||||||
|
LDA.b #$04
|
||||||
|
STA.w $0ED0, X
|
||||||
|
STA.w $0E90, X
|
||||||
|
LDA.b #$01
|
||||||
|
STA.w $0E30, X
|
||||||
|
|
||||||
|
STZ.w $012E
|
||||||
|
|
||||||
|
JML $9E8DC3
|
||||||
|
|
||||||
|
PikitDigest:
|
||||||
|
LDA.w $0ED0, X
|
||||||
|
CMP.b #$04
|
||||||
|
BNE +
|
||||||
|
|
||||||
|
STZ.w $0E90, X
|
||||||
|
|
||||||
|
LDA.b $6C
|
||||||
|
BNE + ; link is in a doorway; giving him an item could be scary :<
|
||||||
|
|
||||||
|
JSL IncrementPikitCounter
|
||||||
|
|
||||||
|
LDA.l PikitItem
|
||||||
|
CMP.b #$04
|
||||||
|
BEQ +
|
||||||
|
|
||||||
|
TAY
|
||||||
|
STZ.w ItemReceiptMethod
|
||||||
|
JSL Link_ReceiveItem
|
||||||
|
|
||||||
|
LDA.b #$04
|
||||||
|
STA.l PikitItem
|
||||||
|
+
|
||||||
|
|
||||||
|
; what we wrote over
|
||||||
|
STZ.w $0DA0, X
|
||||||
|
STZ.w $0ED0, X
|
||||||
|
|
||||||
|
RTL
|
||||||
|
|
||||||
|
MaybeFlagVoOChestGamePrize:
|
||||||
|
LDA.l $81EDA1, X
|
||||||
|
TAY
|
||||||
|
JSL ShieldCheck
|
||||||
|
BCC .cant_take
|
||||||
|
|
||||||
|
LDA.w RoomItemsTaken
|
||||||
|
ORA.b #$40
|
||||||
|
STA.w RoomItemsTaken
|
||||||
|
|
||||||
|
STX.b $C8
|
||||||
|
STY.b $0C
|
||||||
|
|
||||||
|
SEC
|
||||||
|
|
||||||
|
.cant_take
|
||||||
|
RTL
|
||||||
|
|
||||||
|
PikitItemList:
|
||||||
|
db $01 ; 00 - Fighter Sword and Shield
|
||||||
|
db $01 ; 01 - Master Sword
|
||||||
|
db $01 ; 02 - Tempered Sword
|
||||||
|
db $01 ; 03 - Butter Sword
|
||||||
|
db $00 ; 04 - Fighter Shield
|
||||||
|
db $00 ; 05 - Fire Shield
|
||||||
|
db $00 ; 06 - Mirror Shield
|
||||||
|
db $01 ; 07 - Fire Rod
|
||||||
|
db $01 ; 08 - Ice Rod
|
||||||
|
db $01 ; 09 - Hammer
|
||||||
|
db $01 ; 0A - Hookshot
|
||||||
|
db $01 ; 0B - Bow
|
||||||
|
db $01 ; 0C - Boomerang
|
||||||
|
db $01 ; 0D - Powder
|
||||||
|
db $00 ; 0E - Bottle Refill (bee)
|
||||||
|
db $01 ; 0F - Bombos
|
||||||
|
db $01 ; 10 - Ether
|
||||||
|
db $01 ; 11 - Quake
|
||||||
|
db $01 ; 12 - Lamp
|
||||||
|
db $01 ; 13 - Shovel
|
||||||
|
db $01 ; 14 - Flute
|
||||||
|
db $01 ; 15 - Somaria
|
||||||
|
db $01 ; 16 - Bottle
|
||||||
|
db $00 ; 17 - Heartpiece
|
||||||
|
db $01 ; 18 - Byrna
|
||||||
|
db $01 ; 19 - Cape
|
||||||
|
db $01 ; 1A - Mirror
|
||||||
|
db $01 ; 1B - Glove
|
||||||
|
db $01 ; 1C - Mitts
|
||||||
|
db $01 ; 1D - Book
|
||||||
|
db $01 ; 1E - Flippers
|
||||||
|
db $01 ; 1F - Pearl
|
||||||
|
db $00 ; 20 - Crystal
|
||||||
|
db $01 ; 21 - Net
|
||||||
|
db $00 ; 22 - Blue Mail
|
||||||
|
db $00 ; 23 - Red Mail
|
||||||
|
db $00 ; 24 - Small Key
|
||||||
|
db $00 ; 25 - Compass
|
||||||
|
db $00 ; 26 - Heart Container from 4/4
|
||||||
|
db $00 ; 27 - Bomb
|
||||||
|
db $00 ; 28 - 3 bombs
|
||||||
|
db $01 ; 29 - Mushroom
|
||||||
|
db $01 ; 2A - Red boomerang
|
||||||
|
db $01 ; 2B - Full bottle (red)
|
||||||
|
db $01 ; 2C - Full bottle (green)
|
||||||
|
db $01 ; 2D - Full bottle (blue)
|
||||||
|
db $00 ; 2E - Potion refill (red)
|
||||||
|
db $00 ; 2F - Potion refill (green)
|
||||||
|
db $00 ; 30 - Potion refill (blue)
|
||||||
|
db $00 ; 31 - 10 bombs
|
||||||
|
db $00 ; 32 - Big key
|
||||||
|
db $00 ; 33 - Map
|
||||||
|
db $00 ; 34 - 1 rupee
|
||||||
|
db $00 ; 35 - 5 rupees
|
||||||
|
db $00 ; 36 - 20 rupees
|
||||||
|
db $00 ; 37 - Green pendant
|
||||||
|
db $00 ; 38 - Blue pendant
|
||||||
|
db $00 ; 39 - Red pendant
|
||||||
|
db $01 ; 3A - Tossed bow
|
||||||
|
db $01 ; 3B - Silvers
|
||||||
|
db $01 ; 3C - Full bottle (bee)
|
||||||
|
db $01 ; 3D - Full bottle (fairy)
|
||||||
|
db $00 ; 3E - Boss heart
|
||||||
|
db $00 ; 3F - Sanc heart
|
||||||
|
db $00 ; 40 - 100 rupees
|
||||||
|
db $00 ; 41 - 50 rupees
|
||||||
|
db $00 ; 42 - Heart
|
||||||
|
db $00 ; 43 - Arrow
|
||||||
|
db $00 ; 44 - 10 arrows
|
||||||
|
db $00 ; 45 - Small magic
|
||||||
|
db $00 ; 46 - 300 rupees
|
||||||
|
db $00 ; 47 - 20 rupees green
|
||||||
|
db $01 ; 48 - Full bottle (good bee)
|
||||||
|
db $01 ; 49 - Tossed fighter sword
|
||||||
|
db $01 ; 4A - Active Flute
|
||||||
|
db $01 ; 4B - Boots
|
||||||
|
|
||||||
|
db $00 ; 4C - Bomb capacity (50)
|
||||||
|
db $00 ; 4D - Arrow capacity (70)
|
||||||
|
db $01 ; 4E - 1/2 magic
|
||||||
|
db $01 ; 4F - 1/4 magic
|
||||||
|
db $01 ; 50 - Safe master sword
|
||||||
|
db $00 ; 51 - Bomb capacity (+5)
|
||||||
|
db $01 ; 52 - Bomb capacity (+10)
|
||||||
|
db $00 ; 53 - Arrow capacity (+5)
|
||||||
|
db $00 ; 54 - Arrow capacity (+10)
|
||||||
|
db $00 ; 55 - Programmable item 1
|
||||||
|
db $00 ; 56 - Programmable item 2
|
||||||
|
db $00 ; 57 - Programmable item 3
|
||||||
|
db $01 ; 58 - Upgrade-only silver arrows
|
||||||
|
db $00 ; 59 - Rupoor
|
||||||
|
db $00 ; 5A - Nothing
|
||||||
|
db $00 ; 5B - Red clock
|
||||||
|
db $00 ; 5C - Blue clock
|
||||||
|
db $00 ; 5D - Green clock
|
||||||
|
db $01 ; 5E - Progressive sword
|
||||||
|
db $00 ; 5F - Progressive shield
|
||||||
|
db $00 ; 60 - Progressive armor
|
||||||
|
db $01 ; 61 - Progressive glove
|
||||||
|
db $00 ; 62 - RNG pool item (single)
|
||||||
|
db $00 ; 63 - RNG pool item (multi)
|
||||||
|
db $01 ; 64 - Progressive bow
|
||||||
|
db $01 ; 65 - Progressive bow
|
||||||
|
db $00 ; 66 -
|
||||||
|
db $00 ; 67 -
|
||||||
|
db $00 ; 68 -
|
||||||
|
db $00 ; 69 -
|
||||||
|
db $00 ; 6A - Triforce
|
||||||
|
db $00 ; 6B - Power star
|
||||||
|
db $00 ; 6C - Triforce Piece
|
||||||
|
db $00 ; 6D - Server request item
|
||||||
|
db $00 ; 6E - Server request item (dungeon drop)
|
||||||
|
db $00 ; 6F -
|
||||||
|
|
||||||
|
db $00 ; 70 - Map of Light World
|
||||||
|
db $00 ; 71 - Map of Dark World
|
||||||
|
db $00 ; 72 - Map of Ganon's Tower
|
||||||
|
db $00 ; 73 - Map of Turtle Rock
|
||||||
|
db $00 ; 74 - Map of Thieves' Town
|
||||||
|
db $00 ; 75 - Map of Tower of Hera
|
||||||
|
db $00 ; 76 - Map of Ice Palace
|
||||||
|
db $00 ; 77 - Map of Skull Woods
|
||||||
|
db $00 ; 78 - Map of Misery Mire
|
||||||
|
db $00 ; 79 - Map of Dark Palace
|
||||||
|
db $00 ; 7A - Map of Swamp Palace
|
||||||
|
db $00 ; 7B - Map of Agahnim's Tower
|
||||||
|
db $00 ; 7C - Map of Desert Palace
|
||||||
|
db $00 ; 7D - Map of Eastern Palace
|
||||||
|
db $00 ; 7E - Map of Hyrule Castle
|
||||||
|
db $00 ; 7F - Map of Sewers
|
||||||
|
|
||||||
|
db $00 ; 80 - Compass of Light World
|
||||||
|
db $00 ; 81 - Compass of Dark World
|
||||||
|
db $00 ; 82 - Compass of Ganon's Tower
|
||||||
|
db $00 ; 83 - Compass of Turtle Rock
|
||||||
|
db $00 ; 84 - Compass of Thieves' Town
|
||||||
|
db $00 ; 85 - Compass of Tower of Hera
|
||||||
|
db $00 ; 86 - Compass of Ice Palace
|
||||||
|
db $00 ; 87 - Compass of Skull Woods
|
||||||
|
db $00 ; 88 - Compass of Misery Mire
|
||||||
|
db $00 ; 89 - Compass of Dark Palace
|
||||||
|
db $00 ; 8A - Compass of Swamp Palace
|
||||||
|
db $00 ; 8B - Compass of Agahnim's Tower
|
||||||
|
db $00 ; 8C - Compass of Desert Palace
|
||||||
|
db $00 ; 8D - Compass of Eastern Palace
|
||||||
|
db $00 ; 8E - Compass of Hyrule Castle
|
||||||
|
db $00 ; 8F - Compass of Sewers
|
||||||
|
|
||||||
|
db $00 ; 90 - Skull key
|
||||||
|
db $00 ; 91 - Reserved
|
||||||
|
db $00 ; 92 - Big key of Ganon's Tower
|
||||||
|
db $00 ; 93 - Big key of Turtle Rock
|
||||||
|
db $00 ; 94 - Big key of Thieves' Town
|
||||||
|
db $00 ; 95 - Big key of Tower of Hera
|
||||||
|
db $00 ; 96 - Big key of Ice Palace
|
||||||
|
db $00 ; 97 - Big key of Skull Woods
|
||||||
|
db $00 ; 98 - Big key of Misery Mire
|
||||||
|
db $00 ; 99 - Big key of Dark Palace
|
||||||
|
db $00 ; 9A - Big key of Swamp Palace
|
||||||
|
db $00 ; 9B - Big key of Agahnim's Tower
|
||||||
|
db $00 ; 9C - Big key of Desert Palace
|
||||||
|
db $00 ; 9D - Big key of Eastern Palace
|
||||||
|
db $00 ; 9E - Big key of Hyrule Castle
|
||||||
|
db $00 ; 9F - Big key of Sewers
|
||||||
|
|
||||||
|
db $00 ; A0 - Small key of Sewers
|
||||||
|
db $00 ; A1 - Small key of Hyrule Castle
|
||||||
|
db $00 ; A2 - Small key of Eastern Palace
|
||||||
|
db $00 ; A3 - Small key of Desert Palace
|
||||||
|
db $00 ; A4 - Small key of Agahnim's Tower
|
||||||
|
db $00 ; A5 - Small key of Swamp Palace
|
||||||
|
db $00 ; A6 - Small key of Dark Palace
|
||||||
|
db $00 ; A7 - Small key of Misery Mire
|
||||||
|
db $00 ; A8 - Small key of Skull Woods
|
||||||
|
db $00 ; A9 - Small key of Ice Palace
|
||||||
|
db $00 ; AA - Small key of Tower of Hera
|
||||||
|
db $00 ; AB - Small key of Thieves' Town
|
||||||
|
db $00 ; AC - Small key of Turtle Rock
|
||||||
|
db $00 ; AD - Small key of Ganon's Tower
|
||||||
|
db $00 ; AE - Reserved
|
||||||
|
db $00 ; AF - Generic small key
|
||||||
|
db $00 ; B0 - Crystal 6
|
||||||
|
db $00 ; B1 - Crystal 1
|
||||||
|
db $00 ; B2 - Crystal 5
|
||||||
|
db $00 ; B3 - Crystal 7
|
||||||
|
db $00 ; B4 - Crystal 2
|
||||||
|
db $00 ; B5 - Crystal 4
|
||||||
|
db $00 ; B6 - Crystal 3
|
||||||
|
db $00 ; B7 - Reserved
|
||||||
|
db $00 ; B8 -
|
||||||
|
db $00 ; B9 -
|
||||||
|
db $00 ; BA -
|
||||||
|
db $00 ; BB -
|
||||||
|
db $00 ; BC -
|
||||||
|
db $00 ; BD -
|
||||||
|
db $00 ; BE -
|
||||||
|
db $00 ; BF -
|
||||||
|
db $00 ; C0 -
|
||||||
|
db $00 ; C1 -
|
||||||
|
db $00 ; C2 -
|
||||||
|
db $00 ; C3 -
|
||||||
|
db $00 ; C4 -
|
||||||
|
db $00 ; C5 -
|
||||||
|
db $00 ; C6 -
|
||||||
|
db $00 ; C7 -
|
||||||
|
db $00 ; C8 -
|
||||||
|
db $00 ; C9 -
|
||||||
|
db $00 ; CA -
|
||||||
|
db $00 ; CB -
|
||||||
|
db $00 ; CC -
|
||||||
|
db $00 ; CD -
|
||||||
|
db $00 ; CE -
|
||||||
|
db $00 ; CF -
|
||||||
|
db $00 ; D0 - Bee trap
|
||||||
|
db $00 ; D1 - Apples
|
||||||
|
db $00 ; D2 - Fairy
|
||||||
|
db $00 ; D3 - Chicken
|
||||||
|
db $00 ; D4 - Big Magic
|
||||||
|
db $00 ; D5 - 5 Arrows
|
||||||
|
db $00 ; D6 - Good Bee
|
||||||
|
db $00 ; D7 -
|
||||||
|
db $00 ; D8 -
|
||||||
|
db $00 ; D9 -
|
||||||
|
db $00 ; DA -
|
||||||
|
db $00 ; DB -
|
||||||
|
db $00 ; DC -
|
||||||
|
db $00 ; DD -
|
||||||
|
db $00 ; DE -
|
||||||
|
db $00 ; DF -
|
||||||
|
db $00 ; E0 -
|
||||||
|
db $00 ; E1 -
|
||||||
|
db $00 ; E2 -
|
||||||
|
db $00 ; E3 -
|
||||||
|
db $00 ; E4 -
|
||||||
|
db $00 ; E5 -
|
||||||
|
db $00 ; E6 -
|
||||||
|
db $00 ; E7 -
|
||||||
|
db $00 ; E8 -
|
||||||
|
db $00 ; E9 -
|
||||||
|
db $00 ; EA -
|
||||||
|
db $00 ; EB -
|
||||||
|
db $00 ; EC -
|
||||||
|
db $00 ; ED -
|
||||||
|
db $00 ; EE -
|
||||||
|
db $00 ; EF -
|
||||||
|
db $00 ; F0 -
|
||||||
|
db $00 ; F1 -
|
||||||
|
db $00 ; F2 -
|
||||||
|
db $00 ; F3 -
|
||||||
|
db $00 ; F4 -
|
||||||
|
db $00 ; F5 -
|
||||||
|
db $00 ; F6 -
|
||||||
|
db $00 ; F7 -
|
||||||
|
db $00 ; F8 -
|
||||||
|
db $00 ; F9 -
|
||||||
|
db $00 ; FA -
|
||||||
|
db $00 ; FB -
|
||||||
|
db $00 ; FC -
|
||||||
|
db $00 ; FD -
|
||||||
|
db $00 ; FE - Server request (async)
|
||||||
|
db $00 ; FF -
|
||||||
6
ram.asm
6
ram.asm
@@ -338,7 +338,6 @@ SpawnedItemFlag = $7E0726 ; 0x02 - one for pot, 2 for sprite drop
|
|||||||
SpawnedItemMWPlayer = $7E0728 ; Player Id for spawned item if Multiworld item 0x02
|
SpawnedItemMWPlayer = $7E0728 ; Player Id for spawned item if Multiworld item 0x02
|
||||||
;
|
;
|
||||||
EnemyDropIndicator = $7E072A ; Used by HUD to indicate enemy drops remaining
|
EnemyDropIndicator = $7E072A ; Used by HUD to indicate enemy drops remaining
|
||||||
NpcItemIndicator = $7E072C ; Flag used by HUD to indicate NPC item present
|
|
||||||
SkipBeeTrapDisguise = $7E072D ; Flag to skip bee trap disguise during draw routine
|
SkipBeeTrapDisguise = $7E072D ; Flag to skip bee trap disguise during draw routine
|
||||||
|
|
||||||
SprDropsItem = $7E0730 ; Array for whether a sprite drops an item 0x16
|
SprDropsItem = $7E0730 ; Array for whether a sprite drops an item 0x16
|
||||||
@@ -598,8 +597,6 @@ HUDMultiIndicator = $7EC790 ;
|
|||||||
HUDKeysObtained = $7EC7A2 ;
|
HUDKeysObtained = $7EC7A2 ;
|
||||||
HUDKeysSlash = $7EC7A4 ;
|
HUDKeysSlash = $7EC7A4 ;
|
||||||
HUDKeysTotal = $7EC7A6 ;
|
HUDKeysTotal = $7EC7A6 ;
|
||||||
HUDKeysExtraPlus = $7EC7E4 ;
|
|
||||||
HUDKeysExtraCount = $7EC7E6 ;
|
|
||||||
;
|
;
|
||||||
BigRAM = $7EC900 ; Big buffer of free ram (0x1F00)
|
BigRAM = $7EC900 ; Big buffer of free ram (0x1F00)
|
||||||
ItemGFXStack = $7ECB00 ; Pointers to source of decompressed item tiles deferred to NMI loading.
|
ItemGFXStack = $7ECB00 ; Pointers to source of decompressed item tiles deferred to NMI loading.
|
||||||
@@ -622,7 +619,8 @@ HexToDecDigit3: skip 1 ;
|
|||||||
HexToDecDigit4: skip 1 ;
|
HexToDecDigit4: skip 1 ;
|
||||||
HexToDecDigit5: skip 1 ;
|
HexToDecDigit5: skip 1 ;
|
||||||
SpriteSkipEOR: skip 2 ; Used in utilities.asm to determine when to skip drawing sprites. Zero-padded
|
SpriteSkipEOR: skip 2 ; Used in utilities.asm to determine when to skip drawing sprites. Zero-padded
|
||||||
skip $2B ; Unused
|
skip $2A ; Unused
|
||||||
|
BossDropTouched: skip 1
|
||||||
AltTextFlag: skip 2 ; dialog.asm: Determines whether to load from vanilla decompression buffer
|
AltTextFlag: skip 2 ; dialog.asm: Determines whether to load from vanilla decompression buffer
|
||||||
; or from a secondary buffer (used for things like free dungeon item text)
|
; or from a secondary buffer (used for things like free dungeon item text)
|
||||||
BossKills: skip 1 ;
|
BossKills: skip 1 ;
|
||||||
|
|||||||
@@ -433,13 +433,10 @@ Shopkeeper_BuyItem:
|
|||||||
CMP.b #$2E : BEQ .refill ; Red Potion Refill
|
CMP.b #$2E : BEQ .refill ; Red Potion Refill
|
||||||
CMP.b #$2F : BEQ .refill ; Green Potion Refill
|
CMP.b #$2F : BEQ .refill ; Green Potion Refill
|
||||||
CMP.b #$30 : BEQ .refill ; Blue Potion Refill
|
CMP.b #$30 : BEQ .refill ; Blue Potion Refill
|
||||||
CMP.b #$66 : BEQ .refill ; Orange Potion Refill
|
BRA +
|
||||||
CMP.b #$AF : BEQ .generic_key
|
|
||||||
BRA +
|
|
||||||
.refill
|
.refill
|
||||||
JSL Sprite_GetEmptyBottleIndex : BMI .full_bottles
|
JSL Sprite_GetEmptyBottleIndex : BMI .full_bottles
|
||||||
.generic_key
|
LDA.b #$01 : STA.l ShopkeeperRefill ; If this is on, don't toggle bit to remove from shop
|
||||||
LDA.b #$1 : STA.l ShopkeeperRefill ; If this is on, don't toggle bit to remove from shop
|
|
||||||
+
|
+
|
||||||
|
|
||||||
LDA.l ShopType : AND.b #$80 : BNE .buy ; don't charge if this is a take-any
|
LDA.l ShopType : AND.b #$80 : BNE .buy ; don't charge if this is a take-any
|
||||||
@@ -456,6 +453,16 @@ Shopkeeper_BuyItem:
|
|||||||
LDA.b #$3C : STA.w SFX2 ; error sound
|
LDA.b #$3C : STA.w SFX2 ; error sound
|
||||||
JMP .done
|
JMP .done
|
||||||
.buy
|
.buy
|
||||||
|
|
||||||
|
LDA.l ShopInventory, X
|
||||||
|
TAY
|
||||||
|
JSL ShieldCheck
|
||||||
|
BCS +
|
||||||
|
JMP .done
|
||||||
|
+
|
||||||
|
; Y now has the (possibly-substituted) item ID
|
||||||
|
|
||||||
|
|
||||||
LDA.l ShopType : AND.b #$80 : BNE ++ ; don't charge if this is a take-any
|
LDA.l ShopType : AND.b #$80 : BNE ++ ; don't charge if this is a take-any
|
||||||
REP #$20 : LDA.l CurrentRupees : !SUB.l ShopInventory+1, X : STA.l CurrentRupees : SEP #$20 ; Take price away
|
REP #$20 : LDA.l CurrentRupees : !SUB.l ShopInventory+1, X : STA.l CurrentRupees : SEP #$20 ; Take price away
|
||||||
++
|
++
|
||||||
@@ -467,9 +474,9 @@ Shopkeeper_BuyItem:
|
|||||||
LDA.l EnableShopItemCount, X : STA.l ShopEnableCount ; If so, store the permission to count the item here.
|
LDA.l EnableShopItemCount, X : STA.l ShopEnableCount ; If so, store the permission to count the item here.
|
||||||
+++
|
+++
|
||||||
PLX
|
PLX
|
||||||
LDA.l ShopInventory, X
|
|
||||||
JSL AttemptItemSubstitution
|
; Y still has item ID
|
||||||
TAY : JSL Link_ReceiveItem
|
JSL Link_ReceiveItem
|
||||||
LDA.l ShopInventory+3, X : INC : STA.l ShopInventory+3, X
|
LDA.l ShopInventory+3, X : INC : STA.l ShopInventory+3, X
|
||||||
LDA.b #$00 : STA.l ShopEnableCount
|
LDA.b #$00 : STA.l ShopEnableCount
|
||||||
TXA : LSR #2 : TAX
|
TXA : LSR #2 : TAX
|
||||||
|
|||||||
11
sram.asm
11
sram.asm
@@ -190,7 +190,8 @@ ItemLimitCounts: skip 16 ; Keeps track of limited non-progressive items s
|
|||||||
; See: ItemSubstitutionRules in tables.asm
|
; See: ItemSubstitutionRules in tables.asm
|
||||||
; Right now this is only used for three items but extra space is
|
; Right now this is only used for three items but extra space is
|
||||||
; reserved
|
; reserved
|
||||||
skip 34 ; Unused
|
skip 32 ; Unused
|
||||||
|
PikitItem: skip 2 ; Item stored in shield player is carrying
|
||||||
FluteBitfield: skip 1 ;
|
FluteBitfield: skip 1 ;
|
||||||
SpecialWeaponLevel: skip 1 ; keeps track of level in special weapon modes
|
SpecialWeaponLevel: skip 1 ; keeps track of level in special weapon modes
|
||||||
ItemOnB: skip 1 ; NYI
|
ItemOnB: skip 1 ; NYI
|
||||||
@@ -240,9 +241,7 @@ CompassCountDisplay: skip 2 ; Compass count display flags (bitfield)
|
|||||||
; High Byte: x c e d a s p m
|
; High Byte: x c e d a s p m
|
||||||
; x = Sewers | c = Hyrule Castle | e = Eastern Palace | d = Desert Palace
|
; x = Sewers | c = Hyrule Castle | e = Eastern Palace | d = Desert Palace
|
||||||
; a = Castle Tower | s = Swamp Palace | p = PoD | m = Mire
|
; a = Castle Tower | s = Swamp Palace | p = PoD | m = Mire
|
||||||
DungeonVisited: skip 2 ; Whether each dungeon has been entered (bitfield)
|
skip 10 ;
|
||||||
; same order of bits as CompassCountDisplay above
|
|
||||||
skip 8 ;
|
|
||||||
Aga2Duck: skip 1 ; Used in lieu of pyramid hole for checking if the duck should come
|
Aga2Duck: skip 1 ; Used in lieu of pyramid hole for checking if the duck should come
|
||||||
; 0 = Haven't called post-Aga 2 bird | 1 = Have called post-Aga 2 bird
|
; 0 = Haven't called post-Aga 2 bird | 1 = Have called post-Aga 2 bird
|
||||||
NpcFlags: skip 2 ; l - c s t k z o (bitfield)
|
NpcFlags: skip 2 ; l - c s t k z o (bitfield)
|
||||||
@@ -308,7 +307,7 @@ HeartContainerCounter: skip 1 ; Total number of heart containers collected (in
|
|||||||
DeathCounter: skip 1 ; Number of deaths (integer)
|
DeathCounter: skip 1 ; Number of deaths (integer)
|
||||||
skip 1 ; Reserved
|
skip 1 ; Reserved
|
||||||
FluteCounter: skip 1 ; Number of times fluted (integer)
|
FluteCounter: skip 1 ; Number of times fluted (integer)
|
||||||
MapFrames: skip 4 ; Total map time in frames (32-bit integer)
|
skip 4 ;
|
||||||
RNGItem: skip 2 ; RNG Item
|
RNGItem: skip 2 ; RNG Item
|
||||||
SwordlessBossKills: skip 1 ; Number of bosses killed without a sword (integer)
|
SwordlessBossKills: skip 1 ; Number of bosses killed without a sword (integer)
|
||||||
FaerieRevivalCounter: skip 1 ; Number of faerie revivals (integer)
|
FaerieRevivalCounter: skip 1 ; Number of faerie revivals (integer)
|
||||||
@@ -324,7 +323,7 @@ MagicCounter: skip 2 ; Magic used by player (16-bit integer)
|
|||||||
HighestMail: skip 1 ; Highest mail level
|
HighestMail: skip 1 ; Highest mail level
|
||||||
SmallKeyCounter: skip 1 ; Total Number of small keys collected (integer)
|
SmallKeyCounter: skip 1 ; Total Number of small keys collected (integer)
|
||||||
HeartPieceCounter: skip 1 ; Total Number of heartpieces collected (integer)
|
HeartPieceCounter: skip 1 ; Total Number of heartpieces collected (integer)
|
||||||
skip 1 ; Unused
|
PikitFed: skip 1 ; Total Number of shields fed to pikit
|
||||||
DungeonsCompleted: skip 2 ; Bitfield indicating whether a dungeon's prize has been collected.
|
DungeonsCompleted: skip 2 ; Bitfield indicating whether a dungeon's prize has been collected.
|
||||||
; This has the same shape as the dungeon item bitfields.
|
; This has the same shape as the dungeon item bitfields.
|
||||||
MapCountDisplay: skip 2 ;
|
MapCountDisplay: skip 2 ;
|
||||||
|
|||||||
99
stats.asm
99
stats.asm
@@ -5,6 +5,13 @@
|
|||||||
;
|
;
|
||||||
; See sram.asm for adresses and documentation of stat values
|
; See sram.asm for adresses and documentation of stat values
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
|
IncrementPikitCounter:
|
||||||
|
LDA.l StatsLocked : BNE +
|
||||||
|
LDA.l PikitFed : INC A : BEQ + ; overflow
|
||||||
|
STA.l PikitFed
|
||||||
|
+
|
||||||
|
RTL
|
||||||
|
;--------------------------------------------------------------------------------
|
||||||
IncrementBonkCounter:
|
IncrementBonkCounter:
|
||||||
LDA.l StatsLocked : BNE +
|
LDA.l StatsLocked : BNE +
|
||||||
LDA.l BonkCounter : INC : BEQ + ; overflow
|
LDA.l BonkCounter : INC : BEQ + ; overflow
|
||||||
@@ -36,7 +43,7 @@ DungeonHoleWarpTransition:
|
|||||||
BRA StatTransitionCounter
|
BRA StatTransitionCounter
|
||||||
DungeonHoleEntranceTransition:
|
DungeonHoleEntranceTransition:
|
||||||
JSL EnableForceBlank
|
JSL EnableForceBlank
|
||||||
|
|
||||||
LDA.l SilverArrowsAutoEquip : AND.b #$02 : BEQ +
|
LDA.l SilverArrowsAutoEquip : AND.b #$02 : BEQ +
|
||||||
LDA.w EntranceIndex : CMP.b #$7B : BNE + ; skip unless falling to ganon's room
|
LDA.w EntranceIndex : CMP.b #$7B : BNE + ; skip unless falling to ganon's room
|
||||||
LDA.l BowTracking : AND.b #$40 : BEQ + ; skip if we don't have silvers
|
LDA.l BowTracking : AND.b #$40 : BEQ + ; skip if we don't have silvers
|
||||||
@@ -44,7 +51,7 @@ DungeonHoleEntranceTransition:
|
|||||||
CMP.b #$03 : !BGE + ; skip if the bow is already silver
|
CMP.b #$03 : !BGE + ; skip if the bow is already silver
|
||||||
!ADD.b #$02 : STA.l BowEquipment ; increase bow to silver
|
!ADD.b #$02 : STA.l BowEquipment ; increase bow to silver
|
||||||
+
|
+
|
||||||
|
|
||||||
BRA StatTransitionCounter
|
BRA StatTransitionCounter
|
||||||
DungeonStairsTransition:
|
DungeonStairsTransition:
|
||||||
JSL Dungeon_SaveRoomQuadrantData
|
JSL Dungeon_SaveRoomQuadrantData
|
||||||
@@ -88,27 +95,27 @@ IncrementSmallKeys:
|
|||||||
RTL
|
RTL
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
IncrementSmallKeysNoPrimary:
|
IncrementSmallKeysNoPrimary:
|
||||||
STA.l CurrentSmallKeys ; thing we wrote over, write small key count
|
STA.l CurrentSmallKeys ; thing we wrote over, write small key count
|
||||||
PHX
|
PHX
|
||||||
LDA.l StatsLocked : BNE +
|
LDA.l StatsLocked : BNE +
|
||||||
LDA.l SmallKeyCounter : INC : STA.l SmallKeyCounter
|
LDA.l SmallKeyCounter : INC : STA.l SmallKeyCounter
|
||||||
+
|
+
|
||||||
JSL UpdateKeys
|
JSL UpdateKeys
|
||||||
LDA.b IndoorsFlag : BEQ + ; skip room check if outdoors
|
LDA.b IndoorsFlag : BEQ + ; skip room check if outdoors
|
||||||
PHP : REP #$20 ; set 16-bit accumulator
|
PHP : REP #$20 ; set 16-bit accumulator
|
||||||
LDA.b RoomIndex : CMP.w #$0087 : BNE ++ ; hera basement
|
LDA.b RoomIndex : CMP.w #$0087 : BNE ++ ; hera basement
|
||||||
LDA.b $A8 : AND.w #$0003 : CMP.w #$0002 : BNE ++ ; must be quadrant 2
|
LDA.b $A8 : AND.w #$0003 : CMP.w #$0002 : BNE ++ ; must be quadrant 2
|
||||||
LDA.w SprDropsItem, X : AND.w #$00FF : BNE ++ ; must not be a standing item
|
LDA.w SprDropsItem, X : AND.w #$00FF : BNE ++ ; must not be a standing item
|
||||||
PLP : PHY
|
PLP : PHY
|
||||||
LDY.b #$24
|
LDY.b #$24
|
||||||
JSL AddInventory
|
JSL AddInventory
|
||||||
PLY : BRA +
|
PLY : BRA +
|
||||||
++
|
++
|
||||||
PLP
|
PLP
|
||||||
+
|
+
|
||||||
LDA.b #$01 : STA.l UpdateHUDFlag
|
LDA.b #$01 : STA.l UpdateHUDFlag
|
||||||
JSL HUD_RebuildLong
|
JSL HUD_RebuildLong
|
||||||
PLX
|
PLX
|
||||||
RTL
|
RTL
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
DecrementSmallKeys:
|
DecrementSmallKeys:
|
||||||
@@ -188,9 +195,9 @@ CountAllKey:
|
|||||||
|
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
IncrementAgahnim2Sword:
|
IncrementAgahnim2Sword:
|
||||||
PHA
|
PHA
|
||||||
JSL IncrementBossSword
|
JSL IncrementBossSword
|
||||||
PLA
|
PLA
|
||||||
RTL
|
RTL
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
IncrementDeathCounter:
|
IncrementDeathCounter:
|
||||||
@@ -239,22 +246,22 @@ RTL
|
|||||||
DecrementItemCounter:
|
DecrementItemCounter:
|
||||||
PHA
|
PHA
|
||||||
LDA.l StatsLocked : BNE +
|
LDA.l StatsLocked : BNE +
|
||||||
REP #$20
|
REP #$20
|
||||||
LDA.l TotalItemCounter : DEC : STA.l TotalItemCounter
|
LDA.l TotalItemCounter : DEC : STA.l TotalItemCounter
|
||||||
SEP #$20
|
SEP #$20
|
||||||
+
|
+
|
||||||
PLA
|
PLA
|
||||||
RTL
|
RTL
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
IncrementBigChestCounter:
|
IncrementBigChestCounter:
|
||||||
JSL Dungeon_SaveRoomQuadrantData ; thing we wrote over
|
JSL Dungeon_SaveRoomQuadrantData ; thing we wrote over
|
||||||
PHA
|
PHA
|
||||||
LDA.l StatsLocked : BNE +
|
LDA.l StatsLocked : BNE +
|
||||||
LDA.l BigKeysBigChests : INC : AND.b #$0F : TAX
|
LDA.l BigKeysBigChests : INC : AND.b #$0F : TAX
|
||||||
LDA.l BigKeysBigChests : AND.b #$F0 : STA.l BigKeysBigChests
|
LDA.l BigKeysBigChests : AND.b #$F0 : STA.l BigKeysBigChests
|
||||||
TXA : ORA.l BigKeysBigChests : STA.l BigKeysBigChests
|
TXA : ORA.l BigKeysBigChests : STA.l BigKeysBigChests
|
||||||
+
|
+
|
||||||
PLA
|
PLA
|
||||||
RTL
|
RTL
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
IncrementDamageTakenCounter_Eight:
|
IncrementDamageTakenCounter_Eight:
|
||||||
@@ -338,8 +345,8 @@ IncrementUWMirror:
|
|||||||
RTL
|
RTL
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
IncrementSpentRupees:
|
IncrementSpentRupees:
|
||||||
DEC A : BPL .subtractRupees
|
DEC A : BPL .subtractRupees
|
||||||
LDA.w #$0000 : STA.l CurrentRupees
|
LDA.w #$0000 : STA.l CurrentRupees
|
||||||
RTL
|
RTL
|
||||||
.subtractRupees
|
.subtractRupees
|
||||||
PHA : PHP
|
PHA : PHP
|
||||||
@@ -355,18 +362,18 @@ IndoorTileTransitionCounter:
|
|||||||
JMP StatTransitionCounter
|
JMP StatTransitionCounter
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
IndoorSubtileTransitionCounter:
|
IndoorSubtileTransitionCounter:
|
||||||
;JSL HeartPieceSetRedraw ; set redraw flag for items
|
;JSL HeartPieceSetRedraw ; set redraw flag for items
|
||||||
STZ.w SomariaSwitchFlag ; stuff we wrote over
|
STZ.w SomariaSwitchFlag ; stuff we wrote over
|
||||||
STZ.w SpriteRoomTag
|
STZ.w SpriteRoomTag
|
||||||
JMP StatTransitionCounter
|
JMP StatTransitionCounter
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
StatsFinalPrep:
|
StatsFinalPrep:
|
||||||
PHA : PHX : PHP
|
PHA : PHX : PHP
|
||||||
SEP #$30 ; set 8-bit accumulator and index registers
|
SEP #$30 ; set 8-bit accumulator and index registers
|
||||||
|
|
||||||
LDA.l StatsLocked : BNE .ramPostOnly
|
LDA.l StatsLocked : BNE .ramPostOnly
|
||||||
INC : STA.l StatsLocked
|
INC : STA.l StatsLocked
|
||||||
|
|
||||||
JSL IncrementFinalSword
|
JSL IncrementFinalSword
|
||||||
|
|
||||||
LDA.l HighestMail : INC : STA.l HighestMail ; add green mail to mail count
|
LDA.l HighestMail : INC : STA.l HighestMail ; add green mail to mail count
|
||||||
@@ -385,12 +392,12 @@ StatsFinalPrep:
|
|||||||
LDA.l RupeesSpent : !ADD.l DisplayRupees : STA.l RupeesCollected
|
LDA.l RupeesSpent : !ADD.l DisplayRupees : STA.l RupeesCollected
|
||||||
LDA.l RupeesSpent+1 : ADC.l DisplayRupees+1 : STA.l RupeesCollected+1
|
LDA.l RupeesSpent+1 : ADC.l DisplayRupees+1 : STA.l RupeesCollected+1
|
||||||
|
|
||||||
REP #$20
|
REP #$20
|
||||||
LDA.l TotalItemCounter : !SUB.l ChestsOpened : STA.l NonChestCounter
|
LDA.l TotalItemCounter : !SUB.l ChestsOpened : STA.l NonChestCounter
|
||||||
|
|
||||||
.done
|
.done
|
||||||
PLP : PLX : PLA
|
PLP : PLX : PLA
|
||||||
LDA.b #$19 : STA.b GameMode ; thing we wrote over, load triforce room
|
LDA.b #$19 : STA.b GameMode ; thing we wrote over, load triforce room
|
||||||
STZ.b GameSubMode
|
STZ.b GameSubMode
|
||||||
STZ.b SubSubModule
|
STZ.b SubSubModule
|
||||||
RTL
|
RTL
|
||||||
|
|||||||
@@ -504,7 +504,7 @@ CreditsLineBlank:
|
|||||||
%blankline()
|
%blankline()
|
||||||
%blankline()
|
%blankline()
|
||||||
|
|
||||||
%smallcredits("GWAAKIWI * DUNGEON MAPS", "yellow")
|
%smallcredits("PIKIT FEEDER", "red")
|
||||||
|
|
||||||
%blankline()
|
%blankline()
|
||||||
|
|
||||||
@@ -513,7 +513,7 @@ CreditsLineBlank:
|
|||||||
%blankline()
|
%blankline()
|
||||||
%blankline()
|
%blankline()
|
||||||
|
|
||||||
%smallcredits("SPRITE DEVELOPMENT", "green")
|
%smallcredits("SPRITE DEVELOPMENT", "yellow")
|
||||||
|
|
||||||
%blankline()
|
%blankline()
|
||||||
|
|
||||||
@@ -534,7 +534,7 @@ CreditsLineBlank:
|
|||||||
%blankline()
|
%blankline()
|
||||||
%blankline()
|
%blankline()
|
||||||
|
|
||||||
%smallcredits("YOUR SPRITE BY", "yellow")
|
%smallcredits("YOUR SPRITE BY", "green")
|
||||||
|
|
||||||
%blankline()
|
%blankline()
|
||||||
|
|
||||||
@@ -544,7 +544,7 @@ CreditsLineBlank:
|
|||||||
%blankline()
|
%blankline()
|
||||||
%blankline()
|
%blankline()
|
||||||
|
|
||||||
%smallcredits("MSU SUPPORT", "green")
|
%smallcredits("MSU SUPPORT", "yellow")
|
||||||
|
|
||||||
%blankline()
|
%blankline()
|
||||||
|
|
||||||
@@ -553,7 +553,7 @@ CreditsLineBlank:
|
|||||||
%blankline()
|
%blankline()
|
||||||
%blankline()
|
%blankline()
|
||||||
|
|
||||||
%smallcredits("PALETTE SHUFFLER", "yellow")
|
%smallcredits("PALETTE SHUFFLER", "green")
|
||||||
|
|
||||||
%blankline()
|
%blankline()
|
||||||
|
|
||||||
@@ -562,7 +562,7 @@ CreditsLineBlank:
|
|||||||
%blankline()
|
%blankline()
|
||||||
%blankline()
|
%blankline()
|
||||||
|
|
||||||
%smallcredits("WEBSITE LOGO", "green")
|
%smallcredits("WEBSITE LOGO", "yellow")
|
||||||
|
|
||||||
%blankline()
|
%blankline()
|
||||||
|
|
||||||
@@ -755,11 +755,11 @@ endif
|
|||||||
|
|
||||||
%blankline()
|
%blankline()
|
||||||
|
|
||||||
%bigcreditsleft("TOTAL MAP TIME")
|
%bigcreditsleft("TOTAL LAG TIME")
|
||||||
|
|
||||||
%blankline()
|
%blankline()
|
||||||
|
|
||||||
%bigcreditsleft("TOTAL LAG TIME")
|
%bigcreditsleft("SHIELDS EATEN")
|
||||||
|
|
||||||
%blankline()
|
%blankline()
|
||||||
|
|
||||||
|
|||||||
@@ -263,10 +263,6 @@ dw $3D9E ; ~ ;
|
|||||||
dw $3D98 ; , ;
|
dw $3D98 ; , ;
|
||||||
dw $3D99 ; - ; $FB
|
dw $3D99 ; - ; $FB
|
||||||
dw $0000 ; ;
|
dw $0000 ; ;
|
||||||
|
dw $0000 ; ;
|
||||||
; green ellipsis ;
|
dw $0000 ; ;
|
||||||
dw $293F ; ; $FD
|
dw $0000 ; ;
|
||||||
; green period
|
|
||||||
dw $29FE ; ; $FE
|
|
||||||
; yellow dot
|
|
||||||
dw $2DFA ; ; $FF
|
|
||||||
|
|||||||
@@ -25,8 +25,8 @@ PreparePointer:
|
|||||||
LDY.w #$0000
|
LDY.w #$0000
|
||||||
RTL
|
RTL
|
||||||
|
|
||||||
; Regular stat: XXXX X00L LLLL LLLL BBBB SSSS CCC- ---- ---- ---- AAAA AAAA AAAA AAAA AAAA AAAA
|
; Regular stat: XXXX X00L LLLL LLLL BBBB SSSS CCC- ---- ---- ---- AAAA AAAA AAAA AAAA AAAA AAAA
|
||||||
; Time stat: XXXX X01L LLLL LLLL ---- ---- ---- ---- ---- ---- AAAA AAAA AAAA AAAA AAAA AAAA
|
; Time stat: XXXX X01L LLLL LLLL ---- ---- ---- ---- ---- ---- AAAA AAAA AAAA AAAA AAAA AAAA
|
||||||
; End of data: 1111 1111 1111 1111
|
; End of data: 1111 1111 1111 1111
|
||||||
|
|
||||||
; X X offset (measured in 8x8 tiles)
|
; X X offset (measured in 8x8 tiles)
|
||||||
@@ -174,7 +174,7 @@ FindLine:
|
|||||||
!FRAMES_PER_SECOND = 60
|
!FRAMES_PER_SECOND = 60
|
||||||
!FRAMES_PER_MINUTE = 60*60
|
!FRAMES_PER_MINUTE = 60*60
|
||||||
!FRAMES_PER_HOUR = 60*60*60
|
!FRAMES_PER_HOUR = 60*60*60
|
||||||
!MAX_FRAME_COUNT = (99*60*60*60)+(59*60*60)+(59*60)+59
|
!MAX_FRAME_COUNT = 59*60+59*60+59*60+99
|
||||||
|
|
||||||
macro CountUnits(framesPerUnit, unitCounter)
|
macro CountUnits(framesPerUnit, unitCounter)
|
||||||
STZ.b <unitCounter>
|
STZ.b <unitCounter>
|
||||||
@@ -196,7 +196,7 @@ endmacro
|
|||||||
|
|
||||||
!ColonOffset = $8A
|
!ColonOffset = $8A
|
||||||
!PeriodOffset = $4D
|
!PeriodOffset = $4D
|
||||||
BlankCreditsTile = $3D88
|
BlankCreditsTile = $883D
|
||||||
|
|
||||||
RenderCreditsStatCounter:
|
RenderCreditsStatCounter:
|
||||||
PHB
|
PHB
|
||||||
@@ -498,45 +498,45 @@ RenderLineNumber:
|
|||||||
RTS
|
RTS
|
||||||
|
|
||||||
LoadCreditsTiles:
|
LoadCreditsTiles:
|
||||||
JSL CopyFontToVRAM ; What we wrote over
|
JSL CopyFontToVRAM ; What we wrote over
|
||||||
|
|
||||||
REP #$10
|
REP #$10
|
||||||
LDA.b #$80 : STA.w VMAIN
|
LDA.b #$80 : STA.w VMAIN
|
||||||
LDA.b #$01 : STA.w DMAP0
|
LDA.b #$01 : STA.w DMAP0
|
||||||
LDA.b #$18 : STA.w BBAD0
|
LDA.b #$18 : STA.w BBAD0
|
||||||
|
|
||||||
; Item tiles
|
; Item tiles
|
||||||
LDX.w #$8200 : STX.w VMADDL
|
LDX.w #$8200 : STX.w VMADDL
|
||||||
LDA.b #FileSelectNewGraphics>>16 : STA.w A1B0
|
LDA.b #FileSelectNewGraphics>>16 : STA.w A1B0
|
||||||
LDX.w #FileSelectNewGraphics : STX.w A1T0L
|
LDX.w #FileSelectNewGraphics : STX.w A1T0L
|
||||||
LDX.w #$0C00 : STX.w DAS0L
|
LDX.w #$0C00 : STX.w DAS0L
|
||||||
LDA.b #$01 : STA.w DMAENABLE
|
LDA.b #$01 : STA.w DMAENABLE
|
||||||
|
|
||||||
; Small characters A-Z
|
; Small characters A-Z
|
||||||
LDX.w #$7F00 : STX.w VMADDL
|
LDX.w #$7F00 : STX.w VMADDL
|
||||||
LDA.b #SmallCharacters>>16 : STA.w A1B0
|
LDA.b #SmallCharacters>>16 : STA.w A1B0
|
||||||
LDX.w #SmallCharacters : STX.w A1T0L
|
LDX.w #SmallCharacters : STX.w A1T0L
|
||||||
LDX.w #$0200 : STX.w DAS0L
|
LDX.w #$0200 : STX.w DAS0L
|
||||||
LDA.b #$01 : STA.w DMAENABLE
|
LDA.b #$01 : STA.w DMAENABLE
|
||||||
|
|
||||||
SEP #$10
|
SEP #$10
|
||||||
RTL
|
RTL
|
||||||
|
|
||||||
LoadOverworldCreditsTiles:
|
LoadOverworldCreditsTiles:
|
||||||
JSL CopyFontToVRAM ; What we wrote over
|
JSL CopyFontToVRAM ; What we wrote over
|
||||||
REP #$10
|
REP #$10
|
||||||
|
|
||||||
; Small characters A-Z
|
; Small characters A-Z
|
||||||
LDA.b #$80 : STA.w VMAIN
|
LDA.b #$80 : STA.w VMAIN
|
||||||
LDA.b #$01 : STA.w DMAP0
|
LDA.b #$01 : STA.w DMAP0
|
||||||
LDA.b #$18 : STA.w BBAD0
|
LDA.b #$18 : STA.w BBAD0
|
||||||
LDA.b #SmallCharacters>>16 : STA.w A1B0
|
LDA.b #SmallCharacters>>16 : STA.w A1B0
|
||||||
LDX.w #SmallCharacters : STX.w A1T0L
|
LDX.w #SmallCharacters : STX.w A1T0L
|
||||||
LDX.w #$0200 : STX.w DAS0L
|
LDX.w #$0200 : STX.w DAS0L
|
||||||
LDX.w #$7F00 : STX.w VMADDL
|
LDX.w #$7F00 : STX.w VMADDL
|
||||||
LDA.b #$01 : STA.w DMAENABLE
|
LDA.b #$01 : STA.w DMAENABLE
|
||||||
|
|
||||||
SEP #$10
|
SEP #$10
|
||||||
RTL
|
RTL
|
||||||
|
|
||||||
CheckFontTable:
|
CheckFontTable:
|
||||||
@@ -577,23 +577,23 @@ RTS
|
|||||||
; Dialog Pointer Override
|
; Dialog Pointer Override
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
EndingSequenceTableOverride:
|
EndingSequenceTableOverride:
|
||||||
PHY
|
PHY
|
||||||
PHX
|
PHX
|
||||||
TYX
|
TYX
|
||||||
LDA.l EndingSequenceText, X
|
LDA.l EndingSequenceText, X
|
||||||
PLX
|
PLX
|
||||||
STA.w $1008, X
|
STA.w $1008, X
|
||||||
PLY
|
PLY
|
||||||
RTL
|
RTL
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
EndingSequenceTableLookupOverride:
|
EndingSequenceTableLookupOverride:
|
||||||
PHX : PHB
|
PHX : PHB
|
||||||
PHK : PLB
|
PHK : PLB
|
||||||
TYX
|
TYX
|
||||||
LDA.l EndingSequenceText, X : AND.w #$00FF
|
LDA.l EndingSequenceText, X : AND.w #$00FF
|
||||||
ASL A
|
ASL
|
||||||
TAY
|
TAY
|
||||||
LDA.w FontTable,Y
|
LDA.w FontTable,Y
|
||||||
PLB : PLX
|
PLB : PLX
|
||||||
RTL
|
RTL
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
|
|||||||
@@ -30,10 +30,10 @@
|
|||||||
!FAERIE_REVIVALS_Y = 361
|
!FAERIE_REVIVALS_Y = 361
|
||||||
!TOTAL_MENU_TIME_X = 19
|
!TOTAL_MENU_TIME_X = 19
|
||||||
!TOTAL_MENU_TIME_Y = 364
|
!TOTAL_MENU_TIME_Y = 364
|
||||||
!TOTAL_MAP_TIME_X = 19
|
|
||||||
!TOTAL_MAP_TIME_Y = 367
|
|
||||||
!TOTAL_LAG_TIME_X = 19
|
!TOTAL_LAG_TIME_X = 19
|
||||||
!TOTAL_LAG_TIME_Y = 370
|
!TOTAL_LAG_TIME_Y = 367
|
||||||
|
!PIKIT_FED_X = 26
|
||||||
|
!PIKIT_FED_Y = 370
|
||||||
!COLLECTION_RATE_X = 22
|
!COLLECTION_RATE_X = 22
|
||||||
!COLLECTION_RATE_Y = 380
|
!COLLECTION_RATE_Y = 380
|
||||||
!TOTAL_TIME_X = 19
|
!TOTAL_TIME_X = 19
|
||||||
@@ -64,10 +64,11 @@ CreditsStats:
|
|||||||
%AddStat(SaveQuitCounter, 0, 0, 08, 2, !SAVE_AND_QUITS_X, !SAVE_AND_QUITS_Y)
|
%AddStat(SaveQuitCounter, 0, 0, 08, 2, !SAVE_AND_QUITS_X, !SAVE_AND_QUITS_Y)
|
||||||
%AddStat(DeathCounter, 0, 0, 08, 2, !DEATHS_X, !DEATHS_Y)
|
%AddStat(DeathCounter, 0, 0, 08, 2, !DEATHS_X, !DEATHS_Y)
|
||||||
%AddStat(FaerieRevivalCounter, 0, 0, 08, 3, !FAERIE_REVIVALS_X, !FAERIE_REVIVALS_Y)
|
%AddStat(FaerieRevivalCounter, 0, 0, 08, 3, !FAERIE_REVIVALS_X, !FAERIE_REVIVALS_Y)
|
||||||
%AddStat(MenuFrames, 1, 0, 32, 4, !TOTAL_MENU_TIME_X, !TOTAL_MENU_TIME_Y)
|
%AddStat(MenuFrames, 1, 8, 32, 4, !TOTAL_MENU_TIME_X, !TOTAL_MENU_TIME_Y)
|
||||||
%AddStat(MapFrames, 1, 0, 32, 4, !TOTAL_MAP_TIME_X, !TOTAL_MAP_TIME_Y)
|
|
||||||
%AddStat(LagTime, 1, 0, 32, 4, !TOTAL_LAG_TIME_X, !TOTAL_LAG_TIME_Y)
|
%AddStat(LagTime, 1, 0, 32, 4, !TOTAL_LAG_TIME_X, !TOTAL_LAG_TIME_Y)
|
||||||
|
%AddStat(PikitFed, 0, 0, 8, 3, !PIKIT_FED_X, !PIKIT_FED_Y)
|
||||||
print "Collection Rate config: ", pc
|
print "Collection Rate config: ", pc
|
||||||
|
; warnpc $A39864
|
||||||
%AddStat(TotalItemCounter, 0, 0, 16, 3, !COLLECTION_RATE_X, !COLLECTION_RATE_Y)
|
%AddStat(TotalItemCounter, 0, 0, 16, 3, !COLLECTION_RATE_X, !COLLECTION_RATE_Y)
|
||||||
%AddStat(NMIFrames, 1, 0, 32, 4, !TOTAL_TIME_X, !TOTAL_TIME_Y)
|
%AddStat(NMIFrames, 1, 0, 32, 4, !TOTAL_TIME_X, !TOTAL_TIME_Y)
|
||||||
|
|
||||||
|
|||||||
@@ -101,7 +101,7 @@ CheckGanonHammerDamage:
|
|||||||
LDA.w SpriteTypeTable, X : CMP.b #$D8 ; original behavior except ganon
|
LDA.w SpriteTypeTable, X : CMP.b #$D8 ; original behavior except ganon
|
||||||
RTL
|
RTL
|
||||||
+
|
+
|
||||||
LDA.l GanonVulnerabilityItem : AND.b #$7F : CMP.b #$0C : BEQ .hammer_silvers
|
LDA.l GanonVulnerabilityItem : CMP.b #$0C : BEQ .hammer_silvers
|
||||||
LDA.w SpriteTypeTable, X : CMP.b #$D6 ; original behavior
|
LDA.w SpriteTypeTable, X : CMP.b #$D6 ; original behavior
|
||||||
RTL
|
RTL
|
||||||
|
|
||||||
@@ -132,6 +132,12 @@ GetSmithSword:
|
|||||||
.buy
|
.buy
|
||||||
LDA.l SmithItem_Player : STA.l !MULTIWORLD_ITEM_PLAYER_ID
|
LDA.l SmithItem_Player : STA.l !MULTIWORLD_ITEM_PLAYER_ID
|
||||||
LDA.l SmithItem : TAY
|
LDA.l SmithItem : TAY
|
||||||
|
|
||||||
|
JSL ShieldCheck
|
||||||
|
BCS +
|
||||||
|
JML $86B4A5
|
||||||
|
|
||||||
|
+
|
||||||
STZ.w ItemReceiptMethod ; Item from NPC
|
STZ.w ItemReceiptMethod ; Item from NPC
|
||||||
PHX : JSL Link_ReceiveItem : PLX
|
PHX : JSL Link_ReceiveItem : PLX
|
||||||
|
|
||||||
|
|||||||
22
tables.asm
22
tables.asm
@@ -105,10 +105,6 @@ db $00
|
|||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
org $B0802E
|
org $B0802E
|
||||||
GanonVulnerabilityItem:
|
GanonVulnerabilityItem:
|
||||||
; sn-i iiii
|
|
||||||
; s - immune to sword spins in phase 4
|
|
||||||
; n - immune to all items
|
|
||||||
; i - index of item vulnerability
|
|
||||||
db $00 ; $00 = default behavior (silver arrows)
|
db $00 ; $00 = default behavior (silver arrows)
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
org $B0902F
|
org $B0902F
|
||||||
@@ -241,8 +237,12 @@ db $00
|
|||||||
;a - Infinite Arrows
|
;a - Infinite Arrows
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
org $B0804E ; PC 0x18004E
|
org $B0804E ; PC 0x18004E
|
||||||
UncleRefill_deprecated: ; no longer used
|
UncleRefill:
|
||||||
db $00
|
db $00
|
||||||
|
;---- -mba
|
||||||
|
;m - Refill Magic
|
||||||
|
;b - Refill Bombs
|
||||||
|
;a - Refill Arrows
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
org $B0804F ; PC 0x18004F
|
org $B0804F ; PC 0x18004F
|
||||||
ByrnaInvulnerability:
|
ByrnaInvulnerability:
|
||||||
@@ -890,8 +890,8 @@ SilverArrowsAutoEquip:
|
|||||||
db $01 ; #$00 = Off - #$01 = Collection Time (Default) - #$02 = Entering Ganon - #$03 = Collection Time & Entering Ganon
|
db $01 ; #$00 = Off - #$01 = Collection Time (Default) - #$02 = Entering Ganon - #$03 = Collection Time & Entering Ganon
|
||||||
;================================================================================
|
;================================================================================
|
||||||
org $B08183 ; PC 0x180183
|
org $B08183 ; PC 0x180183
|
||||||
RainDeathRefillRupeeBow:
|
FreeUncleItemAmount:
|
||||||
dw $012C ; 300 rupees (Default)
|
dw $12C ; 300 rupees (Default)
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
org $B08185 ; PC 0x180185
|
org $B08185 ; PC 0x180185
|
||||||
RainDeathRefillTable:
|
RainDeathRefillTable:
|
||||||
@@ -1532,7 +1532,7 @@ db $19,$1A,$1B,$1C,$1D,$1E,$1F,$20
|
|||||||
db $21,$22,$11,$11,$10,$16,$16,$16
|
db $21,$22,$11,$11,$10,$16,$16,$16
|
||||||
db $16,$16,$11,$16,$16,$16,$15,$15
|
db $16,$16,$11,$16,$16,$16,$15,$15
|
||||||
db $15,$15,$15,$15,$15,$15,$15,$15
|
db $15,$15,$15,$15,$15,$15,$15,$15
|
||||||
db $15,$15,$2E,$02,$09,$00,$00,$00
|
db $15,$15,$16,$02,$09,$00,$00,$00
|
||||||
|
|
||||||
MusicShuffleTable:
|
MusicShuffleTable:
|
||||||
db $01,$02,$03,$04,$05,$06,$07,$08
|
db $01,$02,$03,$04,$05,$06,$07,$08
|
||||||
@@ -2686,9 +2686,9 @@ org $B0EFFF ; PC 0x186FFF
|
|||||||
BallNChainDungeon: ; Dungeon ID where ball n chain guard is located. Write
|
BallNChainDungeon: ; Dungeon ID where ball n chain guard is located. Write
|
||||||
db $02 ; $FF to count ball and chain item for collection stats.
|
db $02 ; $FF to count ball and chain item for collection stats.
|
||||||
|
|
||||||
org $B0F000
|
;--------------------------------------------------------------------------------
|
||||||
ExtraChestKeys: ; PC 0x187000-0x18700F
|
; 0x187000 - 18700F (unused)
|
||||||
db $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00, $00
|
;--------------------------------------------------------------------------------
|
||||||
|
|
||||||
org $B0F010
|
org $B0F010
|
||||||
ChestKeys: ; PC 0x187010-0x18701F
|
ChestKeys: ; PC 0x187010-0x18701F
|
||||||
|
|||||||
22
tablets.asm
22
tablets.asm
@@ -57,7 +57,7 @@ RTL
|
|||||||
MaybeUnlockTabletAnimation:
|
MaybeUnlockTabletAnimation:
|
||||||
PHA : PHP
|
PHA : PHP
|
||||||
JSL IsMedallion : BCC +
|
JSL IsMedallion : BCC +
|
||||||
JSR SetTabletItemFlag
|
JSR SetTabletItemFlag
|
||||||
STZ.w MedallionFlag ; disable falling-medallion mode
|
STZ.w MedallionFlag ; disable falling-medallion mode
|
||||||
STZ.w ForceSwordUp ; release link from item-up pose
|
STZ.w ForceSwordUp ; release link from item-up pose
|
||||||
LDA.b #$00 : STA.b LinkState ; set link to ground state
|
LDA.b #$00 : STA.b LinkState ; set link to ground state
|
||||||
@@ -73,6 +73,26 @@ MaybeUnlockTabletAnimation:
|
|||||||
PLP : PLA
|
PLP : PLA
|
||||||
RTL
|
RTL
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
|
MaybeFreeLinkFromTablet:
|
||||||
|
PHA : PHP
|
||||||
|
JSL IsMedallion : BCC +
|
||||||
|
STZ.w MedallionFlag ; disable falling-medallion mode
|
||||||
|
STZ.w ForceSwordUp ; release link from item-up pose
|
||||||
|
LDA.b #$00 : STA.b LinkState ; set link to ground state
|
||||||
|
STZ.w CutsceneFlag
|
||||||
|
STZ.w NoDamage
|
||||||
|
|
||||||
|
REP #$20 ; set 16-bit accumulator
|
||||||
|
LDA.b OverworldIndex : CMP.w #$0030 : BNE ++ ; Desert
|
||||||
|
SEP #$20 ; set 8-bit accumulator
|
||||||
|
LDA.b #$02 : STA.b LinkDirection ; face link forward
|
||||||
|
LDA.b #$3C : STA.b LinkIncapacitatedTimer ; lock link for 60f
|
||||||
|
++
|
||||||
|
SEP #$20 ; set 8-bit accumulator
|
||||||
|
+
|
||||||
|
PLP : PLA
|
||||||
|
RTL
|
||||||
|
;--------------------------------------------------------------------------------
|
||||||
IsMedallion:
|
IsMedallion:
|
||||||
REP #$20 ; set 16-bit accumulator
|
REP #$20 ; set 16-bit accumulator
|
||||||
LDA.b OverworldIndex
|
LDA.b OverworldIndex
|
||||||
|
|||||||
@@ -40,7 +40,7 @@ RenderCharToMapExtended:
|
|||||||
sta.b Scrap05
|
sta.b Scrap05
|
||||||
jml RenderCharToMapExtended_return
|
jml RenderCharToMapExtended_return
|
||||||
|
|
||||||
.uncompressed
|
.uncompressed
|
||||||
lda.l FontProperties+$2, x
|
lda.l FontProperties+$2, x
|
||||||
plx
|
plx
|
||||||
clc : adc.w #(NewFont&$ffff)
|
clc : adc.w #(NewFont&$ffff)
|
||||||
@@ -92,7 +92,7 @@ RenderCharLookupWidth:
|
|||||||
plx : lda.l RenderCharThinTable, x : clc
|
plx : lda.l RenderCharThinTable, x : clc
|
||||||
rtl
|
rtl
|
||||||
.vwf
|
.vwf
|
||||||
and.w #$000f
|
and.w #$000f
|
||||||
plx : cpx.w #$0000 : beq + : lda.l RenderCharThinTable, x
|
plx : cpx.w #$0000 : beq + : lda.l RenderCharThinTable, x
|
||||||
+ clc : rtl
|
+ clc : rtl
|
||||||
|
|
||||||
@@ -140,7 +140,7 @@ RenderCharExtended:
|
|||||||
cpx.w #$0010
|
cpx.w #$0010
|
||||||
bne -
|
bne -
|
||||||
|
|
||||||
.end
|
.end
|
||||||
plb
|
plb
|
||||||
jml RenderCharExtended_returnUncompressed
|
jml RenderCharExtended_returnUncompressed
|
||||||
|
|
||||||
@@ -368,7 +368,7 @@ FontProperties:
|
|||||||
dw $8001, $06C0 ; C7 ; !
|
dw $8001, $06C0 ; C7 ; !
|
||||||
dw $8001, $02D0 ; C8 ; ,
|
dw $8001, $02D0 ; C8 ; ,
|
||||||
dw $8001, $02B0 ; C9 ; -
|
dw $8001, $02B0 ; C9 ; -
|
||||||
dw $8000, $0000 ; CA ; 🡄
|
dw $8000, $0000 ; CA ; 🡄"
|
||||||
dw $8000, $0000 ; CB ; 🡆
|
dw $8000, $0000 ; CB ; 🡆
|
||||||
dw $0000, $0000 ; CC ; Blank char
|
dw $0000, $0000 ; CC ; Blank char
|
||||||
dw $8001, $02C0 ; CD ; .
|
dw $8001, $02C0 ; CD ; .
|
||||||
|
|||||||
@@ -192,6 +192,7 @@ LoadBackgroundGraphics_arbitrary = $80E64D
|
|||||||
RoomTag_GetHeartForPrize = $81C709
|
RoomTag_GetHeartForPrize = $81C709
|
||||||
RoomTag_GetHeartForPrize_spawn_prize = $81C731
|
RoomTag_GetHeartForPrize_spawn_prize = $81C731
|
||||||
RoomTag_GetHeartForPrize_delete_tag = $81C749
|
RoomTag_GetHeartForPrize_delete_tag = $81C749
|
||||||
|
RoomTag_GetHeartForPrize_exit = $81C74D
|
||||||
Underworld_SetBossOrSancMusicUponEntry = $828AD9
|
Underworld_SetBossOrSancMusicUponEntry = $828AD9
|
||||||
ResetThenCacheRoomEntryProperties = $828C73
|
ResetThenCacheRoomEntryProperties = $828C73
|
||||||
RecoverPositionAfterDrowning = $829485
|
RecoverPositionAfterDrowning = $829485
|
||||||
@@ -273,6 +274,7 @@ PalettesVanilla_spraux09 = $9BD47E
|
|||||||
; Misc. Data
|
; Misc. Data
|
||||||
;===================================================================================================
|
;===================================================================================================
|
||||||
DungeonMask = $8098C0
|
DungeonMask = $8098C0
|
||||||
|
RoomFlagMask = $809900
|
||||||
GFXSheetPointers_background_bank = $80CFC0
|
GFXSheetPointers_background_bank = $80CFC0
|
||||||
GFXSheetPointers_background_high = $80D09F
|
GFXSheetPointers_background_high = $80D09F
|
||||||
GFXSheetPointers_background_low = $80D17E
|
GFXSheetPointers_background_low = $80D17E
|
||||||
@@ -292,7 +294,6 @@ EntranceData_song = $82D592
|
|||||||
SpawnPointData_room_id = $82D8D2
|
SpawnPointData_room_id = $82D8D2
|
||||||
Overworld_CheckForSpecialOverworldTrigger_Direction = $84E879
|
Overworld_CheckForSpecialOverworldTrigger_Direction = $84E879
|
||||||
RoomHeaderPointers = $84F1E2
|
RoomHeaderPointers = $84F1E2
|
||||||
UncleItem = $85DF45
|
|
||||||
Sprite_ShowSolicitedMessage_Direction = $85E1A3
|
Sprite_ShowSolicitedMessage_Direction = $85E1A3
|
||||||
FluteMenuNumbers_bits = $8AB7A3
|
FluteMenuNumbers_bits = $8AB7A3
|
||||||
WorldMap_RedXChars = $8ABF70
|
WorldMap_RedXChars = $8ABF70
|
||||||
|
|||||||
14
zelda.asm
14
zelda.asm
@@ -1,14 +1,10 @@
|
|||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
EndRainState:
|
EndRainState:
|
||||||
LDA.l InitProgressIndicator : BIT.b #$80 : BEQ + ; check for instant post-aga
|
LDA.l InitProgressIndicator : BIT.b #$80 : BNE + ; check for instant post-aga
|
||||||
LDA.l InitLumberjackOW : STA.l OverworldEventDataWRAM+$02
|
LDA.b #$02 : STA.l ProgressIndicator
|
||||||
LDA.b #$03
|
RTL
|
||||||
BRA ++
|
|
||||||
+
|
+
|
||||||
LDA.b #$02
|
LDA.b #$03 : STA.l ProgressIndicator
|
||||||
++
|
LDA.l InitLumberjackOW : STA.l OverworldEventDataWRAM+$02
|
||||||
STA.l ProgressIndicator
|
|
||||||
|
|
||||||
JSL SetEscapeAssist
|
|
||||||
RTL
|
RTL
|
||||||
;--------------------------------------------------------------------------------
|
;--------------------------------------------------------------------------------
|
||||||
|
|||||||
Reference in New Issue
Block a user