mirror of
https://github.com/KAMKEEL/CustomNPC-Plus.git
synced 2026-11-20 06:29:41 +00:00
fixed crash when hovering over a trader item slot
HashMap.put doesn't work the way I thought it did
This commit is contained in:
1 parent
8c687e7ef5
commit
17fa6328c9
3 files changed
+10
-12
No files matched your search
@@ -68,12 +68,12 @@ public class ContainerNPCTrader extends ContainerNpcInterface{
|
||||
NoppesUtilPlayer.consumeItem(entityplayer, role.inventoryCurrency.getStackInSlot(i + 18), role.ignoreDamage, role.ignoreNBT);
|
||||
ItemStack soldItem = item.copy();
|
||||
givePlayer(soldItem, entityplayer);
|
||||
role.addPurchase(i, entityplayer);
|
||||
role.addPurchase(i, entityplayer.getDisplayName());
|
||||
return soldItem;
|
||||
|
||||
}
|
||||
public boolean isSlotEnabled(int slot, EntityPlayer player) {
|
||||
return role.isSlotEnabled(slot, player);
|
||||
return role.isSlotEnabled(slot, player.getDisplayName());
|
||||
}
|
||||
public boolean canBuy(int slot, EntityPlayer player) {
|
||||
ItemStack currency = role.inventoryCurrency.getStackInSlot(slot);
|
||||
|
||||
Reference in new issue
Block a user