aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAaron Suen <warr1024@gmail.com>2013-05-09 21:10:33 -0400
committerAaron Suen <warr1024@gmail.com>2013-05-10 19:25:50 -0400
commit6911a7d279f487b832882d95318d432d0afbcc6b (patch)
tree3fa4226e2408b280633bf4dc70da1d0c6def8756 /src
parent5068cb40ce437257b01234641779567531f132b1 (diff)
downloadminetest-6911a7d279f487b832882d95318d432d0afbcc6b.tar.gz
minetest-6911a7d279f487b832882d95318d432d0afbcc6b.tar.bz2
minetest-6911a7d279f487b832882d95318d432d0afbcc6b.zip
Clear custom player HUDs when emerging players. Fixes #711.
Diffstat (limited to 'src')
-rw-r--r--src/server.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/server.cpp b/src/server.cpp
index bf48a40d5..40a4f8a02 100644
--- a/src/server.cpp
+++ b/src/server.cpp
@@ -5077,6 +5077,9 @@ PlayerSAO* Server::emergePlayer(const char *name, u16 peer_id)
getPlayerEffectivePrivs(player->getName()),
isSingleplayer());
+ /* Clean up old HUD elements from previous sessions */
+ player->hud.clear();
+
/* Add object to environment */
m_env->addActiveObject(playersao);