From dda9ac430f39fb36dc2d230632b7e449037f97f6 Mon Sep 17 00:00:00 2001 From: greenboxal2 Date: Sat, 21 Apr 2012 06:58:45 +0000 Subject: Fixed bugreport:5593 elemental bl was not removed when pc is removed/freed. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15899 54d463be-8e91-2dee-dedb-b68131a5f0ec --- src/map/unit.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/map/unit.c') diff --git a/src/map/unit.c b/src/map/unit.c index 2dd33af10..bdabb0152 100644 --- a/src/map/unit.c +++ b/src/map/unit.c @@ -2180,6 +2180,8 @@ void unit_remove_map_pc(struct map_session_data *sd, clr_type clrtype) unit_remove_map(&sd->hd->bl, clrtype); if(sd->md) unit_remove_map(&sd->md->bl, clrtype); + if(sd->ed) + unit_remove_map(&sd->ed->bl, clrtype); } void unit_free_pc(struct map_session_data *sd) @@ -2187,6 +2189,7 @@ void unit_free_pc(struct map_session_data *sd) if (sd->pd) unit_free(&sd->pd->bl,CLR_OUTSIGHT); if (sd->hd) unit_free(&sd->hd->bl,CLR_OUTSIGHT); if (sd->md) unit_free(&sd->md->bl,CLR_OUTSIGHT); + if (sd->ed) unit_free(&sd->ed->bl,CLR_OUTSIGHT); unit_free(&sd->bl,CLR_TELEPORT); } -- cgit v1.2.3-70-g09d2