From 1099482abd09f06b821aa712dc59136f494dd649 Mon Sep 17 00:00:00 2001 From: threeandthreee Date: Mon, 16 Sep 2024 15:21:33 -0400 Subject: [PATCH 1/2] implement StealingInLogic option --- worlds/ladx/LADXR/generator.py | 6 ------ worlds/ladx/LADXR/logic/overworld.py | 8 ++++++-- worlds/ladx/Options.py | 17 +++++++++++------ worlds/ladx/docs/en_Links Awakening DX.md | 2 +- 4 files changed, 18 insertions(+), 15 deletions(-) diff --git a/worlds/ladx/LADXR/generator.py b/worlds/ladx/LADXR/generator.py index 69e856f3541..32f735c4e4d 100644 --- a/worlds/ladx/LADXR/generator.py +++ b/worlds/ladx/LADXR/generator.py @@ -233,12 +233,6 @@ def generateRom(args, world: "LinksAwakeningWorld"): # The default rom has this build in, just need to set a flag and we get this save. rom.patch(0, 0x0003, "00", "01") - # Patch the sword check on the shopkeeper turning around. - if world.ladxr_settings.steal == 'never': - rom.patch(4, 0x36F9, "FA4EDB", "3E0000") - elif world.ladxr_settings.steal == 'always': - rom.patch(4, 0x36F9, "FA4EDB", "3E0100") - if world.ladxr_settings.hpmode == 'inverted': patches.health.setStartHealth(rom, 9) elif world.ladxr_settings.hpmode == '1': diff --git a/worlds/ladx/LADXR/logic/overworld.py b/worlds/ladx/LADXR/logic/overworld.py index 551cf8353f4..a18add56d72 100644 --- a/worlds/ladx/LADXR/logic/overworld.py +++ b/worlds/ladx/LADXR/logic/overworld.py @@ -40,8 +40,12 @@ def __init__(self, options, world_setup, r): self._addEntrance("start_house", mabe_village, start_house, None) shop = Location("Shop") - Location().add(ShopItem(0)).connect(shop, OR(COUNT("RUPEES", 500), SWORD)) - Location().add(ShopItem(1)).connect(shop, OR(COUNT("RUPEES", 1480), SWORD)) + if options.steal: + Location().add(ShopItem(0)).connect(shop, OR(COUNT("RUPEES", 500), SWORD)) + Location().add(ShopItem(1)).connect(shop, OR(COUNT("RUPEES", 1480), SWORD)) + else: + Location().add(ShopItem(0)).connect(shop, COUNT("RUPEES", 500)) + Location().add(ShopItem(1)).connect(shop, COUNT("RUPEES", 1480)) self._addEntrance("shop", mabe_village, shop, None) dream_hut = Location("Dream Hut") diff --git a/worlds/ladx/Options.py b/worlds/ladx/Options.py index c5dcc080537..41571b9d01b 100644 --- a/worlds/ladx/Options.py +++ b/worlds/ladx/Options.py @@ -284,12 +284,15 @@ class MusicChangeCondition(Choice): # [Hero] Switch version hero mode, double damage, no heart/fairy drops. # [One hit KO] You die on a single hit, always."""), -# Setting('steal', 'Gameplay', 't', 'Stealing from the shop', -# options=[('always', 'a', 'Always'), ('never', 'n', 'Never'), ('default', '', 'Normal')], default='default', -# description="""Effects when you can steal from the shop. Stealing is bad and never in logic. -# [Normal] requires the sword before you can steal. -# [Always] you can always steal from the shop -# [Never] you can never steal from the shop."""), + +class StealingInLogic(DefaultOffToggle, LADXROption): + """ + Puts stealing from the shop in logic if the player has a sword. + """ + display_name = "Stealing in Logic" + ladxr_name = "steal" + + class Bowwow(Choice): """Allows BowWow to be taken into any area. Certain enemies and bosses are given a new weakness to BowWow. [Normal] BowWow is in the item pool, but can be logically expected as a damage source. @@ -521,6 +524,7 @@ class AdditionalWarpPoints(DefaultOffToggle): OptionGroup("Miscellaneous", [ TradeQuest, Rooster, + StealingInLogic, TrendyGame, NagMessages, BootsControls @@ -579,3 +583,4 @@ class LinksAwakeningOptions(PerGameCommonOptions): nag_messages: NagMessages ap_title_screen: APTitleScreen boots_controls: BootsControls + stealing_in_logic: StealingInLogic diff --git a/worlds/ladx/docs/en_Links Awakening DX.md b/worlds/ladx/docs/en_Links Awakening DX.md index 91a34107c16..03add266ffd 100644 --- a/worlds/ladx/docs/en_Links Awakening DX.md +++ b/worlds/ladx/docs/en_Links Awakening DX.md @@ -85,7 +85,7 @@ Title screen graphics by toomanyteeth✨ (https://instagram.com/toomanyyyteeth)

The walrus is moved a bit, so that you can access the desert without taking Marin on a date.

Logic

-

Depending on your options, you can only steal after you find the sword, always, or never.

+

Depending on your options, you can only steal after you find the sword.

Do not forget that there are two items in the rafting ride. You can access this with just Hookshot or Flippers.

Killing enemies with bombs is in normal logic. You can switch to casual logic if you do not want this.

D7 confuses some people, but by dropping down pits on the 2nd floor you can access almost all of this dungeon, even without feather and power bracelet.

From b1002f234fb91e57bcbda023fa672a064958ff5f Mon Sep 17 00:00:00 2001 From: threeandthreee Date: Mon, 16 Sep 2024 15:29:48 -0400 Subject: [PATCH 2/2] fix ladxr setting --- worlds/ladx/LADXR/settings.py | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/worlds/ladx/LADXR/settings.py b/worlds/ladx/LADXR/settings.py index 848d64390de..33bb550c44b 100644 --- a/worlds/ladx/LADXR/settings.py +++ b/worlds/ladx/LADXR/settings.py @@ -161,12 +161,8 @@ def __init__(self, ap_options): [Oracle] Less iframes and heath from drops. Bombs damage yourself. Water damages you without flippers. No piece of power or acorn. [Hero] Switch version hero mode, double damage, no heart/fairy drops. [One hit KO] You die on a single hit, always."""), - Setting('steal', 'Gameplay', 't', 'Stealing from the shop', - options=[('always', 'a', 'Always'), ('never', 'n', 'Never'), ('default', '', 'Normal')], default='default', - description="""Effects when you can steal from the shop. Stealing is bad and never in logic. -[Normal] requires the sword before you can steal. -[Always] you can always steal from the shop -[Never] you can never steal from the shop."""), + Setting('steal', 'Gameplay', 't', 'Stealing from the shop', default=False, + description='Toggle if stealing is in logic.'), Setting('bowwow', 'Special', 'g', 'Good boy mode', options=[('normal', '', 'Disabled'), ('always', 'a', 'Enabled'), ('swordless', 's', 'Enabled (swordless)')], default='normal', description='Allows BowWow to be taken into any area, damage bosses and more enemies. If enabled you always start with bowwow. Swordless option removes the swords from the game and requires you to beat the game without a sword and just bowwow.'), Setting('overworld', 'Special', 'O', 'Overworld', options=[('normal', '', 'Normal'), ('dungeondive', 'D', 'Dungeon dive'), ('nodungeons', 'N', 'No dungeons'), ('random', 'R', 'Randomized')], default='normal',