summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorai4rei <ai4rei@54d463be-8e91-2dee-dedb-b68131a5f0ec>2010-12-26 15:02:31 +0000
committerai4rei <ai4rei@54d463be-8e91-2dee-dedb-b68131a5f0ec>2010-12-26 15:02:31 +0000
commita25b1a1f0fb28d4262cdbf22bcc7727b576a876a (patch)
tree6769a1dd3a1d8196f10c98267c18d6530d83e81a /src
parent7f2a12250794e5897f39acfa7314db7f926bdf12 (diff)
downloadhercules-a25b1a1f0fb28d4262cdbf22bcc7727b576a876a.tar.gz
hercules-a25b1a1f0fb28d4262cdbf22bcc7727b576a876a.tar.bz2
hercules-a25b1a1f0fb28d4262cdbf22bcc7727b576a876a.tar.xz
hercules-a25b1a1f0fb28d4262cdbf22bcc7727b576a876a.zip
* Fixed opening other player's vending terminating currently running NPC conversation. Vending is now unavailable when talking to an NPC (bugreport:2208).
* Fixed vending not accepting 0 Zeny as sell price. The client asks for confirmation when you attempt to sell items at 0 Zeny (bugreport:2595, since r918 and r11344). git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14628 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src')
-rw-r--r--src/map/clif.c7
-rw-r--r--src/map/vending.c2
2 files changed, 5 insertions, 4 deletions
diff --git a/src/map/clif.c b/src/map/clif.c
index 14b7aa16e..c5796555a 100644
--- a/src/map/clif.c
+++ b/src/map/clif.c
@@ -10872,10 +10872,11 @@ void clif_parse_CloseVending(int fd, struct map_session_data* sd)
*------------------------------------------*/
void clif_parse_VendingListReq(int fd, struct map_session_data* sd)
{
- vending_vendinglistreq(sd,RFIFOL(fd,2));
-
if( sd->npc_id )
- npc_event_dequeue(sd);
+ {// using an NPC
+ return;
+ }
+ vending_vendinglistreq(sd,RFIFOL(fd,2));
}
/*==========================================
diff --git a/src/map/vending.c b/src/map/vending.c
index 67e5ebf19..90bff7399 100644
--- a/src/map/vending.c
+++ b/src/map/vending.c
@@ -275,7 +275,7 @@ void vending_openvending(struct map_session_data* sd, const char* message, bool
sd->vending[i].index = index;
sd->vending[i].amount = amount;
- sd->vending[i].value = cap_value(value, 1, (unsigned int)battle_config.vending_max_value);
+ sd->vending[i].value = cap_value(value, 0, (unsigned int)battle_config.vending_max_value);
i++; // item successfully added
}