Skip to content

Commit 6c1d164

Browse files
committed
LttP: set non-native items to Power Star
1 parent 937fee9 commit 6c1d164

File tree

1 file changed

+13
-8
lines changed

1 file changed

+13
-8
lines changed

worlds/alttp/Rom.py

+13-8
Original file line numberDiff line numberDiff line change
@@ -751,13 +751,18 @@ def write_to_rom(self, rom: LocalRom):
751751
0x4D3F8, 0x4D416, 0x4D420, 0x4D423, 0x4D42D, 0x4D449, 0x4D48C, 0x4D4D9, 0x4D4DC, 0x4D4E3,
752752
0x4D504, 0x4D507, 0x4D55E, 0x4D56A]
753753

754-
def get_nonnative_item_sprite(game):
755-
game_to_id = {
756-
"Factorio": 0x09, # Hammer
757-
"Hollow Knight": 0x21, # Bug Catching Net
758-
"Minecraft": 0x13, # Shovel
759-
}
760-
return game_to_id.get(game, 0x6B) # default to Power Star
754+
def get_nonnative_item_sprite(game: str) -> int:
755+
return 0x6B # set all non-native sprites to Power Star as per 13 to 2 vote at
756+
# https://discord.com/channels/731205301247803413/827141303330406408/852102450822905886
757+
758+
# def get_nonnative_item_sprite(game):
759+
# game_to_id = {
760+
# "Factorio": 0x09, # Hammer
761+
# "Hollow Knight": 0x21, # Bug Catching Net
762+
# "Minecraft": 0x13, # Shovel
763+
# }
764+
# return game_to_id.get(game, 0x6B) # default to Power Star
765+
761766

762767
def patch_rom(world, rom, player, team, enemized):
763768
local_random = world.slot_seeds[player]
@@ -1730,7 +1735,7 @@ def write_custom_shops(rom, world, player):
17301735
item_game = 'Factorio'
17311736
elif item_name in mc_lookup.values():
17321737
item_game = 'Minecraft'
1733-
else:
1738+
else:
17341739
item_game = 'Generic'
17351740
item_code = get_nonnative_item_sprite(item_game)
17361741
else:

0 commit comments

Comments
 (0)