summaryrefslogtreecommitdiff
path: root/src/map/buyingstore.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/map/buyingstore.c')
-rw-r--r--src/map/buyingstore.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/map/buyingstore.c b/src/map/buyingstore.c
index df622e4ab..8cac65775 100644
--- a/src/map/buyingstore.c
+++ b/src/map/buyingstore.c
@@ -91,7 +91,7 @@ static void buyingstore_create(struct map_session_data *sd, int zenylimit, unsig
return;
}
- if( !battle_config.feature_buying_store || pc_istrading(sd) || sd->buyingstore.slots == 0 || count > sd->buyingstore.slots || zenylimit <= 0 || zenylimit > sd->status.zeny || !storename[0] )
+ if( !battle_config.feature_buying_store || pc_istrading(sd) || sd->state.prevend || sd->buyingstore.slots == 0 || count > sd->buyingstore.slots || zenylimit <= 0 || zenylimit > sd->status.zeny || !storename[0] )
{// disabled or invalid input
sd->buyingstore.slots = 0;
clif->buyingstore_open_failed(sd, BUYINGSTORE_CREATE, 0);
@@ -218,7 +218,7 @@ static void buyingstore_open(struct map_session_data *sd, int account_id)
struct map_session_data* pl_sd;
nullpo_retv(sd);
- if( !battle_config.feature_buying_store || pc_istrading(sd) )
+ if (!battle_config.feature_buying_store || pc_istrading(sd) || sd->state.prevend)
{// not allowed to sell
return;
}
@@ -255,7 +255,7 @@ static void buyingstore_trade(struct map_session_data* sd, int account_id, unsig
return;
}
- if( !battle_config.feature_buying_store || pc_istrading(sd) )
+ if (!battle_config.feature_buying_store || pc_istrading(sd) || sd->state.prevend)
{// not allowed to sell
clif->buyingstore_trade_failed_seller(sd, BUYINGSTORE_TRADE_SELLER_FAILED, 0);
return;