Tags
Creators
Details
1.0.0-Alpha
Compatibility
Changes
VillageLife Mod - Changelog
Version 1.0.0-alpha
Overview
VillageLife transforms Minecraft 1.12.2 villages into dynamic, living communities with intelligent villager behavior, custom iron golem AI, and quality-of-life improvements that make villages feel more alive and defensible.
Current Features
Custom Iron Golem AI System
Complete replacement of vanilla iron golem behavior with sophisticated custom AI:
Heightmap-Based Pathfinding
- Pre-calculates terrain before movement for smoother navigation
- Uses decimal precision height calculations based on Minecraft's bounding box system
- Dynamically resizing heightmap scanner (32x32 default, expands as needed)
- Handles slopes, stairs, slabs, and varied terrain heights accurately
Roaming Behavior
- Golems patrol the village area naturally
- Pick random destinations within village bounds
- Stuck detection with automatic rerouting after failed paths
- Falls back to nearby destinations after consecutive pathfinding failures
Distress Response System
- Villagers send distress signals when attacked by hostile mobs
- Expanding radius search: starts at 8 blocks, grows 1 block/second up to village radius
- Golems respond with phases: RESPONDING → ATTACKING → GUARDING
- Multi-attacker handling with priority queue (most recent attacker first)
- Hybrid chase detection: 1.5 second threshold before damage triggers distress
Combat Priorities
- Self-Defense - If attacked by any mob (except players), golem defends itself immediately
- Opportunistic Attacks - While en route to villager, attacks hostile if closer than villager
- Protect Villager - Moves to villager, eliminates all threats
- Guard Duty - Follows villager for 30 seconds after threat cleared
- Help Others - During guarding, can switch to help other villagers under attack
Spawn Management
- Replaces vanilla iron golem spawns with custom golems
- Prevents duplicate spawns on world load
Villager Distress Manager
Central coordinator for villager protection:
- Attack Detection: Monitors LivingAttackEvent for villager damage
- Chase Detection: Detects when hostile mobs target villagers (before damage)
- Attacker Tracking: Maintains list of active attackers per villager
- Golem Assignment: Coordinates which golem responds to which villager
- Cleanup: Automatically removes stale entries, dead mobs, cleared threats
Villager Quality of Life
Gate & Door Handling
- Villagers can now open and close fence gates
- Custom AI task for gate navigation
- Proper pathfinding through gated areas
Personal Space System
- Fluid dynamics-inspired spacing to prevent villager stacking
- Adaptive wall-aware spacing adjusts near obstacles
- Prevents oscillation and jittering
Pressure Plate Avoidance (Configurable)
- Villagers avoid stepping on pressure plates
- Prevents accidental trap triggering
Villager Repopulation System
Prevents villages from becoming permanently empty:
Works on ANY Active Village
- Vanilla generated villages
- Mod-created villages
- Player-created villages (place doors + bring 1 villager = instant village!)
- Checks all villages every 20 seconds
Automatic Spawning
- Triggers when villager count drops below 2
- Per-village cooldowns (5 minutes)
- Spawns villager just outside village radius
- Normal vanilla AI
Emergency Mode
- When a village hits 0 villagers, spawns immediately (skips cooldown)
- Prevents vanilla from removing the village before we can save it
Village Memory System
- Remembers locations of villages that had villagers
- Can revive villages removed from Minecraft's system
Debug Visualization (DEV_MODE only)
- Distress Visualizer - Shows villager distress and golem responses
- Path Visualizer - Shows golem pathfinding
- Villager Space Visualizer - Shows personal space system
Configuration
- In-game config GUI (Mod Options menu)
- DEV_MODE toggle for debug visualizations
- Pressure plate avoidance toggle
Roadmap (Planned Features)
- Early Shelter Seeking - Villagers seek shelter before sunset
- Attack Alerts - Player notification when village is under attack
- Villager Naming - Name tags show profession and home location
- Villager Torch Placement - Villagers place torches in dark areas (light ≤7)
Technical Details
Minecraft Version: 1.12.2
Mod ID: villagelife
Credits
Author: iammojogo
Projects on Modrinth are automatically available through a Maven repository for use with JVM build tools such as Gradle. To learn more about the Modrinth Maven API, click here.
Note: When available, you should use the creator's maven repo instead as it will have transitive dependency information that the Modrinth Maven API does not. You may also end up with duplicate dependencies if you use a mix of Modrinth and non-Modrinth Maven repositories for your dependencies, because the group identifier will be different when served through the Modrinth Maven API.
Maven coordinates:
Version ID:
build.gradle:
repositories {
exclusiveContent {
forRepository {
maven {
name = "Modrinth"
url = "https://api.modrinth.com/maven"
}
}
// forRepositories(fg.repository) // Uncomment when using ForgeGradle
filter {
includeGroup "maven.modrinth"
}
}
}
// Standard Gradle dependency
dependencies {
implementation "maven.modrinth:Io36QOq1:YyOrstx3"
}
// Legacy Loom dependency
dependencies {
modImplementation "maven.modrinth:Io36QOq1:YyOrstx3"
}

