From 82c2f4e0e935a3932bea52cb91e78372fa5ad062 Mon Sep 17 00:00:00 2001 From: Sergii Pylypenko Date: Sat, 11 Oct 2014 07:40:54 +0300 Subject: [PATCH] JA2: removed some extra logs --- project/jni/application/ja2/ja2.patch | 223 -------------------------- 1 file changed, 223 deletions(-) diff --git a/project/jni/application/ja2/ja2.patch b/project/jni/application/ja2/ja2.patch index f0b7ac9b9..28d548b9d 100644 --- a/project/jni/application/ja2/ja2.patch +++ b/project/jni/application/ja2/ja2.patch @@ -273,27 +273,6 @@ index d156d73..66d7cf0 100644 #if defined BROKEN_SWPRINTF if (setlocale(LC_CTYPE, "UTF-8") == NULL) -@@ -361,10 +361,12 @@ try - setGameVersion(version); - - //////////////////////////////////////////////////////////// -+ SLOGD(TAG, "Starting %s:%d\n", __FILE__,__LINE__); - - SDL_Init(SDL_INIT_VIDEO); - SDL_EnableUNICODE(SDL_ENABLE); - -+ SLOGD(TAG, "Starting %s:%d\n", __FILE__,__LINE__); - #ifdef __APPLE__ - // Enable 3-button mouse support if the user haven't instructed - // otherwise -@@ -380,6 +382,7 @@ try - freopen("CON", "w", stderr); - #endif - -+ SLOGD(TAG, "Starting %s:%d\n", __FILE__,__LINE__); - #ifdef SGP_DEBUG - // Initialize the Debug Manager - success doesn't matter - InitializeDebugManager(); @@ -398,7 +401,7 @@ try if(extraDataDir.empty()) { @@ -303,14 +282,6 @@ index d156d73..66d7cf0 100644 } std::string externalizedDataPath = FileMan::joinPaths(extraDataDir, "externalized"); -@@ -428,6 +431,7 @@ try - else - #endif - { -+ SLOGD(TAG, "Starting %s:%d\n", __FILE__,__LINE__); - cm = new DefaultContentManager(version, - configFolderPath, - gameResRootPath, externalizedDataPath); @@ -775,7 +779,7 @@ static void WriteDefaultConfigFile(const char* ConfigFile) #ifdef _WIN32 fprintf(IniFile, "data_dir = C:\\Program Files\\Jagged Alliance 2"); @@ -320,197 +291,3 @@ index d156d73..66d7cf0 100644 #endif fclose(IniFile); fprintf(stderr, "Please edit \"%s\" to point to the binary data.\n", ConfigFile); -diff --git a/src/DefaultContentManager.cc b/src/DefaultContentManager.cc -index b7e4971..25bec4b 100644 ---- a/src/DefaultContentManager.cc -+++ b/src/DefaultContentManager.cc -@@ -602,8 +602,10 @@ const AmmoTypeModel* DefaultContentManager::getAmmoType(uint8_t index) - - bool DefaultContentManager::loadWeapons() - { -+ SLOGD(TAG, "%s:%d\n", __FILE__,__LINE__); - AutoSGPFile f(openGameResForReading("weapons.json")); - std::string jsonData = FileMan::fileReadText(f); -+ SLOGD(TAG, "%s:%d\n", __FILE__,__LINE__); - - rapidjson::Document document; - if (document.Parse<0>(jsonData.c_str()).HasParseError()) -@@ -613,6 +615,7 @@ bool DefaultContentManager::loadWeapons() - } - else - { -+ SLOGD(TAG, "%s:%d\n", __FILE__,__LINE__); - if(document.IsArray()) { - const rapidjson::Value& a = document; - for (rapidjson::SizeType i = 0; i < a.Size(); i++) -@@ -632,6 +635,7 @@ bool DefaultContentManager::loadWeapons() - } - } - } -+ SLOGD(TAG, "%s:%d\n", __FILE__,__LINE__); - - return true; - } -@@ -675,8 +679,11 @@ bool DefaultContentManager::loadMagazines() - - bool DefaultContentManager::loadCalibres() - { -+ SLOGD(TAG, "%s:%d\n", __FILE__,__LINE__); - AutoSGPFile f(openGameResForReading("calibres.json")); -+ SLOGD(TAG, "%s:%d\n", __FILE__,__LINE__); - std::string jsonData = FileMan::fileReadText(f); -+ SLOGD(TAG, "%s:%d\n", __FILE__,__LINE__); - - rapidjson::Document document; - if (document.Parse<0>(jsonData.c_str()).HasParseError()) -@@ -686,6 +693,7 @@ bool DefaultContentManager::loadCalibres() - } - else - { -+ SLOGD(TAG, "%s:%d\n", __FILE__,__LINE__); - if(document.IsArray()) { - const rapidjson::Value& a = document; - for (rapidjson::SizeType i = 0; i < a.Size(); i++) -@@ -703,19 +711,23 @@ bool DefaultContentManager::loadCalibres() - } - } - } -+ SLOGD(TAG, "%s:%d\n", __FILE__,__LINE__); - - BOOST_FOREACH(const CalibreModel* calibre, m_calibres) - { - m_calibreMap.insert(std::make_pair(std::string(calibre->internalName), calibre)); - } -+ SLOGD(TAG, "%s:%d\n", __FILE__,__LINE__); - - return true; - } - - bool DefaultContentManager::loadAmmoTypes() - { -+ SLOGD(TAG, "%s:%d\n", __FILE__,__LINE__); - AutoSGPFile f(openGameResForReading("ammo_types.json")); - std::string jsonData = FileMan::fileReadText(f); -+ SLOGD(TAG, "%s:%d\n", __FILE__,__LINE__); - - rapidjson::Document document; - if (document.Parse<0>(jsonData.c_str()).HasParseError()) -@@ -725,6 +737,7 @@ bool DefaultContentManager::loadAmmoTypes() - } - else - { -+ SLOGD(TAG, "%s:%d\n", __FILE__,__LINE__); - if(document.IsArray()) { - const rapidjson::Value& a = document; - for (rapidjson::SizeType i = 0; i < a.Size(); i++) -@@ -742,12 +755,14 @@ bool DefaultContentManager::loadAmmoTypes() - } - } - } -+ SLOGD(TAG, "%s:%d\n", __FILE__,__LINE__); - - BOOST_FOREACH(const AmmoTypeModel* ammoType, m_ammoTypes) - { - m_ammoTypeMap.insert(std::make_pair(std::string(ammoType->internalName), ammoType)); - } - -+ SLOGD(TAG, "%s:%d\n", __FILE__,__LINE__); - return true; - } - -@@ -755,8 +770,10 @@ bool DefaultContentManager::readWeaponTable( - const char *fileName, - std::vector > & weaponTable) - { -+ SLOGD(TAG, "%s:%d\n", __FILE__,__LINE__); - AutoSGPFile f(openGameResForReading(fileName)); - std::string jsonData = FileMan::fileReadText(f); -+ SLOGD(TAG, "%s:%d\n", __FILE__,__LINE__); - - rapidjson::Document document; - if (document.Parse<0>(jsonData.c_str()).HasParseError()) -@@ -764,6 +781,7 @@ bool DefaultContentManager::readWeaponTable( - SLOGE(TAG, "Failed to parse %s", fileName); - return false; - } -+ SLOGD(TAG, "%s:%d\n", __FILE__,__LINE__); - - if(document.IsArray()) - { -@@ -780,6 +798,7 @@ bool DefaultContentManager::readWeaponTable( - } - } - } -+ SLOGD(TAG, "%s:%d\n", __FILE__,__LINE__); - - return true; - } -@@ -796,12 +815,14 @@ const std::vector > & DefaultContentManager::get - - bool DefaultContentManager::loadArmyGunChoice() - { -+ SLOGD(TAG, "%s:%d\n", __FILE__,__LINE__); - return readWeaponTable("army-gun-choice-normal.json", mNormalGunChoice) - && readWeaponTable("army-gun-choice-extended.json", mExtendedGunChoice); - } - - void DefaultContentManager::loadStringRes(const char *name, std::vector &strings) const - { -+ SLOGD(TAG, "%s:%d\n", __FILE__,__LINE__); - std::string fullName(name); - - switch(m_gameVersion) -@@ -819,6 +840,7 @@ void DefaultContentManager::loadStringRes(const char *name, std::vector json(readJsonDataFile(fullName.c_str())); -@@ -828,12 +850,15 @@ void DefaultContentManager::loadStringRes(const char *name, std::vectorgetInternalName(), item)); - } -+ SLOGD(TAG, "%s:%d\n", __FILE__,__LINE__); - - loadAllDealersInventory(); -+ SLOGD(TAG, "%s:%d\n", __FILE__,__LINE__); - - boost::shared_ptr game_json(readJsonDataFile("game.json")); - m_gamePolicy = new DefaultGamePolicy(game_json.get()); -+ SLOGD(TAG, "%s:%d\n", __FILE__,__LINE__); - - boost::shared_ptr imp_json(readJsonDataFile("imp.json")); - m_impPolicy = new DefaultIMPPolicy(imp_json.get(), this); -+ SLOGD(TAG, "%s:%d\n", __FILE__,__LINE__); - - loadStringRes("strings/ammo-calibre", m_calibreNames); - loadStringRes("strings/ammo-calibre-bobbyray", m_calibreNamesBobbyRay); - - loadStringRes("strings/new-strings", m_newStrings); -+ SLOGD(TAG, "%s:%d\n", __FILE__,__LINE__); - - return result; - }