From 52f9bf63af2f28eaee4004c708a7ff78b4a0a5ee Mon Sep 17 00:00:00 2001 From: aleos89 Date: Fri, 3 Feb 2017 10:17:21 -0500 Subject: [PATCH] Fixed Cart Weight calculation (fixes #1938) * Resolves Cart weight not getting recalculated when using atcommand resetskill. Thanks to @Hactus and @Tokeiburu! --- src/map/pc.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/map/pc.c b/src/map/pc.c index 0eab4cc025..b88c9a4d30 100755 --- a/src/map/pc.c +++ b/src/map/pc.c @@ -8767,8 +8767,10 @@ bool pc_setcart(struct map_session_data *sd,int type) { clif_clearcart(sd->fd); break; default:/* everything else is an allowed ID so we can move on */ - if( !sd->sc.data[SC_PUSH_CART] ) /* first time, so fill cart data */ + if( !sd->sc.data[SC_PUSH_CART] ) { /* first time, so fill cart data */ clif_cartlist(sd); + status_calc_cart_weight(sd, CALCWT_ITEM|CALCWT_MAXBONUS|CALCWT_CARTSTATE); + } clif_updatestatus(sd, SP_CARTINFO); sc_start(&sd->bl, &sd->bl, SC_PUSH_CART, 100, type, 0); break;