diff options
author | Kenpachi Developer <Kenpachi.Developer@gmx.de> | 2020-06-25 08:00:37 +0200 |
---|---|---|
committer | Kenpachi Developer <Kenpachi.Developer@gmx.de> | 2020-06-25 08:00:37 +0200 |
commit | 7aacf9eed8162c18733364cc9b52f1b9358bc9db (patch) | |
tree | 8d7591ee91a938c9f258d9becf71a6b5c9366de0 /src/map | |
parent | 7aa47a08bfdce1a6f65acaa86815b9d8a02e3a48 (diff) | |
download | hercules-7aacf9eed8162c18733364cc9b52f1b9358bc9db.tar.gz hercules-7aacf9eed8162c18733364cc9b52f1b9358bc9db.tar.bz2 hercules-7aacf9eed8162c18733364cc9b52f1b9358bc9db.tar.xz hercules-7aacf9eed8162c18733364cc9b52f1b9358bc9db.zip |
Enable moving items between cart and inventory while Megaphone input box is present
Diffstat (limited to 'src/map')
-rw-r--r-- | src/map/clif.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/map/clif.c b/src/map/clif.c index db719256e..491e4f805 100644 --- a/src/map/clif.c +++ b/src/map/clif.c @@ -12548,8 +12548,10 @@ static void clif_parse_PutItemToCart(int fd, struct map_session_data *sd) __attr static void clif_parse_PutItemToCart(int fd, struct map_session_data *sd) { int flag = 0; - if (pc_istrading(sd) || sd->state.prevend) + + if (pc_istrading_except_npc(sd) || (sd->npc_id != 0 && sd->state.using_megaphone == 0) || sd->state.prevend != 0) return; + if (!pc_iscarton(sd)) return; if ( (flag = pc->putitemtocart(sd,RFIFOW(fd,2)-2,RFIFOL(fd,4))) ) { @@ -12563,8 +12565,9 @@ static void clif_parse_GetItemFromCart(int fd, struct map_session_data *sd) __at /// 0127 <index>.W <amount>.L static void clif_parse_GetItemFromCart(int fd, struct map_session_data *sd) { - if (pc_istrading(sd) || sd->state.prevend) + if (pc_istrading_except_npc(sd) || (sd->npc_id != 0 && sd->state.using_megaphone == 0) || sd->state.prevend != 0) return; + if (!pc_iscarton(sd)) return; pc->getitemfromcart(sd,RFIFOW(fd,2)-2,RFIFOL(fd,4)); |