promotional bannermobile promotional banner

Player Utils

Four commands to control health, air, PvP, and spawnpoints, with optional conditions and persistence.

Player Utils

A powerful administrative mod for NeoForge 1.21.1 that adds four essential commands for gameplay control.

NeoForge Minecraft License


✨ Features

  • /choke – Force players to suffocate unless specific inventory conditions are met.
    Oxygen depletes rapidly and causes damage when empty. Conditions are optional.
  • /health – Lock a player's health to a fixed value (1–100) until conditions are met.
    Supports optional inventory conditions.
  • /pvp – Disable a player's ability to attack other players.
    Simple on/off toggle.
  • /autosp – Automatically sets your spawnpoint to your death location when you die.
    Click the respawn button to respawn exactly where you died.

All states are persisted in each player's NBT data, surviving server restarts and relogs.


📖 Command Reference

/choke

Subcommand Syntax Description
start /choke start <targets> [slotList] Starts suffocating the target players. If slotList is omitted, the effect is unconditional (always active).
stop /choke stop [targets] Stops the effect. If no targets are given, affects the command sender.

/health

Subcommand Syntax Description
start /health start <target> <health> [slotList] Locks the target's health to the given value (1–100). If slotList is omitted, the lock is unconditional.
stop /health stop [target] Releases the lock and restores max health to 20.

/pvp

Subcommand Syntax Description
start /pvp start <targets> Disables PvP for the targets (they cannot damage other players).
stop /pvp stop [targets] Re-enables PvP.

/autosp

Subcommand Syntax Description
start /autosp start <targets> Enables auto spawnpoint – upon death, the player's spawnpoint is set to the death location.
stop /autosp stop [targets] Disables the feature.

🧩 SlotList Format (for /choke and /health)

The slotList is an optional JSON array that defines conditions on specific inventory slots.
Each entry is an object with the slot name as key and an object of item IDs and required counts.

Slot names:

  • hotbar.0 to hotbar.8 –hotbar
  • inventory.9 to inventory.35 –inventory
  • armor.head, armor.chest, armor.legs, armor.feet –armor
  • offhand –offhand

Item format: "namespace:item" (e.g., "minecraft:diamond").
Count is optional; if omitted, any amount is accepted. Multiple items in one slot act as OR (any of them works).

Example:

[
  {"hotbar.8": {"minecraft:bedrock": 1}},
  {"armor.head": {"create:diving_helmet": 1, "create:netherite_diving_helmet": 1}},
  {"inventory.32": {"minecraft:netherite_block": 32}}
]

This requires:

  • Slot 8 (last hotbar slot) has at least 1 bedrock.
  • Helmet slot has either a diving helmet or a netherite diving helmet.
  • Inventory slot 32 has exactly 32 netherite blocks.

🔒 Permissions

All commands require OP level 2 (default for most server admins).
In singleplayer, enable cheats or use /op in a server environment.


📝 License

This mod is distributed under All Rights Reserved unless otherwise stated in the source code.
You may use it on your server, but redistribution or modification requires explicit permission from the author.


🙏 Acknowledgements

  • NeoForge for the modding framework.
  • All contributors and testers.

📞 Contact

Author: DogOfFurina
Issues & suggestions: GitHub Issues


The Player Utils Team

profile avatar
  • 1
    Projects
  • 9
    Downloads