Item Drain Potion Blacklist

「Ban without bounds, manage with order」

Youer can restrict the Item Drain from Create (mechanical power) so that banned potions cannot be emptied/cleared through it. This prevents using the Item Drain to duplicate or recycle specific potions.

Manage the blacklist with the /create_item_drain command, which works the same way as /bans (add | show).


Prerequisites

ConditionDescription
Create mod installedRequired. If not installed, the command is not registered and this feature is disabled
Permission nodeyouer.command.create_item_drain

The command is named create_item_drain instead of create to avoid conflicting with Create mod's own create command.


Quick Start

Ban a potion in two steps:

Method 1: Ban directly by ID

bash

Method 2: Place into GUI

bash

Open your inventory, place the potion you want to ban, and close the GUI to save automatically.

View the current blacklist:

bash

Right-click an entry in the GUI to remove it.


Commands

CommandDescription
/create_item_drain potionban addOpen a GUI; place potions then close to add them to the blacklist (multiple potions at once, auto-dedup)
/create_item_drain potionban add <potion ID>Ban a potion directly by ID
/create_item_drain potionban showOpen a GUI to view the blacklist; right-click an entry to remove it

The command can only be executed by a player; the console cannot use it (same as /bans).

Potion ID Format

Potion IDs use the registry-key format, for example:

PotionID
Swiftness II (8:00)minecraft:long_swiftness
Healing IIminecraft:strong_healing
Invisibility (3:00)minecraft:invisibility

After typing add, the ID argument supports Tab autocompletion, which lists all potions registered on the server, so you never have to memorize IDs.


Usage

bash
  1. Open an inventory GUI;
  2. Place the potion you want to ban (potion, splash potion, or lingering potion) into a slot;
  3. Close the GUI to save automatically; the chat shows how many were added this time.

Notes:

  • Multiple different potions can be placed at once;
  • Potions already on the blacklist are skipped automatically (no duplicates);
  • Non-potion items are ignored.

Method 2: Add directly by ID

bash

Common responses:

MessageMeaning
Successfully banned potion: %sAdded to the blacklist
Invalid potion ID: %sWrong ID format (not namespace:path)
Potion %s does not existID is valid but the server has no such potion
Potion %s is already bannedAlready on the blacklist (duplicate)

View and Remove

bash

Open the GUI to view all currently banned potions (shown as their potion icons). Right-click an entry to remove it from the blacklist; the GUI refreshes automatically.


Config File

The blacklist is stored in youer-config/item-drain-potionban.yml:

yaml
  • Changes take effect immediately, no server restart needed (command operations write to this file);
  • Managing via commands is recommended to avoid formatting mistakes.

How It Works

The blacklist uses a Mixin to hook into Create's GenericItemEmptying.canItemBeEmptied:

  • The check is based on the item's potion registry key, so potions, splash potions, and lingering potions all match the blacklist;
  • Banned potions cannot be emptied in the Item Drain (canItemBeEmptied returns false);
  • Other uses are unaffected: potions can still be drunk or thrown; only Item Drain emptying is restricted.

FAQ

I don't have the Create mod installed. Can I use this command?

No. The command is only registered when Create is detected; without it, the command appears not to exist.

After banning, can players still drink the potion?

Yes. The blacklist only restricts Item Drain emptying; drinking, throwing, and other normal uses are unaffected.

How do I find valid potion IDs?

Type /create_item_drain potionban add and press Tab; it lists all potions registered on the server.

Can the console run this command?

No, the command is players-only (it relies on a player-opened GUI).

Do I need to restart after editing the config file?

No, changes take effect immediately. But editing via the command is recommended to avoid formatting mistakes.

© 2019-2026 MohistMCUnofficial Minecraft product. Not approved by or associated with Mojang or Microsoft.