if(item == null)
{
continue;
}
L2Item template = ItemTable.getInstance().getTemplate(item.getItemId());
if(template == null)
{
continue;
}
boolean found = false;
for(TradeItem ti : _items){
if(ti.getObjectId() == item.getObjectId()){
found = true;
if(ti.getPrice() != item.getPrice()){
return false;
}
}
}
//store is not selling that item...
if(!found){
String msg = "Requested Item is not available to buy... You are perfoming illegal operation, it has been segnalated";
_log.warning("ATTENTION: Player "+player.getName()+" has performed buy illegal operation..");
player.sendMessage(msg);
msg = null;
return false;
}
weight += item.getCount() * template.getWeight();
if(!template.isStackable())
{
slots += item.getCount();
}
else if(player.getInventory().getItemByItemId(item.getItemId()) == null)
{