mirror of
https://github.com/songoda/UltimateRepairing.git
synced 2024-11-29 14:06:30 +01:00
Can't use MainHand if we want to support 1.8.
This commit is contained in:
parent
3920bd2e31
commit
fae3b80488
@ -55,8 +55,8 @@ public class RepairHandler {
|
||||
|
||||
EntityEquipment equipment = player.getEquipment();
|
||||
if (equipment != null) {
|
||||
if (equipment.getItemInMainHand().equals(itemStack)) {
|
||||
equipment.setItemInMainHand(null);
|
||||
if (equipment.getItemInHand().equals(itemStack)) {
|
||||
equipment.setItemInHand(null);
|
||||
playerData.setSlot(EquipmentSlot.HAND);
|
||||
} else if (itemStack.equals(equipment.getHelmet())) {
|
||||
equipment.setHelmet(null);
|
||||
@ -242,7 +242,7 @@ public class RepairHandler {
|
||||
ItemStack item = playerData.getToBeRepaired();
|
||||
switch (slot) {
|
||||
case HAND:
|
||||
equipment.setItemInMainHand(item);
|
||||
equipment.setItemInHand(item);
|
||||
break;
|
||||
case OFF_HAND:
|
||||
equipment.setItemInOffHand(item);
|
||||
|
Loading…
Reference in New Issue
Block a user