Thread: Bug I found
View Single Post
  #2  
Old 12-21-2003, 03:06 AM
Tertiary
Hill Giant
 
Join Date: Nov 2003
Posts: 192
Default

I had a look at this. It seems that whenever you buy anything from an NPC merchant, it is not deducting the money from your 'Player Profile', although clientside it does, until you zone.

I tried a quick fix. In zone/client process.cpp, in the case OP_ShopPlayerBuy: section, make this change, around line 2942:
Code:
if (inst) {	
	freeslotid = m_inv.FindFreeSlot(false, true);
	PutItemInInventory(freeslotid, *inst);
	if(freeslotid!=SLOT_INVALID)                 // Add this line
	    TakeMoneyFromPP(mpo->price);       // Add this line
	SendItemPacket(freeslotid, inst, ItemPacketTrade);
	safe_delete(inst);
}
I did some quick tests and it seems to fix it. This was with 5.3DR1 Dec 17 source.
Reply With Quote