You are viewing a potentially older version of this package. View all versions.
Yatsuta-DecorativePet-1.2.2 icon

DecorativePet

Spawn a named, immortal, passive vanilla creature that follows its owner.

By Yatsuta
Date uploaded 2 months ago
Version 1.2.2
Download link Yatsuta-DecorativePet-1.2.2.zip
Downloads 56
Dependency string Yatsuta-DecorativePet-1.2.2

This mod requires the following mods to function

denikson-BepInExPack_Valheim-5.4.2350 icon
denikson-BepInExPack_Valheim

BepInEx pack for Valheim. Preconfigured with the correct entry point for mods and preferred defaults for the community.

Preferred version: 5.4.2350

README

Decorative Pet

Decorative Pet adds lightweight, multiplayer-friendly companion animals to Valheim. Spawn a named vanilla creature, make it passive and invulnerable, and let it follow you around as a purely decorative companion.

The mod uses Valheim's existing creature prefabs. No custom models, textures, or asset bundles are required.

Features

  • Spawn a named vanilla creature near the player who issued the command.
  • Pets are passive, immortal, and do not attack.
  • Follow and stay modes.
  • Rename your own pets at any time.
  • Automatic teleport when a pet gets too far away.
  • Works in multiplayer: the host creates the networked pet, and every player can see it.
  • Each player can control only their own pets.

Installation

Install DecorativePet through Thunderstore Mod Manager and launch Valheim with Start modded.

For multiplayer, install the same version for the host and all players. The host must have the mod because the host creates and moves the networked pets. Installing it for everyone ensures that names, passive behavior, commands, and follow/stay mode work consistently.

Chat commands

Press Enter to open the Valheim chat and enter one of these commands:

/pet help
/pet spawn [Prefab] [Name]
/pet name <New name>
/pet follow
/pet stay
/pet list
/pet remove

Examples:

/pet spawn Wolf Rex
/pet spawn Lox Big Bublik
/pet name My Companion
/pet stay
/pet follow

If no prefab or name is supplied, the configured defaults are used:

/pet spawn

The same command can also be entered in the F5 console without the leading /.

Available creature prefabs

Prefab Creature Notes
Wolf Wolf Recommended default
Boar Boar
Lox Lox
Chicken Chicken
Deer Deer
Hare Hare
Neck Neck
Serpent Serpent Best spawned in water
Fish1 Fish Water only
Fish2 Fish Water only
Fish3 Fish Water only
Fish4 Fish Water only

Prefab names are case-sensitive. If a prefab is unavailable in your Valheim version, the command will return an error.

Multiplayer behavior

  1. A player enters a /pet command in chat.
  2. The request is sent to the world host through Valheim's normal network chat RPC.
  3. The host creates a networked vanilla creature near the requesting player.
  4. All connected players can see the pet, its name, and its movement.

Pet commands affect only the pets owned by the player who entered the command. For example, /pet remove removes your pets, not somebody else's.

Following and teleporting

Pets follow their owner while follow mode is enabled. If the distance becomes greater than 15 metres, the server automatically teleports the pet close to its owner.

The teleport distance can be changed in:

BepInEx/config/ua.bohdan.decorativepet.cfg

Edit the TeleportDistance value and restart the game or reload the profile.

Removing a pet

Use this command in chat:

/pet remove

This removes all decorative pets owned by the player who entered the command. It is recommended to remove your pets before uninstalling the mod.

Support

If a command does not work, make sure:

  • the host and players are running the same mod version;
  • the game was launched through Thunderstore Mod Manager;
  • the host is present in the world;
  • the prefab name is spelled correctly.

CHANGELOG

1.5.0

  • Added a compact on-screen pet panel with hunger and aggression status.
  • The panel appears only while aiming at a decorative pet.

1.4.4

  • Fixed inverted aggression behavior by saving and restoring every MonsterAI attack flag.
  • /pet ignore now disables attacks against creatures as well as players.
  • /pet attack restores the prefab's original aggression settings.

1.4.3

  • Added attack-method guards to stop retaliation after a pet is hit.
  • Removed the broken pseudo-graphic hunger bar from hover text.
  • Kept only a compact localized mode line above the pet.

1.4.2

  • Kept MonsterAI enabled in ignore mode so pets can approach dropped food and eat.
  • Added a fallback hunger bar based on Valheim's hungry status when the food-level API is unavailable.
  • Preserved compact hover text.

