From 1cc18f6e7b589946be5beb4d8a9284d67054579a Mon Sep 17 00:00:00 2001 From: Johannes Schickel Date: Thu, 8 Feb 2007 09:41:10 +0000 Subject: Don't rely on assert when calling functions. svn-id: r25426 --- engines/kyra/kyra3.cpp | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/engines/kyra/kyra3.cpp b/engines/kyra/kyra3.cpp index 772c4cee89..d17a2b72c3 100644 --- a/engines/kyra/kyra3.cpp +++ b/engines/kyra/kyra3.cpp @@ -400,9 +400,12 @@ void KyraEngine_v3::realInit() { musicUpdate(0); musicUpdate(0); - assert(loadLanguageFile("ITEMS.", _itemList)); - assert(loadLanguageFile("C_CODE.", _cCodeFile)); - assert(loadLanguageFile("SCENES.", _scenesList)); + if (!loadLanguageFile("ITEMS.", _itemList)) + error("couldn't load ITEMS"); + if (!loadLanguageFile("C_CODE.", _cCodeFile)) + error("couldn't load C_CODE"); + if (!loadLanguageFile("SCENES.", _scenesList)) + error("couldn't load SCENES"); assert(_unkBuffer5 && _unkBuffer6 && _unkBuffer7 && _costpalData && _unkBuffer9 && _unkWSAPtr && _unkPage2 && _itemList && _cCodeFile && _scenesList); -- cgit v1.2.3