Fake boots checkbox/argument

This commit is contained in:
aerinon
2021-07-07 16:23:16 -07:00
parent fb22c88ace
commit ffcc78f95c
11 changed files with 22 additions and 5 deletions

View File

@@ -131,6 +131,7 @@ class World(object):
set_player_attr('treasure_hunt_total', 0)
set_player_attr('potshuffle', False)
set_player_attr('pot_contents', None)
set_player_attr('fakeboots', False)
set_player_attr('shopsanity', False)
set_player_attr('keydropshuffle', False)

3
CLI.py
View File

@@ -97,7 +97,7 @@ def parse_cli(argv, no_defaults=False):
'shuffle', 'door_shuffle', 'intensity', 'crystals_ganon', 'crystals_gt', 'openpyramid',
'mapshuffle', 'compassshuffle', 'keyshuffle', 'bigkeyshuffle', 'startinventory',
'triforce_pool_min', 'triforce_pool_max', 'triforce_goal_min', 'triforce_goal_max',
'triforce_min_difference', 'triforce_goal', 'triforce_pool', 'shufflelinks',
'triforce_min_difference', 'triforce_goal', 'triforce_pool', 'shufflelinks', 'fakeboots',
'retro', 'accessibility', 'hints', 'beemizer', 'experimental', 'dungeon_counters',
'shufflebosses', 'shuffleenemies', 'enemy_health', 'enemy_damage', 'shufflepots',
'ow_palettes', 'uw_palettes', 'sprite', 'disablemusic', 'quickswap', 'fastmenu', 'heartcolor', 'heartbeep',
@@ -144,6 +144,7 @@ def parse_settings():
"shuffleganon": True,
"shuffle": "vanilla",
"shufflelinks": False,
"fakeboots": False,
"shufflepots": False,
"shuffleenemies": "none",

View File

@@ -90,6 +90,7 @@ def main(args, seed=None, fish=None):
world.treasure_hunt_count = args.triforce_goal.copy()
world.treasure_hunt_total = args.triforce_pool.copy()
world.shufflelinks = args.shufflelinks.copy()
world.fakeboots = args.fakeboots.copy()
world.rom_seeds = {player: random.randint(0, 999999999) for player in range(1, world.players + 1)}

View File

@@ -143,6 +143,7 @@ def roll_settings(weights):
ret.dungeon_counters = 'pickup' if ret.door_shuffle != 'vanilla' or ret.compassshuffle == 'on' else 'off'
ret.shufflelinks = get_choice('shufflelinks') == 'on'
ret.fakeboots = get_choice('fakeboots') == 'on'
ret.shopsanity = get_choice('shopsanity') == 'on'
ret.keydropshuffle = get_choice('keydropshuffle') == 'on'
ret.mixed_travel = get_choice('mixed_travel') if 'mixed_travel' in weights else 'prevent'

4
Rom.py
View File

@@ -18,7 +18,6 @@ except ImportError:
from BaseClasses import CollectionState, ShopType, Region, Location, Door, DoorType, RegionType, PotItem
from DoorShuffle import compass_data, DROptions, boss_indicator
from Dungeons import dungeon_music_addresses
from KeyDoorShuffle import count_locations_exclude_logic
from Regions import location_table, shop_to_location_table, retro_shops
from RoomData import DoorKind
from Text import MultiByteTextMapper, CompressedTextMapper, text_addresses, Credits, TextTable
@@ -1163,6 +1162,9 @@ def patch_rom(world, rom, player, team, enemized, is_mystery=False):
rom.write_byte(0x18017E, 0x01) # Fairy fountains only trade in bottles
# Starting equipment
if world.fakeboots[player]:
rom.write_byte(0x18008E, 0x01)
equip = [0] * (0x340 + 0x4F)
equip[0x36C] = 0x18
equip[0x36D] = 0x18

View File

@@ -310,6 +310,10 @@
"action": "store_true",
"type": "bool"
},
"fakeboots": {
"action": "store_true",
"type": "bool"
},
"calc_playthrough": {
"action": "store_false",
"type": "bool"

View File

@@ -262,6 +262,7 @@
"Keys are universal, shooting arrows costs rupees,",
"and a few other little things make this more like Zelda-1. (default: %(default)s)"
],
"fakeboots": [ " Players starts with fake boots that allow dashing but no item checks (default: %(default)s"],
"startinventory": [ "Specifies a list of items that will be in your starting inventory (separated by commas). (default: %(default)s)" ],
"usestartinventory": [ "Toggle usage of Starting Inventory." ],
"custom": [ "Not supported." ],

View File

@@ -189,6 +189,7 @@
"randomizer.item.hints": "Include Helpful Hints",
"randomizer.item.retro": "Retro mode (universal keys)",
"randomizer.item.fakeboots": "Start with Fake Boots",
"randomizer.item.worldstate": "World State",
"randomizer.item.worldstate.standard": "Standard",

View File

@@ -4,7 +4,8 @@
"shopsanity": { "type": "checkbox" },
"hints": {
"type": "checkbox"
}
},
"fakeboots": { "type": "checkbox" }
},
"leftItemFrame": {
"worldstate": {

View File

@@ -58,6 +58,7 @@ SETTINGSTOPROCESS = {
"hints": "hints",
"retro": "retro",
"shopsanity": "shopsanity",
"fakeboots": "fakeboots",
"worldstate": "mode",
"logiclevel": "logic",
"goal": "goal",

View File

@@ -1,4 +1,4 @@
from tkinter import ttk, Frame, E, W, LEFT, RIGHT
from tkinter import ttk, Frame, E, W, LEFT, RIGHT, Label
import source.gui.widgets as widgets
import json
import os
@@ -17,6 +17,9 @@ def item_page(parent):
self.frames["checkboxes"] = Frame(self)
self.frames["checkboxes"].pack(anchor=W)
various_options = Label(self.frames["checkboxes"], text="")
various_options.pack(side=LEFT)
self.frames["leftItemFrame"] = Frame(self)
self.frames["rightItemFrame"] = Frame(self)
self.frames["leftItemFrame"].pack(side=LEFT)
@@ -34,7 +37,7 @@ def item_page(parent):
self.widgets[key] = dictWidgets[key]
packAttrs = {"anchor":E}
if self.widgets[key].type == "checkbox":
packAttrs["anchor"] = W
packAttrs["side"] = LEFT
self.widgets[key].pack(packAttrs)
return self