You are viewing a potentially older version of this package. View all versions.
Hardwire99-Offspring_Portal-0.2.14 icon

Offspring Portal

Teleports tamed juveniles from breeder portals to maturing pens. Optional adult routing to farm or cull. Press E on juveniles to toggle follow/stay.

Date uploaded a week ago
Version 0.2.14
Download link Hardwire99-Offspring_Portal-0.2.14.zip
Downloads 69
Dependency string Hardwire99-Offspring_Portal-0.2.14

This mod requires the following mods to function

denikson-BepInExPack_Valheim-5.4.2202 icon
denikson-BepInExPack_Valheim

BepInEx pack for Valheim. Preconfigured and includes unstripped Unity DLLs.

Preferred version: 5.4.2202
ValheimModding-Jotunn-2.26.0 icon
ValheimModding-Jotunn

Jötunn (/ˈjɔːtʊn/, 'giant'), the Valheim Library was created with the goal of making the lives of mod developers easier. It enables you to create mods for Valheim using an abstracted API so you can focus on the actual content creation.

Preferred version: 2.26.0

README

Offspring Portal

Automate your breeding pens. Offspring Portal teleports tamed juveniles from your breeder area to distant maturing pens the moment they wander into range — keeping vanilla population caps from stalling production.

Press E on juveniles to toggle follow/stay — useful for leading piglets and wolf cubs through portals or into pens before they grow up.

Build a portal, name it, configure it once, and let the mod handle the logistics.

