In vanilla Minecraft, Iron Golems are sooooo bad at protecting villagers. This mod overhauls how golems choose their targets and how far they reach for targets, making them actively defend villagers from danger instead of getting distracted by random mobs, or not acting at all.
Features:
- Golems prioritize enemies that are actively hunting, hurting, or cornering villagers.
- Mobs that don't attack villagers (like spiders or skeletons) aren't targeted by golems.
- The mod's new mechanism doesn't target drowneds in the water.
- Paths are calculated in the background on a separate thread, so large search ranges don't lag the main thread.
- If the village is safe, golems fall back to normal vanilla behavior (wandering, handing out roses, and patrolling).
How It Works:
1. When near living villagers, the golem scans a 48-block radius for threats.
2. Enemies are scored based on real danger to the village:
- Actively targeting a villager (+100)
- Damaging a villager recently (+80)
- Zombie breaking a villager's door (+40)
- Villager is panicking (+25)
- Proximity to villagers (closer = higher urgency)
3. The score is scaled by the walking path distance from the golem to the threat. A threat 5 blocks away from the golem will be prioritized over one 40 blocks away.
4. Golems keep pursuing their target up to 10 blocks past the scan radius, and take a brief 1-second breather after defeating a target before re-scanning.

