mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-01-01 03:21:41 +00:00
Add NPC base skeleton files to the optimizer blacklist (Fixes #4159)
This commit is contained in:
parent
b06512a60d
commit
a5adc5b018
@ -432,13 +432,18 @@ namespace Resource
|
||||
|
||||
bool canOptimize(const std::string& filename)
|
||||
{
|
||||
// xmesh.nif can not be optimized because there are keyframes added in post
|
||||
size_t slashpos = filename.find_last_of("\\/");
|
||||
if (slashpos != std::string::npos && slashpos+1 < filename.size())
|
||||
{
|
||||
std::string basename = filename.substr(slashpos+1);
|
||||
// xmesh.nif can not be optimized because there are keyframes added in post
|
||||
if (!basename.empty() && basename[0] == 'x')
|
||||
return false;
|
||||
|
||||
// NPC skeleton files can not be optimized because of keyframes added in post
|
||||
// (most of them are usually named like 'xbase_anim.nif' anyway, but not all of them :( )
|
||||
if (basename.compare(0, 9, "base_anim") == 0 || basename.compare(0, 4, "skin") == 0)
|
||||
return false;
|
||||
}
|
||||
|
||||
// For spell VFX, DummyXX nodes must remain intact. Not adding those to reservedNames to avoid being overly cautious - instead, decide on filename
|
||||
|
Loading…
Reference in New Issue
Block a user