aboutsummaryrefslogtreecommitdiff
path: root/src/content_sao.cpp
diff options
context:
space:
mode:
authorShadowNinja <shadowninja@minetest.net>2014-05-30 16:04:07 -0400
committerShadowNinja <shadowninja@minetest.net>2014-06-23 15:45:59 -0400
commit7e6db1b80344a519e53a9967a159c8d3585a9b9d (patch)
treedcdd53f2f558b8c57ca4b58a754e7ed0be015c6c /src/content_sao.cpp
parent50127510e72732b069be040db2d2bbdad4d0be1c (diff)
downloadminetest-7e6db1b80344a519e53a9967a159c8d3585a9b9d.tar.gz
minetest-7e6db1b80344a519e53a9967a159c8d3585a9b9d.tar.bz2
minetest-7e6db1b80344a519e53a9967a159c8d3585a9b9d.zip
Only keep players loaded while they're connected
Diffstat (limited to 'src/content_sao.cpp')
-rw-r--r--src/content_sao.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/content_sao.cpp b/src/content_sao.cpp
index 095c6b5bf..4ee92f4d3 100644
--- a/src/content_sao.cpp
+++ b/src/content_sao.cpp
@@ -1027,6 +1027,8 @@ void PlayerSAO::removingFromEnvironment()
{
m_player->setPlayerSAO(NULL);
m_player->peer_id = 0;
+ m_env->savePlayer(m_player->getName());
+ m_env->removePlayer(m_player->getName());
}
}