projects
/
oweals
/
minetest.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Node highlighting.
[oweals/minetest.git]
/
src
/
content_sao.cpp
diff --git
a/src/content_sao.cpp
b/src/content_sao.cpp
index 52b741365cfa18c16606d3d3a4cdb85b4b3389d7..4ee92f4d34255408e83f1159cfadb73f359fb26b 100644
(file)
--- a/
src/content_sao.cpp
+++ b/
src/content_sao.cpp
@@
-191,7
+191,7
@@
public:
}
ItemSAO(ServerEnvironment *env, v3f pos,
}
ItemSAO(ServerEnvironment *env, v3f pos,
- const std::string itemstring):
+ const std::string
&
itemstring):
ServerActiveObject(env, pos),
m_itemstring(itemstring),
m_itemstring_changed(false),
ServerActiveObject(env, pos),
m_itemstring(itemstring),
m_itemstring_changed(false),
@@
-350,7
+350,7
@@
private:
ItemSAO proto_ItemSAO(NULL, v3f(0,0,0), "");
ServerActiveObject* createItemSAO(ServerEnvironment *env, v3f pos,
ItemSAO proto_ItemSAO(NULL, v3f(0,0,0), "");
ServerActiveObject* createItemSAO(ServerEnvironment *env, v3f pos,
-
const std::string
itemstring)
+
const std::string &
itemstring)
{
return new ItemSAO(env, pos, itemstring);
}
{
return new ItemSAO(env, pos, itemstring);
}
@@
-1027,6
+1027,8
@@
void PlayerSAO::removingFromEnvironment()
{
m_player->setPlayerSAO(NULL);
m_player->peer_id = 0;
{
m_player->setPlayerSAO(NULL);
m_player->peer_id = 0;
+ m_env->savePlayer(m_player->getName());
+ m_env->removePlayer(m_player->getName());
}
}
}
}