aboutsummaryrefslogtreecommitdiff
path: root/src/mapblock_mesh.h
diff options
context:
space:
mode:
authorest31 <MTest31@outlook.com>2016-12-22 23:16:00 +0100
committerest31 <MTest31@outlook.com>2016-12-22 23:16:00 +0100
commit81d56b94919dceb7b2e51d70b21a7ca22f852bd5 (patch)
tree1e9ef1be1b3295a8673d6e4f0bdeb4c2d3a6015f /src/mapblock_mesh.h
parent8077612dcb48221281e726a60eb97bf73fde462b (diff)
parent231ac33d34dfaaddf292c5f31b1eae43eeefba2d (diff)
downloadminetest-81d56b94919dceb7b2e51d70b21a7ca22f852bd5.tar.gz
minetest-81d56b94919dceb7b2e51d70b21a7ca22f852bd5.tar.bz2
minetest-81d56b94919dceb7b2e51d70b21a7ca22f852bd5.zip
Merge 0.4.15 changes into stable-0.4
0.4.15 release!
Diffstat (limited to 'src/mapblock_mesh.h')
-rw-r--r--src/mapblock_mesh.h15
1 files changed, 8 insertions, 7 deletions
diff --git a/src/mapblock_mesh.h b/src/mapblock_mesh.h
index f89fbe669..8376468da 100644
--- a/src/mapblock_mesh.h
+++ b/src/mapblock_mesh.h
@@ -23,6 +23,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
#include "irrlichttypes_extrabloated.h"
#include "client/tile.h"
#include "voxel.h"
+#include "util/cpp11_container.h"
#include <map>
class IGameDef;
@@ -121,7 +122,7 @@ public:
if(m_animation_force_timer > 0)
m_animation_force_timer--;
}
-
+
void updateCameraOffset(v3s16 camera_offset);
private:
@@ -144,20 +145,20 @@ private:
// Last crack value passed to animate()
int m_last_crack;
// Maps mesh buffer (i.e. material) indices to base texture names
- std::map<u32, std::string> m_crack_materials;
+ UNORDERED_MAP<u32, std::string> m_crack_materials;
// Animation info: texture animationi
// Maps meshbuffers to TileSpecs
- std::map<u32, TileSpec> m_animation_tiles;
- std::map<u32, int> m_animation_frames; // last animation frame
- std::map<u32, int> m_animation_frame_offsets;
-
+ UNORDERED_MAP<u32, TileSpec> m_animation_tiles;
+ UNORDERED_MAP<u32, int> m_animation_frames; // last animation frame
+ UNORDERED_MAP<u32, int> m_animation_frame_offsets;
+
// Animation info: day/night transitions
// Last daynight_ratio value passed to animate()
u32 m_last_daynight_ratio;
// For each meshbuffer, maps vertex indices to (day,night) pairs
std::map<u32, std::map<u32, std::pair<u8, u8> > > m_daynight_diffs;
-
+
// Camera offset info -> do we have to translate the mesh?
v3s16 m_camera_offset;
};