From: Holger Schemel Date: Fri, 17 Aug 2018 13:11:19 +0000 (+0200) Subject: fixed warning for missing level template when loading level X-Git-Tag: 4.1.1.0~73 X-Git-Url: https://git.artsoft.org/?a=commitdiff_plain;h=573c7e1b90b4c8cba0e5a1ce4095231095a2e5aa;p=rocksndiamonds.git fixed warning for missing level template when loading level --- diff --git a/src/files.c b/src/files.c index 151c8079..37864e0d 100644 --- a/src/files.c +++ b/src/files.c @@ -6582,6 +6582,13 @@ void LoadLevelTemplate(int nr) { char *filename; + if (!fileExists(getGlobalLevelTemplateFilename())) + { + Error(ERR_WARN, "no level template found for this level"); + + return; + } + setLevelFileInfo(&level_template.file_info, nr); filename = level_template.file_info.filename;