| 
						
						
							
								
							
						
						
					 | 
					 | 
					@ -1577,22 +1577,21 @@ public class ClientMessagePump implements NetMsgHandler { | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                    return; | 
					 | 
					 | 
					 | 
					                    return; | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					
 | 
					 | 
					 | 
					 | 
					
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                if (buy != null) { | 
					 | 
					 | 
					 | 
					                if (buy != null) { | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					
 | 
					 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                    msg.setItem(buy); | 
					 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                    //send the buy message back to update player
 | 
					 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                    //					msg.setItemType(buy.getObjectType().ordinal());
 | 
					 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                    //					msg.setItemID(buy.getObjectUUID());
 | 
					 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                    Dispatch dispatch = Dispatch.borrow(sourcePlayer, msg); | 
					 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                    DispatchMessage.dispatchMsgDispatch(dispatch, DispatchChannel.SECONDARY); | 
					 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                    if(npc.getName().equals("Resource Merchant")) { | 
					 | 
					 | 
					 | 
					                    if(npc.getName().equals("Resource Merchant")) { | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                        MobLoot resource = new MobLoot(npc, ItemBase.getItemBase(buy.getItemBaseID()), 1, true); | 
					 | 
					 | 
					 | 
					                        MobLoot resource = new MobLoot(npc, ItemBase.getItemBase(buy.getItemBaseID()), 1, true); | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                        resource.setValue(Warehouse.getCostForResource(buy.getItemBaseID())); | 
					 | 
					 | 
					 | 
					                        resource.setValue(Warehouse.getCostForResource(buy.getItemBaseID())); | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                        npc.getCharItemManager().addItemToInventory(resource); | 
					 | 
					 | 
					 | 
					                        npc.getCharItemManager().addItemToInventory(resource); | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                        npc.getCharItemManager().updateInventory(resource, true); | 
					 | 
					 | 
					 | 
					                        npc.getCharItemManager().updateInventory(resource, true); | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                    } | 
					 | 
					 | 
					 | 
					                    } | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					                    msg.setItem(buy); | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					                    //send the buy message back to update player
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					                    //					msg.setItemType(buy.getObjectType().ordinal());
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					                    //					msg.setItemID(buy.getObjectUUID());
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					                    Dispatch dispatch = Dispatch.borrow(sourcePlayer, msg); | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					                    DispatchMessage.dispatchMsgDispatch(dispatch, DispatchChannel.SECONDARY); | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                        itemMan.updateInventory(); | 
					 | 
					 | 
					 | 
					                        itemMan.updateInventory(); | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                } | 
					 | 
					 | 
					 | 
					                } | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					
 | 
					 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					            } finally { | 
					 | 
					 | 
					 | 
					            } finally { | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					                origin.buyLock.unlock(); | 
					 | 
					 | 
					 | 
					                origin.buyLock.unlock(); | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					            } | 
					 | 
					 | 
					 | 
					            } | 
				
			
			
		
	
	
		
		
			
				
					| 
						
							
								
							
						
						
						
					 | 
					 | 
					
  |