summaryrefslogtreecommitdiff
path: root/src/map/clif.c
diff options
context:
space:
mode:
authorDennis Friis <peavey@inspircd.org>2009-06-23 04:28:53 +0200
committerDennis Friis <peavey@inspircd.org>2009-06-25 01:13:20 +0200
commit5340f4943a444276690d4334653fedcf65e90844 (patch)
tree1e747221476eaed87b3c448c8d02d4fbab4b42af /src/map/clif.c
parent7a2781853d87ea0b613efc709b6f84645541990b (diff)
downloadtmwa-5340f4943a444276690d4334653fedcf65e90844.tar.gz
tmwa-5340f4943a444276690d4334653fedcf65e90844.tar.bz2
tmwa-5340f4943a444276690d4334653fedcf65e90844.tar.xz
tmwa-5340f4943a444276690d4334653fedcf65e90844.zip
Dont allow any use of storage while in a trade, dereived from ea stable.
Diffstat (limited to 'src/map/clif.c')
-rw-r--r--src/map/clif.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/map/clif.c b/src/map/clif.c
index ad65f88..e28eeed 100644
--- a/src/map/clif.c
+++ b/src/map/clif.c
@@ -7156,7 +7156,7 @@ void clif_parse_PutItemToCart(int fd,struct map_session_data *sd)
{
nullpo_retv(sd);
- if(sd->npc_id!=0)
+ if(sd->npc_id!=0 || sd->trade_partner != 0)
return;
pc_putitemtocart(sd,RFIFOW(fd,2)-2,RFIFOL(fd,4));
}
@@ -7168,7 +7168,7 @@ void clif_parse_GetItemFromCart(int fd,struct map_session_data *sd)
{
nullpo_retv(sd);
- if(sd->npc_id!=0) return;
+ if(sd->npc_id!=0 || sd->trade_partner != 0) return;
pc_getitemfromcart(sd,RFIFOW(fd,2)-2,RFIFOL(fd,4));
}
@@ -7537,7 +7537,7 @@ void clif_parse_MoveToKafra(int fd, struct map_session_data *sd) {
item_index = RFIFOW(fd,2) - 2;
item_amount = RFIFOL(fd,4);
- if (sd->npc_id != 0 && !sd->npc_flags.storage)
+ if (sd->npc_id != 0 || sd->trade_partner != 0 || !sd->state.storage_flag)
return;
if (sd->state.storage_flag == 1)
@@ -7558,7 +7558,7 @@ void clif_parse_MoveFromKafra(int fd,struct map_session_data *sd) {
item_index = RFIFOW(fd,2) - 1;
item_amount = RFIFOL(fd,4);
- if (sd->npc_id != 0 && !sd->npc_flags.storage)
+ if (sd->npc_id != 0 || sd->trade_partner != 0 || !sd->state.storage_flag)
return;
if (sd->state.storage_flag == 1)
@@ -7589,7 +7589,7 @@ void clif_parse_MoveToKafraFromCart(int fd, struct map_session_data *sd) {
void clif_parse_MoveFromKafraToCart(int fd, struct map_session_data *sd) {
nullpo_retv(sd);
- if (sd->npc_id != 0)
+ if (sd->npc_id != 0 || sd->trade_partner != 0 || !sd->state.storage_flag)
return;
if (sd->state.storage_flag == 1)
storage_storagegettocart(sd, RFIFOW(fd,2)-1, RFIFOL(fd,4));