
Attack Range Attribute
A small API that adds an attack range entity attribute.
About this Mod
Attack Range Attribute
A small API that adds the "attackrangeattribute:generic.attack_range" entity attribute.
On its own this mod does NOT change gameplay. It does NOT change the attack range when used on its own.
Other mods like Better Combat Extension and Spell Engine Extension can optionally use this mod.
Vanilla Minecraft has the "entity_interaction_range" attribute. Why is an "attack_range" attribute necessary?
The entity_interaction_range attribute controls both the range of attacks and the range of right-click interactions (e.g. trading with villagers). This works fine in vanilla, since the entity_interaction_range doesn't change in normal gameplay.
However, in scenarios where different weapons are designed to have different attack ranges, the right-click interactions with entities get inconsistent and in extreme cases, when the attack range is 0, impossible.
API
Casting a "LivingEntity" to the "AttackRangeUsingEntity" interface gives access to all relevant methods.
Available Versions
How to Install Attack Range Attribute on Your Server
Order Server
Order a Minecraft Java server with at least 3 GB RAM (4 GB recommended).
Set fabric Loader
In the panel under "Egg", select the fabric loader and matching Minecraft version (1.21.1).
Install Mod
Open the mod browser in the dashboard and search for "Attack Range Attribute". Click "Install" – done! Alternatively, upload the .jar via SFTP to the /mods folder.
Compatibility
Mod Loaders
Minecraft Versions
1.21.1
Server-side
✓ RequiredRecommended RAM
4 GB(min. 3 GB)Frequently Asked Questions
Attack Range Attribute server crashes on startup – what to do?
Most common cause: wrong fabric version or insufficient RAM. Check the server log (latest.log) for "OutOfMemoryError" or "Mixin" errors. With Mado Hosting: ensure at least 3 GB RAM is allocated and the loader matches the mod version (1.21.1). You can switch loaders with one click in the panel.
Is Attack Range Attribute compatible with fabric?
Attack Range Attribute officially supports fabric for Minecraft 1.21.1. The Mado dashboard automatically detects incompatible loader combinations.
Server lagging with Attack Range Attribute – how to optimize performance?
Recommended RAM: 4 GB (per 8 players). Use /spark profiler to check if Attack Range Attribute consumes the most tick time. Common fixes: reduce server view-distance to 8-10, install "performant" or "starlight" as supplementary mods on Forge. With Mado Hosting, your server runs on NVMe SSDs with dedicated CPU cores for minimal latency.
Similar Mods
Rent Modded Server
Install Attack Range Attribute with just one click on your server.