Skip to content

Commit

Permalink
Fix build.
Browse files Browse the repository at this point in the history
Signed-off-by: 秋雨落 <[email protected]>
  • Loading branch information
qyl27 committed Nov 8, 2024
1 parent 5ba275c commit 67d2744
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -157,13 +157,10 @@ protected boolean shouldDropExperience() {
}

@Override
public void onEquipItem(net.minecraft.world.entity.EquipmentSlot slotIn, ItemStack stack, boolean silent) {
switch (slotIn.getType()) {
case HAND ->
this.bridge$playEquipSound(slotIn, this.handItems.set(slotIn.getIndex(), stack), stack, silent);
case HUMANOID_ARMOR ->
this.bridge$playEquipSound(slotIn, this.armorItems.set(slotIn.getIndex(), stack), stack, silent);
public void setItemSlot(net.minecraft.world.entity.EquipmentSlot slot, ItemStack stack, boolean silent) {
switch (slot.getType()) {
case HAND -> this.bridge$playEquipSound(slot, this.handItems.set(slot.getIndex(), stack), stack, silent);
case HUMANOID_ARMOR -> this.bridge$playEquipSound(slot, this.armorItems.set(slot.getIndex(), stack), stack, silent);
}

}
}
Original file line number Diff line number Diff line change
Expand Up @@ -430,7 +430,7 @@ public CraftHumanEntity getBukkitEntity() {
}

@Override
public void onEquipItem(EquipmentSlot slot, ItemStack stack, boolean silent) {
public void setItemSlot(EquipmentSlot slot, ItemStack stack, boolean silent) {
this.verifyEquippedItem(stack);
if (slot == EquipmentSlot.MAINHAND) {
this.equipEventAndSound(slot, this.inventory.items.set(this.inventory.selected, stack), stack, silent);
Expand Down

0 comments on commit 67d2744

Please sign in to comment.