summaryrefslogtreecommitdiff
path: root/src/map/status.c
diff options
context:
space:
mode:
authorzephyrus <zephyrus@54d463be-8e91-2dee-dedb-b68131a5f0ec>2008-02-26 22:14:05 +0000
committerzephyrus <zephyrus@54d463be-8e91-2dee-dedb-b68131a5f0ec>2008-02-26 22:14:05 +0000
commit2be5a82d3849a499377ece635b4ec3932dfc6ec9 (patch)
tree832ac26cb7f7b007d7525c2c89cbfa2460823393 /src/map/status.c
parent288978d302ad332a8e22766278cb65dbd6f2a746 (diff)
downloadhercules-2be5a82d3849a499377ece635b4ec3932dfc6ec9.tar.gz
hercules-2be5a82d3849a499377ece635b4ec3932dfc6ec9.tar.bz2
hercules-2be5a82d3849a499377ece635b4ec3932dfc6ec9.tar.xz
hercules-2be5a82d3849a499377ece635b4ec3932dfc6ec9.zip
- Added new settings for autotrade on battle/misc.conf (you can read descriptions there).
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@12243 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/status.c')
-rw-r--r--src/map/status.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/map/status.c b/src/map/status.c
index f7e3157bf..3c13404e2 100644
--- a/src/map/status.c
+++ b/src/map/status.c
@@ -25,6 +25,7 @@
#include "script.h"
#include "unit.h"
#include "mercenary.h"
+#include "vending.h"
#include <time.h>
#include <stdio.h>
@@ -6489,6 +6490,15 @@ int status_change_end(struct block_list* bl, enum sc_type type, int tid)
status_set_hp(bl, 10, 0);
status_set_sp(bl, 10, 0);
break;
+ case SC_AUTOTRADE:
+ if (tid == -1)
+ break;
+ vending_closevending(sd);
+ map_quit(sd);
+ // Because map_quit calls status_change_end with tid -1
+ // from here it's not neccesary to continue
+ return 1;
+ break;
}
opt_flag = 1;