
Eviction Notice
Keep villagers out of your house or base. Set a zone and villager AI pathfinding routes around it, so they stop using your doors and can't claim a bed or workstation inside. Wandering traders can be kept out too. No barrier blocks to place.
Описание

Keep villagers out of your house without iron doors. This mod lets you define a zone around your house that keeps villagers away and forces them to leave your beds and workstations alone.
Trading, breeding and everything else keeps working normally, just not on your doorstep.

The gold particles mark the zone edge for this clip; an in-game outline is planned.
Quick start
- Install Fabric API and Eviction Notice. In singleplayer, add both to your game. On a server, only the server needs them.
- Stand in the middle of your house.
- Run
/eviction set home 24
That's it. You now have a 49×49 zone around you that goes from the bottom of the world to the top.
Good to know
- Existing claims inside a new zone are released. A villager you haven't traded with yet loses its profession, the same as when you break its workstation. Villagers you've already traded with keep their job.
- Zones are squares centred on where you stand, with an optional height range.
- By default, zombie villagers are kept out and iron golems can still walk in. Wandering traders and their llamas can be kept out too. All of this can be changed in the config.
This mod was born out of annoyance in my Hardcore Forever World. Somehow the entire village decided to pathfind into the first floor and even the attic of my home and couldn't be convinced to leave.

Each zone works in three ways:
- Villagers walk around it. Their pathfinding treats the zone as blocked, so they go around your house instead of crowding at your door.
- They can't claim anything inside. Beds and workstations in a zone don't show up when villagers look for one. Claims from before the zone existed are released, so those villagers don't keep coming back.
- They get moved out. If a villager still ends up inside, for example because it spawned there or got pushed in, it's moved to the nearest safe spot outside your zones. It won't be put on lava, on your roof or into unloaded chunks.
You can make as many zones as you like, each with its own name, size and height range. Zones are saved with your world and belong to the player who made them.

| Command | What it does |
|---|---|
/eviction set <name> <radius> [yMin] [yMax] | Creates a zone centred on you |
/eviction list | Lists your zones |
/eviction here | Shows if you're standing in one of your zones |
/eviction remove <name> | Deletes a zone |
- The radius goes up to 256. Leave out
yMinandyMaxto cover the full height. - Zone names are one word (
home,base_2) and aren't case-sensitive. You can't use the same name twice, so you need to remove the old zone first. /eviction set home 24makes a zone 49 blocks wide, not 48, because the block you're standing on counts too, keep that in mind when creating a zone.
Multiplayer and permissions
- Every player can use
/evictionwithout operator rights or extra permissions. - Each player manages their own zones. There's no limit on how many zones a player can have. Zones can have a radius of up to 256 blocks.
- Zones keep out all villagers, not just the owner's, and nothing stops a zone being placed over someone else's build. Operators are told when a zone is created or removed.
- There are no admin commands yet. To remove another player's zone, stop the server and edit
eviction_notice/zones.jsonin the world folder.
Right now Eviction Notice is best suited to singleplayer, LAN and servers with players you trust. Server controls are planned.

The config is at config/eviction_notice.json. Restart the game or server after changing it.
| Option | Default | What it does |
|---|---|---|
evictionIntervalTicks | 20 | How often each zone is checked, in ticks (20 ticks = 1 second) |
mobs.zombieVillagers | true | Keeps zombie villagers out as well |
mobs.ironGolems | false | Keeps iron golems out as well |
mobs.wanderingTraders.enabled | false | Keeps wandering traders out as well |
mobs.wanderingTraders.llamas | true | Keeps their trader llamas out too. Only works while enabled is on |
Config files from 1.2.0 or older are converted to this layout when the game or server starts, and your settings are kept. If the file can't be read, for example because of a typo, the mod uses the defaults and leaves the file alone so you can fix it.

- Server-side only. It works the same in singleplayer, LAN and on dedicated servers. Players joining a server don't need to install anything.
- Safe to add to an existing world. Zones only affect villagers where you make them.
- Safe to remove. Villagers come and go as before. Your zones stay in
eviction_notice/zones.jsonin the world folder, so they're back if you install the mod again. - Works with other mods. It only changes villager pathfinding and how villagers find beds and workstations, and it never removes or replaces entities. Only mods that change those same things are likely to conflict. I run it alongside 65+ other mods without issues.
- Modpacks: Feel free to include it in modpacks. And let me know, so I can check it out!

The mod changes villager pathfinding so the blocks inside a zone count as unreachable. It filters the search villagers use to find beds and workstations, so the ones inside a zone are never found. A regular check moves any villager that is still inside to the nearest safe spot outside. Zones are looked up by chunk, so checking whether a spot is in a zone stays cheap even with many zones.
Bugs and ideas
Found a bug, had a crash or have an idea? Use the issue tracker. For bugs, please include your versions, your mod list and logs/latest.log.



