onArmorUpdate

装备栏检测

判断条件: 装备此物时 检测时间: 每Tick

函数效果:当你穿上这件装备时可使用 itemstack || player || world 类方法

itemstack.damageItem(-1)
//损耗耐久 (此处-1为修复)
player.addPotionEffect("moveSpeed", 2400, 0)
//给予玩家 速度 2:00 I

最后更新于

这有帮助吗?