Skip to content

Commit

Permalink
Zillion: cache key includes gun requirement (ArchipelagoMW#1846)
Browse files Browse the repository at this point in the history
The key for the logic cache was missing some important information, so it was yielding a cache hit when it should have been a miss.
  • Loading branch information
beauxq authored May 31, 2023
1 parent df7462e commit 1809823
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion worlds/zillion/logic.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ def set_randomizer_locs(cs: CollectionState, p: int, zz_r: Randomizer) -> int:
if isinstance(z_loc.item, ZillionItem) and z_loc.item.player == p \
else zz_empty
zz_r.locations[zz_name].item = zz_item
_hash += hash(zz_name) ^ hash(zz_item)
_hash += (hash(zz_name) * (z_loc.zz_loc.req.gun + 2)) ^ hash(zz_item)
return _hash


Expand Down

0 comments on commit 1809823

Please sign in to comment.