HomeJavaModsSelective Peaceful Mobs
Selective Peaceful Mobs
ModsJava

Selective Peaceful Mobs

by voidanomaly · on Modrinth

Let every player choose how hostile mobs treat them, without changing the experience for everyone else on the server.

⬇ Download on Modrinth

Let every player choose how hostile mobs treat them—without changing the experience for everyone else on the server.

Selective Peaceful Mobs is a configurable NeoForge mod for Minecraft 1.21.1. Players with peaceful mobs enabled are ignored by hostile mobs until they attack. Other players can leave the feature off and continue playing with normal vanilla hostility at the same time.

Features

How it works

Player setting Result
Peaceful ON Hostile mobs ignore the player unless that player provokes them.
Peaceful OFF Hostile mobs behave normally toward the player.
No saved choice The server's configured default is used.

When a protected player attacks a hostile mob, that mob can target the player for the configured provocation time. If group aggro is enabled, nearby mobs of the same type can retaliate too. Once provocation expires, the mobs return to ignoring that player.

The Ender Dragon, Warden, and Wither are always hostile by default. Server owners can change this list.

Player commands

/peacefulmobs on
/peacefulmobs off
/peacefulmobs status
/peacefulmobs reset

Operator commands

These commands require vanilla permission level 2 or higher:

/peacefulmobs set <player> <true|false>
/peacefulmobs check <player>
/peacefulmobs reset <player>

Configuration

The generated configuration file is:

config/selective-peaceful-mobs-server.toml

Server owners can configure:

Default values:

[general]
defaultPeaceful = true
rememberPlayerChoice = true
provokedTimeSeconds = 30
groupAggro = true
groupAggroRadius = 16
ignoreCreativeAndSpectator = true

[alwayshostilemobs]
mobs = ["minecraft:ender_dragon", "minecraft:warden", "minecraft:wither"]

Frequently asked questions

Does this change the world's difficulty or stop hostile mobs from spawning?

No. It changes which players hostile mobs are allowed to target; it does not change the difficulty or spawning rules.

Can peaceful and non-peaceful players play together?

Yes. The setting is evaluated per player, so a mob can ignore one player and target another.

Can peaceful players still fight mobs?

Yes. Attacking a hostile mob temporarily provokes it, preserving risk and retaliation.

Can operators force a setting for another player?

Yes. Operators can set, inspect, or reset another player's choice with the admin commands above.

Does it work with modded mobs?

It should work automatically with most modded mobs that use Minecraft's normal hostile classifications and targeting systems. Mobs with fully custom attack logic may require compatibility work.

Quick facts

Install steps are the general flow for this file type — How to install Minecraft Java mods & modpacks walks through it step by step.

Verified by MCModsHub

These come from our own check of the pack file, not from the source page.

Explore more