Skip to content

MobInteract 1.4.0

Latest

Choose a tag to compare

@nukebean nukebean released this 08 Nov 14:07

中文

1.4.0 是一次「按审计报告大扫除」:修掉 2 个致命、11 个高危,加上一批中低问题的收口。

致命

  • plugin.yml 的 version / api-version 改成字面量。之前依赖 Maven 资源过滤,一旦拿到的 jar 没经过过滤,服务端解析 api-version 会抛 NumberFormatException,插件根本不加载。
  • 怪物挖方块现在会触发 BlockBreakEvent:WorldGuard、CoreProtect、领地插件终于能看见并拦住它。同时掉落改用主手镐子的附魔与等级结算,石头类不再空手零掉落。

高危

  • 追击打列不再永久卡死(被拒列计数有上限,满了自动清空)。
  • 区块卸载、僵尸变形不再丢档案,走远回来不会重新掷骰白送方块。
  • 临时方块的到期队列加锁,跨区域并发不再破坏堆结构。
  • 区块键改成 record,负坐标与超大坐标不再撞 key 导致误删整批方块。
  • 放置的规划与执行都做区域归属校验,跨区域读写不再每 tick 刷堆栈。
  • 写入方块前复核实体占用(规划到落块之间有好几个 tick,世界会变),不再把人埋进墙里。
  • 拾取只认 placement.yml 里 entries 列出的方块:以前连钻石块都捡,15 秒后又被清理,等于静默销毁玩家财产。
  • 版本比较重写:rc10 > rc2、1.0.0-1 < 1.0.0-alpha、+build 忽略、release-1.4.0 能正确解析。
  • 放 TNT / 倒水前检查波及范围内的保护区,不再隔着一格拆家。

中低

  • 背包加锁;/mi inspect 切到怪物所在区域的线程;tab 补全按权限过滤。
  • /mi reload 会重建档案:世界里已经生成的怪也按新配置重新掷出生装备,不用重启服务端。
  • message.yml 改写列表现在真的生效;占位符一次性替换;&A、&R 这类大写颜色码也认。
  • 更新检查:响应体上限 512 KB,同一版本只提醒一次。
  • 配置边界:hard-cap-seconds: 0 = 不设上限;block-lifetime-seconds 负数按 1 秒(0 仍是永久);backpack.chance: 65 按 65% 处理,不再被截成 1.0。

升级提示:直接替换 jar 重启即可。配置文件不会被覆盖;如果你之前把 hard-cap-seconds 写成 0 或把 backpack.chance 写成百分数,行为会在这一版开始符合直觉。


English

1.4.0 is a full pass over an external audit: 2 critical and 11 high-severity issues fixed, plus a batch of medium and low ones.

Critical

  • version / api-version in plugin.yml are now literals. They used to rely on Maven resource filtering; an unfiltered jar made Paper throw NumberFormatException on api-version and refuse to load the plugin.
  • Mining now fires BlockBreakEvent, so WorldGuard / CoreProtect / claim plugins finally see and can block it. Drops are resolved with the mob's actual pickaxe, so stone no longer yields nothing.

High

  • Chases no longer stall forever when too many lanes have been rejected.
  • Chunk unloads and zombie transformations keep the mob profile, so walking away and back no longer re-rolls free blocks.
  • The temporary-block expiry queue is locked; concurrent region access no longer corrupts it.
  • Chunk keys are a record now, so negative or huge coordinates cannot collide and wipe an unrelated batch.
  • Placement planning and execution both verify region ownership; no more stack traces every tick.
  • Entity occupancy is re-checked right before a block is written (several ticks pass between plan and write), so players no longer get walled in.
  • Pickup only accepts blocks listed in placement.yml → entries. Before, a mob would pick up diamond blocks and the 15-second cleanup would destroy them.
  • Version comparison rewritten: rc10 > rc2, 1.0.0-1 < 1.0.0-alpha, +build ignored, release-1.4.0 parsed correctly.
  • TNT and fluids check the protected area within their blast / flow range before being placed.

Medium / low

  • Backpack is synchronized; /mi inspect hops to the mob's region thread; tab completion is permission-gated.
  • /mi reload rebuilds profiles, so mobs already in the world re-roll their equipment with the new settings.
  • List values in message.yml now override the built-in defaults; placeholders are substituted once; &A / &R work.
  • Update checks: 512 KB response cap, one announcement per release.
  • Config edges: hard-cap-seconds: 0 means no cap; negative block-lifetime-seconds becomes 1 (0 still means forever); backpack.chance: 65 is read as 65%.

Upgrading: drop in the jar and restart. Existing configuration files are kept as they are.