summaryrefslogtreecommitdiff
path: root/src/serverenvironment.cpp
diff options
context:
space:
mode:
authorDániel Juhász <juhdanad@gmail.com>2018-02-10 22:04:16 +0200
committerSmallJoker <SmallJoker@users.noreply.github.com>2018-02-10 21:04:16 +0100
commit3face01a202040e4feff3b0936b4aa89c051c98d (patch)
treeccdad6773aa9705cc07fdc9f71f28bae395f353e /src/serverenvironment.cpp
parent617d94c8038e3ff035eaeef7ccdfa4f442feb873 (diff)
downloadminetest-3face01a202040e4feff3b0936b4aa89c051c98d.tar.gz
minetest-3face01a202040e4feff3b0936b4aa89c051c98d.tar.bz2
minetest-3face01a202040e4feff3b0936b4aa89c051c98d.zip
Node definition manager refactor (#7016)
* Rename IWritableNodeDefManager to NodeDefManager * Make INodeDefManager functions const * Use "const *NodeDefManager" instead of "*INodeDefManager" * Remove unused INodeDefManager class * Merge NodeDefManager and CNodeDefManager * Document NodeDefManager
Diffstat (limited to 'src/serverenvironment.cpp')
-rw-r--r--src/serverenvironment.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/serverenvironment.cpp b/src/serverenvironment.cpp
index f949021f6..53d30c4fb 100644
--- a/src/serverenvironment.cpp
+++ b/src/serverenvironment.cpp
@@ -80,7 +80,7 @@ void LBMContentMapping::addLBM(LoadingBlockModifierDef *lbm_def, IGameDef *gamed
{
// Add the lbm_def to the LBMContentMapping.
// Unknown names get added to the global NameIdMapping.
- INodeDefManager *nodedef = gamedef->ndef();
+ const NodeDefManager *nodedef = gamedef->ndef();
lbm_list.push_back(lbm_def);
@@ -691,7 +691,7 @@ public:
{
if(dtime_s < 0.001)
return;
- INodeDefManager *ndef = env->getGameDef()->ndef();
+ const NodeDefManager *ndef = env->getGameDef()->ndef();
for (ABMWithState &abmws : abms) {
ActiveBlockModifier *abm = abmws.abm;
float trigger_interval = abm->getTriggerInterval();
@@ -914,7 +914,7 @@ void ServerEnvironment::addLoadingBlockModifierDef(LoadingBlockModifierDef *lbm)
bool ServerEnvironment::setNode(v3s16 p, const MapNode &n)
{
- INodeDefManager *ndef = m_server->ndef();
+ const NodeDefManager *ndef = m_server->ndef();
MapNode n_old = m_map->getNodeNoEx(p);
const ContentFeatures &cf_old = ndef->get(n_old);
@@ -947,7 +947,7 @@ bool ServerEnvironment::setNode(v3s16 p, const MapNode &n)
bool ServerEnvironment::removeNode(v3s16 p)
{
- INodeDefManager *ndef = m_server->ndef();
+ const NodeDefManager *ndef = m_server->ndef();
MapNode n_old = m_map->getNodeNoEx(p);
// Call destructor