Offspring portals are for animal automation only — players cannot travel through them. Compatible with XPortal (offspring portals are excluded from XPortal's travel list).


Support & feedback

Bug reports, feature requests, and questions:

GitHub — Offspring Portal

When reporting a problem, include your mod version, single-player or multiplayer, and other portal-related mods (e.g. XPortal).


At a glance

Portal type What it does
Breeder Sends juveniles out to matching maturing pens
Maturing Receives juveniles; optionally forwards grown adults
Farm Receives adults routed back from maturing pens (by species)
Cull One shared yard — receives adults marked for slaughter

Juvenile follow: With EnableFollowCommand on (default), look at a tamed juvenile and press E to toggle Follow / Stay. Works on boar piglets, wolf cubs, and other juveniles still growing up.

Minimum setup: 2 portals (Breeder + Maturing). Farm and Cull are optional when you want adult automation.

Build cost: 20 Fine Wood · 10 Greydwarf Eyes · 2 Surtling Cores


Juvenile follow command

When a juvenile is still growing (has not reached its adult form), you can command it directly:

  1. Aim at the tamed juvenile — hover shows Follow or Stay
  2. Press E to toggle
  3. Press E again to make it stay

This is separate from portal automation: follow helps you move juveniles; portals teleport them when they enter a breeder's scan radius.

Toggle in config: EnableFollowCommand in BepInEx/config/offspringportal.mod.cfg (default: true).


How juveniles move

Breeder Portal                    Maturing Portal
  (at breeding pen)    ────────►   (at grow-up pen)
  Role: Breeder                   Receives: Boar / Wolf / Hen / All …
  1. Place a portal at your breeding area → configure as Breeder
  2. Place a portal at your grow-up area → configure as Maturing → set Receives to a species (or All)
  3. When a tamed juvenile enters the breeder portal's scan radius, it teleports to the next available maturing pen for its species (round-robin if you have several)

Hover any portal to see its Name, role, and warnings.


Maturing pen destinations (adults)

Each Maturing portal has one Receives species (or All) and one Destination for adults that grow up on that portal. The mod applies that destination to every adult of the species that portal receives.

When juveniles grow up, the maturing portal can optionally move adults elsewhere:

Destination Behavior
None Adults stay on the maturing pen (default — great for a simple 2-portal setup)
Farm Adults teleport to a Farm portal matching their species (or All)
Cull Adults teleport to your Cull yard — one Cull portal serves every species

If Destination is Farm or Cull but no receiver portal exists yet, you'll see a yellow hover warning and adults won't teleport until you place one.

Mixed species, different outcomes: Use one Maturing portal per species when adults need different destinations (e.g. boars → Cull, wolves → None). Place them in the same building if you like — the Breeder sends each juvenile to the Maturing portal whose Receives matches that species. You do not hand-sort animals; the portal network routes them.


Example setups

Starter — 2 portals (juveniles only)

Perfect first build. No adult routing needed.

Portal Type Receives Destination Name example
Breeding area Breeder Boar Farm
Grow-up pen Maturing Boar None Boar Maturing

Juveniles leave the breeder automatically. Adults stay on the maturing pen until you handle them.


Boar production + cull automation

Cull grown boars without walking them across the map.

Portal Type Receives Destination Name example
Breeding pen Breeder Boar Farm
Grow-up pen Maturing Boar Cull Boar Maturing
Slaughter area Cull Boar Cull Yard

One Cull portal is enough for every species you mark for culling.


Cull boars, keep wolves on-site

Mixed species with different adult outcomes. Use one Maturing portal per species — each portal sorts its own juveniles and adults. Both maturing portals can sit in the same grow-up pen; only the portal Receives / Destination settings differ.

Portal Type Receives Destination Name example
Main breeder Breeder Mixed Farm
Grow-up pen Maturing Boar Cull Boar Maturing
Grow-up pen Maturing Wolf None Wolf Maturing
Cull yard Cull Cull Yard

How routing works:

  • The Breeder sends boar juveniles to the Boar maturing portal and wolf juveniles to the Wolf maturing portal automatically.
  • When boars grow up on the Boar maturing portal, they teleport to the Cull yard.
  • When wolves grow up on the Wolf maturing portal, they stay (Destination: None).
  • You only need one Cull portal for every species you mark for culling.

Return adults to the farm

Send grown animals back to holding pens near your breeder.

Portal Type Receives Destination Name example
Breeder Breeder Boar Farm
Distant grow-up Maturing Boar Farm Boar Maturing
Farm holding Farm Boar Boar Holding

Place the Farm portal where you want adults to land. Match Receives to the species on the maturing pen.


Multiple maturing pens (round-robin)

Two boar maturing pens? Juveniles alternate between them automatically.

Portal Type Receives
Breeder Breeder
North pen Maturing Boar
South pen Maturing Boar

Same species + same role = round-robin. Works for Farm and Cull routing too when you have multiple receivers.


Config UI (press E on a portal)

Field Breeder Maturing Farm Cull
Name
Type
Receives All juveniles (fixed) All adults (fixed)
Destination None / Farm / Cull

Species in Receives: Boar · Wolf · Lox · Hen · Asksvin · All


Config file

After first launch, edit:

BepInEx/config/offspringportal.mod.cfg

Setting Default Description
BreederScanRange 10 Scan radius (meters) around portals
BreederScanIntervalSec 0.5 How often breeders scan for juveniles
MaturingAdultScanIntervalSec 30 How often maturing pens scan for adults to forward
TeleportCooldownSec 2 Per-animal cooldown after teleport
DistantTeleportTimeoutSec 15 Wait for distant zones to load before giving up
AllowRetransport false Allow the same animal to teleport again
EnableCapWarning true Warn when a maturing pen is inside breeding cap radius
EnableFollowCommand true Press E on tamed juveniles to toggle follow/stay

Restart Valheim after changing config values.


Multiplayer

Install on server/host and every client. Everyone needs the mod to see the custom portal piece, open the config UI, and get correct hover text. BepInEx and Jotunn are required on all sides.

Teleport logic runs on the server/host.


Requirements

Installed automatically with most mod managers:

Manual install

  1. Install BepInEx and Jotunn.
  2. Place OffspringPortal.dll in BepInEx/plugins/.
  3. Launch once to generate the config file.

Tips

  • Name your portals — hover text shows custom names (Boar Farm, Wolf Maturing, etc.)
  • Press E on juveniles to toggle follow/stay when moving them into range of a breeder portal
  • Destination: None is the safe default until you're ready for Farm or Cull automation
  • One Cull portal can serve your entire world — boars, wolves, lox, etc.
  • One Maturing portal = one species rule — for mixed keep/cull setups, add a Maturing portal per species (they can share one pen)
  • Maturing pens too close to a breeder trigger a cap radius warning — keep grow-up pens outside the vanilla breeding cap range when possible
  • Players cannot travel through offspring portals — juveniles only. Offspring portals are excluded from XPortal's travel list when XPortal is installed.

Source code

Public repository: github.com/cdjensen99-sudo/Offspring_Portal


Credits

By HW

CHANGELOG

Changelog

0.2.15

  • Thunderstore README and wiki: Team Extreme Discord link, feature list, and support section updates

0.2.14

  • Fixed offspring portals reappearing in XPortal as "(No Name)" entries (stronger XPortal list filtering and purge on world load)
  • README and wiki: Discord community section, feature list, and troubleshooting updates

0.2.13

  • Fixed juvenile follow/stay command not working for players who joined a hosted game (routes follow toggle through server RPC)

0.2.12

  • Fixed startup Harmony error: removed invalid ZNetView.Start patch (Valheim's ZNetView has no Start method)

0.2.11

  • Fixed offspring portals placed by remote players in hosted games not routing juveniles until rebuilt
  • Fixed portals spawned via Prefabhammer (or other tools that skip standard placement) not initializing scanners or registry entries

0.2.10

  • Thunderstore README: GitHub Issues link for support, player-travel note, source repo link

0.2.9

  • Block player travel to and from offspring portals (fixes XPortal bounce-back)
  • Exclude offspring portals from XPortal's portal list when XPortal is installed

0.2.8

  • Fixed follow on wolf cubs and other AnimalAI juveniles (no Tameable/MonsterAI — uses custom follow path)
  • Juvenile crosshair detection no longer requires Tameable component

0.2.7

  • Fixed follow command not firing in pens: scan full crosshair raycast for juveniles and set hover target before E is processed
  • Apply follow directly on server/host instead of relying on misrouted client RPC

0.2.6

  • Fixed juvenile follow command: use vanilla follow/stay, correct hover targeting in pens, and show follow hint on crosshair

0.2.5

  • Fixed juvenile follow command for MonsterAI species (Boar, Wolf, Lox, Asksvin)

0.2.4

  • Fixed portal hover still showing XPortal text — use Postfix after all mods and stronger offspring portal detection

0.2.3

  • Fixed portal hover text overridden by XPortal (and similar mods) — Offspring Portal hover now wins

0.2.2

  • Hover warning on maturing portals when Destination is Farm/Cull but no receiver portal exists

0.2.1

  • Maturing portals: Destination dropdown (None / Farm / Cull) replaces forward-adults checkbox
  • None disables adult teleporting; missing Farm/Cull portal shows a warning and skips routing
  • Added Farm receiver portal type for species-separated adult routing
  • Cull yard is shared across all species; Hen label in UI

0.2.0

  • Added three portal types: Breeder, Maturing, and Cull
  • Maturing portals can optionally forward adults to cull pens (checkbox in config UI)
  • Adult scan runs every 30 seconds on maturing portals with forwarding enabled (configurable)
  • Existing pen portals migrate automatically to Maturing type

0.1.18

  • Reduced portal build cost to 20 Fine Wood, 10 Greydwarf Eyes, and 2 Surtling Cores

0.1.17

  • Added custom portal Name field to the config UI
  • Hover text now shows Name plus Role (breeder) or Accepts (pen)
  • Renamed Destination dropdown label to Accepts; breeders show "All juveniles"

0.1.16

  • Fixed config panel OK/Cancel buttons overlapping the Destination dropdown
  • Fixed player warning message stuck on screen while standing in portal range

0.1.15

  • Fixed juvenile floating after teleport
  • Fixed follow command RPC for AnimalAI juveniles (follow deferred for polish)
  • Ground snap for teleported juveniles

0.1.0

  • Initial release: breeder/pen portals, species config UI, distant teleport, cap warnings