1.4.1

  • Ignore mode now disables the pet's MonsterAI to prevent retaliation after repeated hits.
  • /pet attack re-enables MonsterAI and restores the original attacks.
  • Reduced hover UI to a single localized mode line.

1.4.0

  • Ignore mode now replaces the complete attack container, including array-based Valheim builds.
  • Reduced hover text to a compact food/mode line.

1.3.9

  • Ignore mode now removes all configured MonsterAI attacks and restores them with /pet attack.
  • Added Ukrainian/English labels based on the selected Valheim language.

1.3.8

  • Restored the requested face icon and resized it to exactly 256×256.

1.3.7

  • Fixed a null Harmony target that aborted the entire mod during startup.
  • All later pet features now initialize even on Valheim builds without BaseAI.DoAttack.

1.3.6

  • Resized the package icon to the required exact 256×256 dimensions.

1.3.5

  • Blocked Fish prefab pickup methods (Pick, Pickup, and Take), not just Interact.
  • Added fish hover-name hooks for ItemDrop/Pickable implementations.

1.3.4

  • Added dedicated Fish/Pickable/ItemDrop hooks so decorative fish cannot be picked up.
  • Added a decorative name and aggression action to fish hover text.

1.3.3

  • Ignore mode now blocks target acquisition and retaliation after the pet is hit.
  • Added a direct empty-hand interaction toggle on the owner’s pet.
  • Added hunger/aggression information to Character hover-name rendering.

1.3.2

  • Replaced the package icon with the requested Decorative Pet icon.

1.3.1

  • Fixed pet commands when Valheim formats the chat sender name differently.
  • Ignore mode now clears creature targets continuously, including skeletons and wildlife.
  • Applied the hunger/aggression hover text to every compatible Valheim hover-text overload.

1.3.0

  • Added the required icon.png package icon.
  • Cached reflected game types to reduce the one-time hitch when spawning a pet.

1.2.9

  • Fixed repeated transform errors after a pet or player object disappears.
  • Prevented the teleport tick from touching destroyed Unity objects, removing the related FPS drops.

1.2.8

  • Blocked picking up decorative fish and other marked Pickable/ItemDrop pets.
  • Normal world drops and unmarked creatures are unaffected.

1.2.7

  • Added an empty-hand hover interaction to toggle Ignore enemies for your pet.
  • Added /pet ignore and /pet attack commands.
  • Added a hunger bar to the pet hover text; normal Valheim feeding remains available.
  • Kept native MonsterAI movement and animations while preventing attacks in ignore mode.
  • Removed the code path that disabled creature food consumption.

1.2.6

  • Replaced manual transform movement with Valheim's native MonsterAI following.
  • Restored normal walking and running animations.
  • Removed reflection-heavy movement updates that caused severe FPS loss.
  • Improved tame-state and custom-name synchronization.

1.2.5

  • Fixed vanilla prefab lookup on current Valheim builds.
  • Replaced manual ZDO creation with normal network-prefab instantiation.
  • Removed all idle polling when no pets exist and removed global ZNetView hooks.
  • Pets are now session-based and disappear when the host world session ends.

1.2.4

  • Fixed compatibility with Valheim builds where singleton instances are exposed as properties instead of fields.
  • Fixed /pet spawn and server detection on those builds.
  • Removed repeated Harmony reflection warnings that could cause log spam and stuttering.

1.2.3

  • Removed the periodic full-world scan that caused a freeze every two seconds.
  • Pets are now tracked when their network objects are created and removed.
  • Player lookup no longer scans every loaded network object.

1.2.2

  • Fixed a severe FPS drop caused by scanning all loaded network objects every frame.
  • Added a lightweight pet cache and throttled command-registration retries.
  • Improved follow movement timing.

1.2.1

  • Reworked the Thunderstore documentation with installation, commands, supported creatures, multiplayer behavior, and configuration details.

1.2.0

  • Added automatic teleport to the owner when the pet is more than 15 metres away.
  • Added configurable TeleportDistance.

1.1.0

  • Added chat commands that can be sent by any player.
  • The server creates the pet near the player who sent the command.
  • Follow movement is authoritative on the server for remote owners.

1.0.0

  • Initial release.