예제 #1
0
 public ItemStack[] getContentsofSlot4() throws NoBagException {
   NPCBag pb = new NPCBag(player, 4);
   if (pb.getType() == 0) {
     throw new NoBagException();
   }
   return pb.getInventory();
 }
예제 #2
0
 public void setContentsofSlot4(ItemStack[] items) throws NoBagException {
   NPCBag pb = new NPCBag(player, 4);
   if (pb.getType() == 0) {
     throw new NoBagException();
   }
   pb.setInventory(items);
 }
예제 #3
0
 public boolean isSlot4Equipped() {
   NPCBag pb = new NPCBag(player, 4);
   if (pb.getType() == 0) {
     return true;
   }
   return false;
 }
예제 #4
0
 public boolean isSlot2Large() throws NoBagException {
   NPCBag pb = new NPCBag(player, 2);
   int type = pb.getType();
   if (type == 0) {
     throw new NoBagException();
   }
   if (type == 2) {
     return true;
   } else {
     return false;
   }
 }