timetable ui panel enhancement, door cab control logic fix, load visualization model loading error logging tweak

This commit is contained in:
tmj-fstate
2019-06-04 18:41:47 +02:00
parent 39596c76ba
commit a9365e7845
6 changed files with 36 additions and 33 deletions

View File

@@ -57,7 +57,7 @@ TModelsManager::LoadModel(std::string const &Name, bool dynamic) {
}
TModel3d *
TModelsManager::GetModel(std::string const &Name, bool const Dynamic)
TModelsManager::GetModel(std::string const &Name, bool const Dynamic, bool const Logerrors )
{ // model może być we wpisie "node...model" albo "node...dynamic", a także być dodatkowym w dynamic
// (kabina, wnętrze, ładunek)
// dla "node...dynamic" mamy podaną ścieżkę w "\dynamic\" i musi być co najmniej 1 poziom, zwkle
@@ -107,7 +107,9 @@ TModelsManager::GetModel(std::string const &Name, bool const Dynamic)
}
else {
// there's nothing matching in the databank nor on the disk, report failure...
ErrorLog( "Bad file: failed do locate 3d model file \"" + filename + "\"", logtype::file );
if( Logerrors ) {
ErrorLog( "Bad file: failed do locate 3d model file \"" + filename + "\"", logtype::file );
}
// ...and link it with the error model slot
m_modelsmap.emplace( filename, null_handle );
}