mirror of
https://github.com/horizon-rust/horizon.git
synced 2026-11-09 02:29:50 -10:00
Mod port harness: drop 1.21.1's player. attribute prefix too
1.21.2 renamed player.entity_interaction_range, player.block_interaction_range and the other player.* attributes along with generic.*, so a spear's interaction range never matched the oracle's. Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
1 parent
fd41f0e36f
commit
a502eccc92
1 file changed
+4
-2
@@ -90,8 +90,10 @@ def sound_upgrades(oracle, horizon):
|
||||
|
||||
|
||||
def modifiers(entries):
|
||||
"""Attribute modifiers as comparable tuples, 1.21.1's `generic.` attribute prefix dropped."""
|
||||
return sorted((m['type'].replace(':generic.', ':'), m['id'], round(m['amount'], 4), m['operation'], m['slot'])
|
||||
"""Attribute modifiers as comparable tuples, 1.21.1's `generic.` and `player.` attribute prefixes dropped
|
||||
(1.21.2 renamed `player.entity_interaction_range` and the others too)."""
|
||||
return sorted((m['type'].replace(':generic.', ':').replace(':player.', ':'), m['id'], round(m['amount'], 4),
|
||||
m['operation'], m['slot'])
|
||||
for m in entries)
|
||||
|
||||
|
||||
|
||||
Reference in new issue
Block a user