📦 ShulkerKing — открывай шалкер-боксы прямо из руки

Плагин 📦 ShulkerKing — открывай шалкер-боксы прямо из руки 2.0.6

Создайте и подтвердите аккаунт для скачивания
2.0.6 — Critical dupe fix

This update fixes the duplication reported in reviews: a shulker box held in the off hand could be placed endlessly.

Critical fixes
  • Off-hand dupe — placement always consumed the item from the main hand, so the off-hand shulker was never removed. The item is now taken from the hand that was actually used.
  • Double placement — the plugin placed the block manually but did not cancel the interaction, so vanilla placed a second block and consumed a second item. Fixed.
  • Plugin did not load — config.yml was missing from the jar, saveDefaultConfig() threw in onLoad and the plugin never enabled.
  • Permissions not registered — shulkerking.place and cooldown.vip/premium/bypass were nested under "commands" and were OP-only.
  • Region protection bypass — placement now fires BlockPlaceEvent, so WorldGuard / GriefPrevention / Towny work again.

Anti-dupe model reworked
  • On open, the contents move into the session; the item in hand is emptied and tagged with a session id (PDC). While the GUI is open, only one copy of the contents exists.
  • Sessions are persisted in sessions.yml and restored on join after a crash or a quit with the GUI open — no item loss, no dupe.
  • Item identity is checked by session id instead of "same type and name".

Added
  • API events: ShulkerOpenEvent (cancellable), ShulkerCloseEvent, ShulkerPlaceEvent (cancellable).
  • Localized GUI title and cooldown display; all missing locale keys added (no more "Message not found" in chat).
  • Regression tests: tests/dup-regression (4 tests, MockBukkit).

Changed
  • Combat tag is set only for PvP (player or player's projectile), not for any damage.
  • Hopper guard checks the real GUI holder instead of "any 27-slot inventory".
  • Debug logging is off by default; added /shulkerking info and /shulkerking debug.
  • Config keys documented: pvp-block.enabled, cooldown.default, item-blacklist.items/mode (old names still supported).

Verified
  • Maven build succeeds (Java 8 target, API 1.16+).
  • Loaded and enabled on Paper 1.21 / Java 21 with no exceptions.
  • Tests: 4/4 passing.

Upgrade notes
  • Delete the old jar and put the new one into /plugins.
  • config.yml is recreated with all keys; existing values are kept.
  • /shulkerking reload works without a restart.

Source: You must be logged in to see this link.
Исправлен дюп.
Исправлен Кулдаун.
Исправлена работа с файлом config.yml
Исправлены мелкие недочеты плагина, обновлен полностью.
Баг полностью исправлен - предметы теперь корректно сохраняются при размещении шалкер-боксов через Shift+ПКМ.
Неуправляемые BukkitRunnable задачи создавали утечки памяти
Создание новых задач планировщика при каждом клике в инвентаре
Неэффективная проверка типа материала через строковые операции
Повторное чтение файла конфигурации при каждом событии
Добавили вызов stopAllCountdowns() в методе onDisable()
Визуальный кулдаун — отображение таймера прямо на предмете, обновление в реальном времени.
Размещение шалкеров — Shift+ПКМ для установки на землю.
✅ Уведомления готовности — сообщение «✓ Готов к открытию!» после кулдауна.
Назад
Сверху Снизу