diff options
author | momacabu <momacabu@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2012-11-30 00:30:13 +0000 |
---|---|---|
committer | momacabu <momacabu@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2012-11-30 00:30:13 +0000 |
commit | a97c2837c050d53bed4010f3399dcd5d0ad8b269 (patch) | |
tree | 53470d89099cb9932509a0fed9af88f93c2286ab /src/map/script.c | |
parent | 325d58d7e7f0e67e69e891bc26549c9cb2d85a9e (diff) | |
download | hercules-a97c2837c050d53bed4010f3399dcd5d0ad8b269.tar.gz hercules-a97c2837c050d53bed4010f3399dcd5d0ad8b269.tar.bz2 hercules-a97c2837c050d53bed4010f3399dcd5d0ad8b269.tar.xz hercules-a97c2837c050d53bed4010f3399dcd5d0ad8b269.zip |
- Minor tweak in @jobchange, it will now read msg_athena.conf job names;
- Fixed warning in cleanmap command (follow up to r16971).
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@16986 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/script.c')
-rw-r--r-- | src/map/script.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/map/script.c b/src/map/script.c index 351d5d615..8ff244538 100644 --- a/src/map/script.c +++ b/src/map/script.c @@ -17363,13 +17363,16 @@ static int atcommand_cleanfloor_sub(struct block_list *bl, va_list ap) BUILDIN_FUNC(cleanmap) { const char *map; - int m, index; - short x0, y0, x1, y1; + int m = -1, index = -1; + short x0 = 0, y0 = 0, x1 = 0, y1 = 0; map = script_getstr(st, 2); index = mapindex_name2id(map); if (index) m = map_mapindex2mapid(index); + + if (!m) + return 1; if ((script_lastdata(st) - 2) < 4) { map_foreachinmap(atcommand_cleanfloor_sub, m, BL_ITEM); |