From 4822003e8cd55d137d7d857fa38d4307ecaecc6b Mon Sep 17 00:00:00 2001 From: cookiecrumbs Date: Tue, 17 Jul 2012 06:36:49 +0000 Subject: Fixed double decrement with unit_remove_map and the issue that causes dynamic mobs to not spawn when one player is on the map. bugreport:1640 git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@16434 54d463be-8e91-2dee-dedb-b68131a5f0ec --- src/map/pc.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/map/pc.c') diff --git a/src/map/pc.c b/src/map/pc.c index 215086532..1e18e4941 100644 --- a/src/map/pc.c +++ b/src/map/pc.c @@ -4637,6 +4637,12 @@ int pc_setpos(struct map_session_data* sd, unsigned short mapindex, int x, int y sd->md->ud.dir = sd->ud.dir; } + // If the player is changing maps, end cloaking and cloaking exceed. + if ( sd->state.changemap && sd->sc.count ) + { + status_change_end(&sd->bl, SC_CLOAKING, INVALID_TIMER); + status_change_end(&sd->bl, SC_CLOAKINGEXCEED, INVALID_TIMER); + } return 0; } -- cgit v1.2.3-70-g09d2