Code:public boolean checkEmpty() { if(getItems().freeSlots() == 28) { for(int i = 0; i < playerEquipment.length; i++) { if(playerEquipment[i] != -1) { return false; } } return true; } else { return false; } }
Use:
Code:if(!c.checkEmpty) { c.sendMessage("You can't bring items into Demon Minigame."); } else { c.getPA().movePlayer(2341, 3656, 0); c.sendMessage("@blu@You enter the minigame."); }