return true;
}
private boolean doBowString(Player player, final InvItem bowString,
final InvItem bow) {
final ItemBowStringDef stringDef = EntityHandler
.getItemBowStringDef(bow.id);
if (!Config.members) {
player.getActionSender().sendMessage(
"This feature is not avaliable in f2p");
return true;
}
if (stringDef == null) {
return false;
}
if (player.getCurStat(9) < stringDef.getReqLevel()) {
player.getActionSender().sendMessage(
"You need a fletching level of " + stringDef.getReqLevel()
+ " to do that.");
return true;
}
Instance.getDelayedEventHandler().add(new MiniEvent(player) {
public void action() {
if (owner.getInventory().remove(bowString.id, bowString.amount,
false)
&& owner.getInventory().remove(bow.id, bow.amount,
false)) {
owner.getActionSender().sendMessage(
"You add the bow string to the bow");
owner.getInventory().add(stringDef.getBowID(), 1, false);
owner.incExp(9, stringDef.getExp(), true);
owner.getActionSender().sendStat(9);
owner.getActionSender().sendInventory();
}
}
});