From fd36ec7613d19c78fe4c598f1667c74317b291ad Mon Sep 17 00:00:00 2001 From: Koncord Date: Sun, 19 Feb 2017 22:43:57 +0800 Subject: [PATCH] [Server] Iterate cells where player was loaded instead all --- apps/openmw-mp/Cell.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/openmw-mp/Cell.cpp b/apps/openmw-mp/Cell.cpp index 7341504e7..9b78228c7 100644 --- a/apps/openmw-mp/Cell.cpp +++ b/apps/openmw-mp/Cell.cpp @@ -142,7 +142,7 @@ void CellController::removePlayer(Cell *cell, Player *player) void CellController::deletePlayer(Player *player) { - for_each (cells.begin(), cells.end(), [&player](Cell *cell) { + for_each (player->getCells().begin(), player->getCells().end(), [&player](Cell *cell) { for (auto it = cell->begin(); it != cell->end(); ++it) { if (*it == player)