1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-06-27 16:36:03 +00:00

Remove preload_item_visuals code

Closes #3748
This commit is contained in:
RealBadAngel 2016-02-20 03:37:26 +01:00 committed by est31
parent 354635f9fb
commit 2f4cf0bcca
5 changed files with 0 additions and 38 deletions

View file

@ -1766,29 +1766,6 @@ void Client::afterContentReceived(IrrlichtDevice *device)
m_nodedef->updateTextures(this, texture_update_progress, &tu_args);
delete[] tu_args.text_base;
// Preload item textures and meshes if configured to
if(g_settings->getBool("preload_item_visuals"))
{
verbosestream<<"Updating item textures and meshes"<<std::endl;
text = wgettext("Item textures...");
draw_load_screen(text, device, guienv, 0, 0);
std::set<std::string> names = m_itemdef->getAll();
size_t size = names.size();
size_t count = 0;
int percent = 0;
for(std::set<std::string>::const_iterator
i = names.begin(); i != names.end(); ++i)
{
// Asking for these caches the result
m_itemdef->getInventoryTexture(*i, this);
m_itemdef->getWieldMesh(*i, this);
count++;
percent = (count * 100 / size * 0.2) + 80;
draw_load_screen(text, device, guienv, 0, percent);
}
delete[] text;
}
// Start mesh update thread after setting up content definitions
infostream<<"- Starting mesh update thread"<<std::endl;
m_mesh_update_thread.start();