Core: Added some anti-WPE filter checks to prevent putting non-empty bags into other bags/gbank/mail/auction, original patch from mythcore
Core: Changed inventory saving - will no longer abort operation at single item fail Closes issue #1994. --HG-- branch : trunk
This commit is contained in:
@@ -1977,6 +1977,13 @@ void Guild::MoveFromCharToBank(Player * pl, uint8 PlayerBag, uint8 PlayerSlot, u
|
||||
if (!pItemChar) // Problem to get item from player
|
||||
return;
|
||||
|
||||
// prevent storing non-empty bags
|
||||
if (pItemChar && pItemChar->IsBag() && !((Bag*)pItemChar)->IsEmpty())
|
||||
{
|
||||
pl->SendEquipError(EQUIP_ERR_CAN_ONLY_DO_WITH_EMPTY_BAGS, pItemChar, NULL);
|
||||
return;
|
||||
}
|
||||
|
||||
if (!pItemChar->CanBeTraded())
|
||||
{
|
||||
pl->SendEquipError(EQUIP_ERR_ITEMS_CANT_BE_SWAPPED, pItemChar, NULL);
|
||||
|
||||
Reference in New Issue
Block a user