aboutsummaryrefslogtreecommitdiff
path: root/src/mg_schematic.cpp
diff options
context:
space:
mode:
authorLoic Blot <loic.blot@unix-experience.fr>2016-10-05 09:03:55 +0200
committerNer'zhul <nerzhul@users.noreply.github.com>2016-10-05 10:53:19 +0200
commit613797a3048907275ceebe29582b9fc2761b1f25 (patch)
tree1d8f90a75c86dd3a32a72d3789bc108042d8f65d /src/mg_schematic.cpp
parent5f084cd98d7b3326b51320455364337539710efd (diff)
downloadminetest-613797a3048907275ceebe29582b9fc2761b1f25.tar.gz
minetest-613797a3048907275ceebe29582b9fc2761b1f25.tar.bz2
minetest-613797a3048907275ceebe29582b9fc2761b1f25.zip
Replace various std::map with UNORDERED_MAP + various cleanups
This is part 2 for 5f084cd98d7b3326b51320455364337539710efd Other improvements: * Use the defined ItemGroupList when used * make Client::checkPrivilege const * inline some trivial functions * Add ActiveObjectMap typedef * Add SettingsEntries typedef
Diffstat (limited to 'src/mg_schematic.cpp')
-rw-r--r--src/mg_schematic.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mg_schematic.cpp b/src/mg_schematic.cpp
index 0b95fa267..e028215dc 100644
--- a/src/mg_schematic.cpp
+++ b/src/mg_schematic.cpp
@@ -564,14 +564,14 @@ void Schematic::applyProbabilities(v3s16 p0,
void generate_nodelist_and_update_ids(MapNode *nodes, size_t nodecount,
std::vector<std::string> *usednodes, INodeDefManager *ndef)
{
- std::map<content_t, content_t> nodeidmap;
+ UNORDERED_MAP<content_t, content_t> nodeidmap;
content_t numids = 0;
for (size_t i = 0; i != nodecount; i++) {
content_t id;
content_t c = nodes[i].getContent();
- std::map<content_t, content_t>::const_iterator it = nodeidmap.find(c);
+ UNORDERED_MAP<content_t, content_t>::const_iterator it = nodeidmap.find(c);
if (it == nodeidmap.end()) {
id = numids;
numids++;