Let There Be Portal Farms!
No reviews yet
A Fabric mod for preventing mob despawning when they change dimensions or enter a portal. Fixing portal-based farms. [portal mob despawn farm fix]
Fabric is a mod loader for versions 1.14+ of Minecraft, particularly popular for client side and optimization mods.
Community voices
Reviews
Click once to include, again to exclude, again to clear
No reviews yet. Be the first to review this project!
Get it on
Available Platforms
Compatibility
Supported Environments
About
Project Details
For authors
Embed Badge
If you're the author of this project, you can embed a live badge anywhere that supports HTML or Markdown. It updates automatically whenever ratings change.
Use HTML for any page that supports it, or Markdown for README files and Markdown-based descriptions.
Identifiers
Platform IDs
About
Description
Let There Be Portal Farms!
A Fabric server-side mod for Minecraft 26.2+ for solving a common farming inconvenience - mobs despawning upon entering a nether portal, if no other players are nearby.
Installation
This mod requires Fabric API!
Drop the mod .jar into your mods folder, and start the server!
Why is this needed?
In vanilla Minecraft, if both a mob and a player exist in a world, and they're at least 128 blocks apart, then that mob despawns. This a completely normal and vanilla feature, but here is where it gets annoying:
Say a despawnable mob enters a nether portal, and there is a player in the target dimension, nowhere close to that mob? The mob immediately despawns.
This is what breaks most portal-based farms on multiplayer servers, making others rely on having a player AFK at the portal on the other side.
What does this mod do?
LTBPF makes select mobs get a period of despawn immunity once they change dimensions.
If a whitelisted entity enters a portal, it gets a grace period in which they cannot despawn.
And once the period passes, their default despawning logic takes over - making them despawnable again.
It also does not touch entities or mobs which were already persistent by some means (tamed, name tagged, etc.), and checks if they were name tagged while in the grace period, to avoid taking away their persistence.
Configuration
On first run, a config file is generated at config/portal-fix-config.json
This includes the entity whitelist, which entities get despawn immunity:
...
"minecraft:creeper",
"minecraft:spider",
"minecraft:zombified_piglin",
"minecraft:guardian",
"#minecraft:burn_in_daylight",
...and so on
I put in most farmable mobs I could think of, but if the default configuration doesn't suit you, then you can change it.
And an option called persistenceDurationSeconds for setting the length of the grace period in seconds. (default 60)
Commands / Permissions
/portalfix reload - reloads the configuration file
requires the portalfix.reload permission or Operator privileges.
Extra
I am no programming expert, and neither do I have much experience in it.
I'm just a server owner who didn't find any mod to suit my needs, and decided to take matters in my own hands.
This mod was intended to be used only on my server, but I realised that other server owners might be having the same issue, so I publish it both here and on GitHub.
I will admit that I used Claude AI for most of the syntax writing this, because I'm new to Java.
However, I don't blindly trust it - no line was left unexplained and no logic was left overlooked.
Screenshots
Gallery
Versions
Files
Relations
Project Relations
More like this
Similar Mods
Suggestions use data such as tags, dependencies, dependents, descriptions, titles, and more to rank how much they overlap with this mod.
On ModDex
Community snapshot
By the numbers
Statistics
Want to reach Minecraft players?
We're looking for a server hosting partner to feature here and other parts of the site. Interested? Send us a message!
Get in touchGet it on
Available Platforms
On ModDex
Community snapshot
By the numbers