1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-08-11 17:51:04 +00:00

Change TileSpec::frames to be std::vector not std::map

Signed-off-by: Craig Robbins <kde.psych@gmail.com>
This commit is contained in:
unknown 2014-12-18 23:25:36 +11:00 committed by Craig Robbins
parent 0d55f43977
commit 1e8e700ee6
4 changed files with 10 additions and 7 deletions

View file

@ -1136,7 +1136,7 @@ MapBlockMesh::MapBlockMesh(MeshMakeData *data, v3s16 camera_offset):
m_animation_frame_offsets[i] = 0;
}
// Replace tile texture with the first animation frame
FrameSpec animation_frame = p.tile.frames.find(0)->second;
FrameSpec animation_frame = p.tile.frames[0];
p.tile.texture = animation_frame.texture;
}
@ -1322,7 +1322,7 @@ bool MapBlockMesh::animate(bool faraway, float time, int crack, u32 daynight_rat
scene::IMeshBuffer *buf = m_mesh->getMeshBuffer(i->first);
ITextureSource *tsrc = m_gamedef->getTextureSource();
FrameSpec animation_frame = tile.frames.find(frame)->second;
FrameSpec animation_frame = tile.frames[frame];
buf->getMaterial().setTexture(0, animation_frame.texture);
if (m_enable_shaders) {
if (animation_frame.normal_texture) {