diff options
Diffstat (limited to 'src/resources/spritedef.cpp')
-rw-r--r-- | src/resources/spritedef.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/resources/spritedef.cpp b/src/resources/spritedef.cpp index de6f8d0b..ee823c3f 100644 --- a/src/resources/spritedef.cpp +++ b/src/resources/spritedef.cpp @@ -62,7 +62,10 @@ SpriteDef *SpriteDef::load(std::string const &animationFile, int variant) char *data = (char*) resman->loadFile (animationFile.substr(0, pos).c_str(), size); - if (!data) return NULL; + if (!data && animationFile != "graphics/sprites/error.xml") + { + return load("graphics/sprites/error.xml", 0); + } xmlDocPtr doc = xmlParseMemory(data, size); free(data); |