Merge of various fixes
This commit is contained in:
51
Bosses.py
51
Bosses.py
@@ -119,11 +119,11 @@ def can_place_boss(world, player, boss, dungeon_name, level=None):
|
||||
if world.swords[player] in ['swordless'] and boss == 'Kholdstare' and dungeon_name != 'Ice Palace':
|
||||
return False
|
||||
|
||||
if dungeon_name in ['Ganons Tower', 'Inverted Ganons Tower'] and level == 'top':
|
||||
if dungeon_name == 'Ganons Tower' and level == 'top':
|
||||
if boss in ["Armos Knights", "Arrghus", "Blind", "Trinexx", "Lanmolas"]:
|
||||
return False
|
||||
|
||||
if dungeon_name in ['Ganons Tower', 'Inverted Ganons Tower'] and level == 'middle':
|
||||
if dungeon_name == 'Ganons Tower' and level == 'middle':
|
||||
if boss in ["Blind"]:
|
||||
return False
|
||||
|
||||
@@ -141,38 +141,21 @@ def place_bosses(world, player):
|
||||
if world.boss_shuffle[player] == 'none':
|
||||
return
|
||||
# Most to least restrictive order
|
||||
if world.mode[player] != 'inverted':
|
||||
boss_locations = [
|
||||
['Ganons Tower', 'top'],
|
||||
['Tower of Hera', None],
|
||||
['Skull Woods', None],
|
||||
['Ganons Tower', 'middle'],
|
||||
['Eastern Palace', None],
|
||||
['Desert Palace', None],
|
||||
['Palace of Darkness', None],
|
||||
['Swamp Palace', None],
|
||||
['Thieves Town', None],
|
||||
['Ice Palace', None],
|
||||
['Misery Mire', None],
|
||||
['Turtle Rock', None],
|
||||
['Ganons Tower', 'bottom'],
|
||||
]
|
||||
else:
|
||||
boss_locations = [
|
||||
['Inverted Ganons Tower', 'top'],
|
||||
['Tower of Hera', None],
|
||||
['Skull Woods', None],
|
||||
['Inverted Ganons Tower', 'middle'],
|
||||
['Eastern Palace', None],
|
||||
['Desert Palace', None],
|
||||
['Palace of Darkness', None],
|
||||
['Swamp Palace', None],
|
||||
['Thieves Town', None],
|
||||
['Ice Palace', None],
|
||||
['Misery Mire', None],
|
||||
['Turtle Rock', None],
|
||||
['Inverted Ganons Tower', 'bottom'],
|
||||
]
|
||||
boss_locations = [
|
||||
['Ganons Tower', 'top'],
|
||||
['Tower of Hera', None],
|
||||
['Skull Woods', None],
|
||||
['Ganons Tower', 'middle'],
|
||||
['Eastern Palace', None],
|
||||
['Desert Palace', None],
|
||||
['Palace of Darkness', None],
|
||||
['Swamp Palace', None],
|
||||
['Thieves Town', None],
|
||||
['Ice Palace', None],
|
||||
['Misery Mire', None],
|
||||
['Turtle Rock', None],
|
||||
['Ganons Tower', 'bottom'],
|
||||
]
|
||||
|
||||
all_bosses = sorted(boss_table.keys()) #s orted to be deterministic on older pythons
|
||||
placeable_bosses = [boss for boss in all_bosses if boss not in ['Agahnim', 'Agahnim2', 'Ganon']]
|
||||
|
||||
36
Gui.py
36
Gui.py
@@ -38,7 +38,10 @@ def guiMain(args=None):
|
||||
farBottomFrame = Frame(mainWindow)
|
||||
|
||||
def open_output():
|
||||
open_file(output_path(''))
|
||||
if args and args.outputpath:
|
||||
open_file(output_path(args.outputpath))
|
||||
else:
|
||||
open_file(output_path(''))
|
||||
|
||||
openOutputButton = Button(farBottomFrame, text='Open Output Directory', command=open_output)
|
||||
|
||||
@@ -317,24 +320,6 @@ def guiMain(args=None):
|
||||
doorShuffleLabel = Label(doorShuffleFrame, text='Door shuffle algorithm')
|
||||
doorShuffleLabel.pack(side=LEFT)
|
||||
|
||||
heartbeepFrame = Frame(drowDownFrame)
|
||||
heartbeepOptionMenu = OptionMenu(heartbeepFrame, heartbeepVar, 'double', 'normal', 'half', 'quarter', 'off')
|
||||
heartbeepOptionMenu.pack(side=RIGHT)
|
||||
heartbeepLabel = Label(heartbeepFrame, text='Heartbeep sound rate')
|
||||
heartbeepLabel.pack(side=LEFT)
|
||||
|
||||
heartcolorFrame = Frame(drowDownFrame)
|
||||
heartcolorOptionMenu = OptionMenu(heartcolorFrame, heartcolorVar, 'red', 'blue', 'green', 'yellow', 'random')
|
||||
heartcolorOptionMenu.pack(side=RIGHT)
|
||||
heartcolorLabel = Label(heartcolorFrame, text='Heart color')
|
||||
heartcolorLabel.pack(side=LEFT)
|
||||
|
||||
fastMenuFrame = Frame(drowDownFrame)
|
||||
fastMenuOptionMenu = OptionMenu(fastMenuFrame, fastMenuVar, 'normal', 'instant', 'double', 'triple', 'quadruple', 'half')
|
||||
fastMenuOptionMenu.pack(side=RIGHT)
|
||||
fastMenuLabel = Label(fastMenuFrame, text='Menu speed')
|
||||
fastMenuLabel.pack(side=LEFT)
|
||||
|
||||
logicFrame.pack(expand=True, anchor=E)
|
||||
accessibilityFrame.pack(expand=True, anchor=E)
|
||||
|
||||
@@ -485,6 +470,7 @@ def guiMain(args=None):
|
||||
int(triforcecountVar.get()), int(triforceVar.get()), int(rupoorcostVar.get()), int(universalkeyVar.get())]
|
||||
guiargs.rom = romVar.get()
|
||||
guiargs.sprite = sprite
|
||||
guiargs.outputpath = args.outputpath if args else None
|
||||
# get default values for missing parameters
|
||||
for k,v in vars(parse_arguments(['--multi', str(guiargs.multi)])).items():
|
||||
if k not in vars(guiargs):
|
||||
@@ -1244,8 +1230,11 @@ def guiMain(args=None):
|
||||
keyshuffleVar.set(args.keyshuffle)
|
||||
bigkeyshuffleVar.set(args.bigkeyshuffle)
|
||||
retroVar.set(args.retro)
|
||||
openpyramidVar.set(args.openpyramid)
|
||||
quickSwapVar.set(int(args.quickswap))
|
||||
disableMusicVar.set(int(args.disablemusic))
|
||||
if args.multi:
|
||||
worldVar.set(str(args.multi))
|
||||
if args.count:
|
||||
countVar.set(str(args.count))
|
||||
if args.seed:
|
||||
@@ -1263,12 +1252,21 @@ def guiMain(args=None):
|
||||
algorithmVar.set(args.algorithm)
|
||||
shuffleVar.set(args.shuffle)
|
||||
doorShuffleVar.set(args.door_shuffle)
|
||||
heartcolorVar.set(args.heartcolor)
|
||||
heartbeepVar.set(args.heartbeep)
|
||||
fastMenuVar.set(args.fastmenu)
|
||||
logicVar.set(args.logic)
|
||||
romVar.set(args.rom)
|
||||
shuffleGanonVar.set(args.shuffleganon)
|
||||
hintsVar.set(args.hints)
|
||||
enemizerCLIpathVar.set(args.enemizercli)
|
||||
potShuffleVar.set(args.shufflepots)
|
||||
enemyShuffleVar.set(args.shuffleenemies)
|
||||
enemizerBossVar.set(args.shufflebosses)
|
||||
enemizerDamageVar.set(args.enemy_damage)
|
||||
enemizerHealthVar.set(args.enemy_health)
|
||||
owPalettesVar.set(args.ow_palettes)
|
||||
uwPalettesVar.set(args.uw_palettes)
|
||||
if args.sprite is not None:
|
||||
set_sprite(Sprite(args.sprite))
|
||||
|
||||
|
||||
15
Rom.py
15
Rom.py
@@ -241,9 +241,9 @@ def patch_enemizer(world, player, rom, baserom_path, enemizercli, shufflepots, r
|
||||
'IcePalace': world.get_dungeon("Ice Palace", player).boss.enemizer_name,
|
||||
'MiseryMire': world.get_dungeon("Misery Mire", player).boss.enemizer_name,
|
||||
'TurtleRock': world.get_dungeon("Turtle Rock", player).boss.enemizer_name,
|
||||
'GanonsTower1': world.get_dungeon('Ganons Tower' if world.mode[player] != 'inverted' else 'Inverted Ganons Tower', player).bosses['bottom'].enemizer_name,
|
||||
'GanonsTower2': world.get_dungeon('Ganons Tower' if world.mode[player] != 'inverted' else 'Inverted Ganons Tower', player).bosses['middle'].enemizer_name,
|
||||
'GanonsTower3': world.get_dungeon('Ganons Tower' if world.mode[player] != 'inverted' else 'Inverted Ganons Tower', player).bosses['top'].enemizer_name,
|
||||
'GanonsTower1': world.get_dungeon('Ganons Tower', player).bosses['bottom'].enemizer_name,
|
||||
'GanonsTower2': world.get_dungeon('Ganons Tower', player).bosses['middle'].enemizer_name,
|
||||
'GanonsTower3': world.get_dungeon('Ganons Tower', player).bosses['top'].enemizer_name,
|
||||
'GanonsTower4': 'Agahnim2',
|
||||
'Ganon': 'Ganon',
|
||||
}
|
||||
@@ -1736,6 +1736,15 @@ def write_strings(rom, world, player, team):
|
||||
tt[hint_locations.pop(0)] = this_hint
|
||||
hint_count -= 1
|
||||
|
||||
# Adding a hint for the Thieves' Town Attic location in Crossed Doorshufle.
|
||||
if world.doorShuffle[player] in ['crossed']:
|
||||
attic_hint = world.get_location("Thieves' Town - Attic", player).parent_region.dungeon.name
|
||||
this_hint = 'A cracked floor can be found in ' + attic_hint + '.'
|
||||
if hint_locations[0] == 'telepathic_tile_thieves_town_upstairs':
|
||||
tt[hint_locations.pop(1)] = this_hint
|
||||
else:
|
||||
tt[hint_locations.pop(0)] = this_hint
|
||||
|
||||
# All remaining hint slots are filled with junk hints. It is done this way to ensure the same junk hint isn't selected twice.
|
||||
junk_hints = junk_texts.copy()
|
||||
random.shuffle(junk_hints)
|
||||
|
||||
Reference in New Issue
Block a user