diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/map/map.c | 2 | ||||
-rw-r--r-- | src/map/unit.c | 1 |
2 files changed, 2 insertions, 1 deletions
diff --git a/src/map/map.c b/src/map/map.c index 9155a11f3..b6bb89669 100644 --- a/src/map/map.c +++ b/src/map/map.c @@ -1566,6 +1566,8 @@ int map_quit(struct map_session_data *sd) if (sd->npc_id) npc_event_dequeue(sd); + if( sd->bg_id ) + bg_team_leave(sd,1); npc_script_event(sd, NPCE_LOGOUT); //Unit_free handles clearing the player related data, diff --git a/src/map/unit.c b/src/map/unit.c index 52b479b25..44296ca51 100644 --- a/src/map/unit.c +++ b/src/map/unit.c @@ -2139,7 +2139,6 @@ int unit_free(struct block_list *bl, clr_type clrtype) guild_send_memberinfoshort(sd,0); pc_cleareventtimer(sd); pc_inventory_rental_clear(sd); - if( sd->bg_id ) bg_team_leave(sd,1); pc_delspiritball(sd,sd->spiritball,1); if( sd->reg ) |