Experimental no longer pre-opens stone walls

Updated baserom
Fixed a standard bug where the exits to the ledge would be unavailable if the pyramid was pre-opened
DR ASM optimization
Removed Archery Game from Take-Any caves in inverted
Fixed a problem with new YAML parser
This commit is contained in:
aerinon
2021-05-13 12:17:31 -06:00
parent 7764432683
commit f2318b821a
12 changed files with 56 additions and 33 deletions

View File

@@ -378,8 +378,11 @@ take_any_locations = [
def set_up_take_anys(world, player):
if world.mode[player] == 'inverted' and 'Dark Sanctuary Hint' in take_any_locations:
take_any_locations.remove('Dark Sanctuary Hint')
if world.mode[player] == 'inverted':
if 'Dark Sanctuary Hint' in take_any_locations:
take_any_locations.remove('Dark Sanctuary Hint')
if 'Archery Game' in take_any_locations:
take_any_locations.remove('Archery Game')
regions = random.sample(take_any_locations, 5)

View File

@@ -27,7 +27,7 @@ from Fill import sell_potions, sell_keys, balance_multiworld_progression, balanc
from ItemList import generate_itempool, difficulties, fill_prizes, customize_shops
from Utils import output_path, parse_player_names
__version__ = '0.4.0.0-u'
__version__ = '0.4.0.1-u'
class EnemizerError(RuntimeError):

View File

@@ -8,6 +8,12 @@ import yaml
from DungeonRandomizer import parse_cli
from Main import main as DRMain
from source.classes.BabelFish import BabelFish
from yaml.constructor import SafeConstructor
def add_bool(self, node):
return self.construct_scalar(node)
SafeConstructor.add_constructor(u'tag:yaml.org,2002:bool', add_bool)
def main():
parser = argparse.ArgumentParser(add_help=False)

View File

@@ -8,6 +8,20 @@ Thanks to qadan, cheuer, & compiling
* 0.4.0.1
* Moved stonewall pre-opening to not happen in experimental
* Updated baserom
* Boss RNG perseved between files
* Vanilla prize pack fix
* Starting equipment fix
* Post-Aga world state option
* Code optimzation
* Bottle quickswap via double shoulder
* Credits update
* Accessibility option
* Sewer map/compass fix
* Fixed a standard bug where the exits to the ledge would be unavailable if the pyramid was pre-opened
* DR ASM optimization
* Removed Archery Game from Take-Any caves in inverted
* Fixed a problem with new YAML parser
* 0.4.0.0
* Mystery yaml parser updated to a package maintained version (Thanks StructuralMike)
* Bomb-logic and extend crystal switch logic (Thanks StructuralMike)

30
Rom.py
View File

@@ -27,7 +27,7 @@ from EntranceShuffle import door_addresses, exit_ids
JAP10HASH = '03a63945398191337e896e5771f77173'
RANDOMIZERBASEHASH = '2a9cd9b95c0ad118a3d58a77b7197eab'
RANDOMIZERBASEHASH = '0c27ed494039b6da016678b8741939ed'
class JsonRom(object):
@@ -782,17 +782,19 @@ def patch_rom(world, rom, player, team, enemized, is_mystery=False):
| (0x4 if world.retro[player] else 0))
rom.write_byte(0x140001, multiClientFlags)
write_int16(rom, 0x187010, credits_total) # dynamic credits
#write_int16(rom, 0x187010, credits_total) # dynamic credits
if credits_total != 216:
# collection rate address: 238C37
# collection rate address:
cr_address = 0x2391BE
cr_pc = cr_address - 0x120000 # convert to pc
mid_top, mid_bot = credits_digit((credits_total // 10) % 10)
last_top, last_bot = credits_digit(credits_total % 10)
# top half
rom.write_byte(0x118C53, mid_top)
rom.write_byte(0x118C54, last_top)
rom.write_byte(cr_pc+0x1c, mid_top)
rom.write_byte(cr_pc+0x1d, last_top)
# bottom half
rom.write_byte(0x118C71, mid_bot)
rom.write_byte(0x118C72, last_bot)
rom.write_byte(cr_pc+0x3a, mid_bot)
rom.write_byte(cr_pc+0x3b, last_bot)
if world.keydropshuffle[player] or world.doorShuffle[player] != 'vanilla':
gt = world.dungeon_layouts[player]['Ganons Tower']
@@ -800,16 +802,18 @@ def patch_rom(world, rom, player, team, enemized, is_mystery=False):
total = 0
for region in gt.master_sector.regions:
total += count_locations_exclude_logic(region.locations, gt_logic)
rom.write_byte(0x187012, total) # dynamic credits
# gt big key address: 238B59
# rom.write_byte(0x187012, total) # dynamic credits
# gt big key address:
gtbk_address = 0x2390E0
gtbk_pc = gtbk_address - 0x120000 # convert to pc
mid_top, mid_bot = credits_digit(total // 10)
last_top, last_bot = credits_digit(total % 10)
# top half
rom.write_byte(0x118B75, mid_top)
rom.write_byte(0x118B76, last_top)
rom.write_byte(gtbk_pc+0x1c, mid_top)
rom.write_byte(gtbk_pc+0x1d, last_top)
# bottom half
rom.write_byte(0x118B93, mid_bot)
rom.write_byte(0x118B94, last_bot)
rom.write_byte(gtbk_pc+0x3a, mid_bot)
rom.write_byte(gtbk_pc+0x3b, last_bot)
# patch medallion requirements
if world.required_medallions[player][0] == 'Bombos':

View File

@@ -82,8 +82,8 @@ DrHudDungeonItemsAdditions:
- sta $1704, x : sta $170e, x : sta $1718, x
inx #2 : cpx #$0008 : !blt -
lda !HUD_FLAG : and.w #$0020 : beq + : brl ++ : +
lda HUDDungeonItems : and.w #$0007 : bne + : brl ++ : +
lda !HUD_FLAG : and.w #$0020 : beq + : JMP ++ : +
lda HUDDungeonItems : and.w #$0007 : bne + : JMP ++ : +
; bk symbols
lda.w #$2811 : sta $1606 : sta $1610 : sta $161a : sta $1624
; sm symbols
@@ -125,10 +125,10 @@ DrHudDungeonItemsAdditions:
lda.w #$24f5 : sta $1644, y
+
ldx $00
+ inx #2 : cpx #$001b : bcs ++ : brl -
+ inx #2 : cpx #$001b : bcs ++ : JMP -
++
lda !HUD_FLAG : and.w #$0020 : bne + : brl ++ : +
lda HUDDungeonItems : and.w #$000c : bne + : brl ++ : +
lda !HUD_FLAG : and.w #$0020 : bne + : JMP ++ : +
lda HUDDungeonItems : and.w #$000c : bne + : JMP ++ : +
; map symbols (do I want these) ; note compass symbol is 2c20
lda.w #$2821 : sta $1606 : sta $1610 : sta $161a : sta $1624
; blank out a couple thing from old hud
@@ -159,7 +159,7 @@ DrHudDungeonItemsAdditions:
.skipBlanks iny #2
cpx #$001a : beq +
lda.w #$24f5 : sta $1644, y ; blank out spot
+ inx #2 : cpx #$001b : !bge ++ : brl -
+ inx #2 : cpx #$001b : !bge ++ : JMP -
++
plp : ply : plx : rtl
}

View File

@@ -173,7 +173,7 @@ KeyGetPlayer:
LoadProperties_PreserveItemMaybe:
{
lda.l ShuffleKeyDrops : bne +
jsl Sprite_LoadProperties : rtl
JML Sprite_LoadProperties
+ lda $0e80, x : pha
jsl Sprite_LoadProperties
pla : sta $0e80, x

View File

@@ -399,8 +399,7 @@ StraightStairsTrapDoor:
lda #$05 : sta $11
inc $0468 : stz $068e : stz $0690
++ rtl
+ jsl Dungeon_ApproachFixedColor ; what we wrote over
rtl
+ JML Dungeon_ApproachFixedColor ; what we wrote over
}
InroomStairsTrapDoor:

View File

@@ -64,8 +64,7 @@ FixShopCode:
VitreousKeyReset:
lda.l DRMode : beq +
stz $0cba, x
+ jsl $0db818 ;restore old code
rtl
+ JML $0db818 ;restore old code
GuruguruFix:
lda $a0 : cmp #$df : !bge +
@@ -134,7 +133,7 @@ RainPrevention:
LDA.l $7EF3CC : AND #$00FF : CMP #$0001 : BEQ .done ; zelda is following
LDA $00 : CMP #$02A1 : BNE .done
PLA : LDA #$0008 : RTL
+ LDA.l BlockCastleDoorsInRain : BEQ .done ;flagged
+ LDA.l BlockCastleDoorsInRain : AND #$00FF : BEQ .done ;flagged
LDX #$FFFE
- INX #2 : LDA.l RemoveRainDoorsRoom, X : CMP #$FFFF : BEQ .done
CMP $A0 : BNE -

View File

@@ -209,12 +209,10 @@ QuadrantLoadOrderBeforeScroll:
lda $045f : beq .end
lda #$08 : sta $045c ; start with opposite quadrant row
.end
jsl $0091c4 ; what we overwrote
rtl
JML $0091c4 ; what we overwrote
QuadrantLoadOrderAfterScroll:
lda $045f : beq .end
stz $045c : stz $045f ; draw other row and clear flag
.end
jsl $0091c4 ; what we overwrote
rtl
JML $0091c4 ; what we overwrote

View File

@@ -182,7 +182,7 @@ InroomStairsWarp: {
sta $02
stz $07
lda $01 : and #$10 : lsr #4
brl .layer
JMP .layer
.notEdge
lda $01 : and #$03 : cmp #$03 : bne .normal
txa : and #$06 : sta $07

Binary file not shown.