From 24556fbd5969a6cc2806a46b853e6252b5d7cd06 Mon Sep 17 00:00:00 2001 From: shennetsind Date: Fri, 4 Oct 2013 16:31:38 -0300 Subject: Fixed Storage AddItem Bug Fixed a ancient bug where trying to add a item to a full storage would render the item un-draggable (server was failing to respond properly). Thanks to Sanasol for bringing it up. Signed-off-by: shennetsind --- src/map/storage.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/map/storage.c') diff --git a/src/map/storage.c b/src/map/storage.c index 91515dfe1..cc1100d28 100644 --- a/src/map/storage.c +++ b/src/map/storage.c @@ -196,8 +196,7 @@ int storage_delitem(struct map_session_data* sd, int n, int amount) * 0 : fail * 1 : success *------------------------------------------*/ -int storage_storageadd(struct map_session_data* sd, int index, int amount) -{ +int storage_storageadd(struct map_session_data* sd, int index, int amount) { nullpo_ret(sd); if( sd->status.storage.storage_amount > MAX_STORAGE ) @@ -214,6 +213,8 @@ int storage_storageadd(struct map_session_data* sd, int index, int amount) if( storage->additem(sd,&sd->status.inventory[index],amount) == 0 ) pc->delitem(sd,index,amount,0,4,LOG_TYPE_STORAGE); + else + clif->dropitem(sd, index,0); return 1; } -- cgit v1.2.3-60-g2f50