Procházet zdrojové kódy

Fixes problem with PR #4148. (#4176)

* Fixes the disappearing item mentioned in PR #4148.
* Should now mirror kRO behavior when cart is full.
Thanks to @Normynator!
norm před 6 roky
rodič
revize
8ed3d0583a
1 změnil soubory, kde provedl 2 přidání a 2 odebrání
  1. 2 2
      src/map/pc.cpp

+ 2 - 2
src/map/pc.cpp

@@ -5463,9 +5463,9 @@ void pc_putitemtocart(struct map_session_data *sd,int idx,int amount)
 	if (flag == ADDITEM_SUCCESS)
 		pc_delitem(sd,idx,amount,0,5,LOG_TYPE_NONE);
 	else {
-		clif_delitem(sd, idx, amount, flag);
 		clif_cart_additem_ack(sd, (flag == ADDITEM_OVERAMOUNT) ? ADDITEM_TO_CART_FAIL_COUNT : ADDITEM_TO_CART_FAIL_WEIGHT);
-		clif_additem(sd, idx, amount, flag);
+		clif_additem(sd, idx, amount, 0);
+		clif_delitem(sd, idx, amount, 0);
 	}
 }