Skip to content
Snippets Groups Projects
Commit c1202a2e authored by Perttu Ahola's avatar Perttu Ahola
Browse files

Update inventory texture too

parent 01ae0dae
No related branches found
No related tags found
No related merge requests found
......@@ -64,6 +64,7 @@ void ContentFeatures::setInventoryTexture(std::string imgname,
imgname += "^[forcesingle";
inventory_texture_name = imgname;
inventory_texture = tsrc->getTextureRaw(imgname);
}
......@@ -84,6 +85,7 @@ void ContentFeatures::setInventoryTextureCube(std::string top,
imgname_full += left;
imgname_full += "{";
imgname_full += right;
inventory_texture_name = imgname_full;
inventory_texture = tsrc->getTextureRaw(imgname_full);
}
#endif
......@@ -181,6 +183,10 @@ class CNodeDefManager: public IWritableNodeDefManager
if(f->special_material2)
f->special_material2->setTexture(0, f->special_atlas->atlas);
}
if(f->inventory_texture_name != ""){
f->inventory_texture =
tsrc->getTextureRaw(f->inventory_texture_name);
}
}
#endif
}
......
......@@ -113,6 +113,7 @@ struct ContentFeatures
*/
TileSpec tiles[6];
std::string inventory_texture_name;
video::ITexture *inventory_texture;
// Used currently for flowing liquids
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment