From 69078cf4085badd9215003f4ff71b987dfd134f5 Mon Sep 17 00:00:00 2001 From: skotlex Date: Wed, 26 Jul 2006 15:12:50 +0000 Subject: - Added support for "sc_end -1" which will clear all status changes. Added the constant SC_ALL so you can use in scripts "sc_end SC_ALL;" instead. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@7895 54d463be-8e91-2dee-dedb-b68131a5f0ec --- src/map/script.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src/map') diff --git a/src/map/script.c b/src/map/script.c index 70b1e7c94..476e9011f 100644 --- a/src/map/script.c +++ b/src/map/script.c @@ -6458,8 +6458,11 @@ int buildin_sc_end(struct script_state *st) if (potion_flag==1 && potion_target) bl = map_id2bl(potion_target); - if (bl) + if (!bl) return 0; + if (type >= 0) status_change_end(bl,type,-1); + else + status_change_clear(bl, 2); return 0; } /*========================================== -- cgit v1.2.3-70-g09d2