diff options
author | Kenpachi Developer <Kenpachi.Developer@gmx.de> | 2020-06-25 08:07:51 +0200 |
---|---|---|
committer | Kenpachi Developer <Kenpachi.Developer@gmx.de> | 2020-06-25 08:07:51 +0200 |
commit | 7da438ed9885aa05f4d2748e655ad889b4d39c85 (patch) | |
tree | 9582925467a669e69b335c15ef4a6a9ab6afb767 /src/map/vending.c | |
parent | d6622f54398a780d9c007c75855971ebb2a19ea1 (diff) | |
download | hercules-7da438ed9885aa05f4d2748e655ad889b4d39c85.tar.gz hercules-7da438ed9885aa05f4d2748e655ad889b4d39c85.tar.bz2 hercules-7da438ed9885aa05f4d2748e655ad889b4d39c85.tar.xz hercules-7da438ed9885aa05f4d2748e655ad889b4d39c85.zip |
Enable vending shop features while Megaphone input box is present
Diffstat (limited to 'src/map/vending.c')
-rw-r--r-- | src/map/vending.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/map/vending.c b/src/map/vending.c index 4fd009025..9b3f48f38 100644 --- a/src/map/vending.c +++ b/src/map/vending.c @@ -251,8 +251,10 @@ static void vending_openvending(struct map_session_data *sd, const char *message int vending_skill_lvl; nullpo_retv(sd); - if ( pc_isdead(sd) || !sd->state.prevend || pc_istrading(sd)) - return; // can't open vendings lying dead || didn't use via the skill (wpe/hack) || can't have 2 shops at once + if (pc_isdead(sd) || sd->state.prevend == 0 || pc_istrading_except_npc(sd) + || (sd->npc_id != 0 && sd->state.using_megaphone == 0)) { + return; // Can't open vendings lying dead. || Didn't use via the skill. (wpe/hack) || Can't have 2 shops at once. + } vending_skill_lvl = pc->checkskill(sd, MC_VENDING); // skill level and cart check |