From 1bc05bed4de265f7c54601260b289a23fd853b1f Mon Sep 17 00:00:00 2001 From: goaaats Date: Sun, 11 Feb 2018 13:59:38 +0100 Subject: [PATCH 1/3] Update libraries --- bin/config/settings_lobby.xml | 2 -- bin/config/settings_rest.xml | 2 +- bin/config/settings_zone.xml | 2 +- src/libraries | 2 +- 4 files changed, 3 insertions(+), 5 deletions(-) diff --git a/bin/config/settings_lobby.xml b/bin/config/settings_lobby.xml index f41c6c7f..df2052ce 100644 --- a/bin/config/settings_lobby.xml +++ b/bin/config/settings_lobby.xml @@ -5,8 +5,6 @@ 54998 127.0.0.1 - - C:\\SquareEnix\\FINAL FANTASY XIV - A Realm Reborn\\game\\sqpack\\ffxiv 127.0.0.1 diff --git a/bin/config/settings_rest.xml b/bin/config/settings_rest.xml index ddadaf67..c0b84b7f 100644 --- a/bin/config/settings_rest.xml +++ b/bin/config/settings_rest.xml @@ -6,7 +6,7 @@ 127.0.0.1 - C:\\SquareEnix\\FINAL FANTASY XIV - A Realm Reborn\\game\\sqpack\\ffxiv + C:\\SquareEnix\\FINAL FANTASY XIV - A Realm Reborn\\game\\sqpack 127.0.0.1 diff --git a/bin/config/settings_zone.xml b/bin/config/settings_zone.xml index 547219a7..5282957a 100644 --- a/bin/config/settings_zone.xml +++ b/bin/config/settings_zone.xml @@ -5,7 +5,7 @@ 127.0.0.1 - C:\\SquareEnix\\FINAL FANTASY XIV - A Realm Reborn\\game\\sqpack\\ffxiv + C:\\SquareEnix\\FINAL FANTASY XIV - A Realm Reborn\\game\\sqpack diff --git a/src/libraries b/src/libraries index 978d3d2a..153f288d 160000 --- a/src/libraries +++ b/src/libraries @@ -1 +1 @@ -Subproject commit 978d3d2a336b97bb6ea0d95dc7000cbc1618a8cc +Subproject commit 153f288dc17bb5ff5ee2916e16871298aef4f482 From 15345d36d2d6720ec8b20dd43740544d87e78453 Mon Sep 17 00:00:00 2001 From: goaaats Date: Sun, 11 Feb 2018 16:50:31 +0100 Subject: [PATCH 2/3] Fix pcb_reader, quest_parser --- src/tools/pcb_reader/main.cpp | 24 ++++++++++-------------- src/tools/quest_parser/main.cpp | 6 +++--- 2 files changed, 13 insertions(+), 17 deletions(-) diff --git a/src/tools/pcb_reader/main.cpp b/src/tools/pcb_reader/main.cpp index 0a0a8ee3..7ab7ecf5 100644 --- a/src/tools/pcb_reader/main.cpp +++ b/src/tools/pcb_reader/main.cpp @@ -26,7 +26,7 @@ // garbage to ignore models bool ignoreModels = false; -std::string gamePath( "C:\\Program Files (x86)\\SquareEnix\\FINAL FANTASY XIV - A Realm Reborn\\game\\sqpack\\ffxiv" ); +std::string gamePath( "C:\\SquareEnix\\FINAL FANTASY XIV - A Realm Reborn\\game\\sqpack" ); std::unordered_map< uint32_t, std::string > eobjNameMap; std::unordered_map< uint16_t, std::string > zoneNameMap; std::unordered_map< uint16_t, std::vector< std::pair< uint16_t, std::string > > > zoneInstanceMap; @@ -335,7 +335,7 @@ int main( int argc, char* argv[] ) std::vector< std::string > argVec( argv + 1, argv + argc ); // todo: support expansions - std::string zoneName = "r1f1"; + std::string zoneName = "r2t2"; bool dumpInstances = ignoreModels = std::remove_if( argVec.begin(), argVec.end(), []( auto arg ){ return arg == "--instance-dump"; } ) != argVec.end(); if( argc > 1 ) @@ -366,12 +366,6 @@ LABEL_DUMP: { const auto& zonePath = zoneNameToPath( zoneName ); - if( zonePath.find( "ex1/" ) != std::string::npos || zonePath.find( "ex2" ) != std::string::npos ) - { - std::cout << "[Error] Expansions are currently not supported " << zonePath << "\n"; - goto LABEL_NEXT_ZONE_ENTRY; - } - std::string listPcbPath( zonePath + "/collision/list.pcb" ); std::string bgLgbPath( zonePath + "/level/bg.lgb" ); std::string planmapLgbPath( zonePath + "/level/planmap.lgb" ); @@ -381,15 +375,15 @@ LABEL_DUMP: std::vector< char > section2; #ifndef STANDALONE - const xiv::dat::Cat& test = data1->get_category( "bg" ); + const xiv::dat::Cat& test = data1->getCategory( "bg" ); - auto test_file = data1->get_file( bgLgbPath ); + auto test_file = data1->getFile( bgLgbPath ); section = test_file->access_data_sections().at( 0 ); - auto planmap_file = data1->get_file( planmapLgbPath ); + auto planmap_file = data1->getFile( planmapLgbPath ); section2 = planmap_file->access_data_sections().at( 0 ); - auto test_file1 = data1->get_file( listPcbPath ); + auto test_file1 = data1->getFile( listPcbPath ); section1 = test_file1->access_data_sections().at( 0 ); #else { @@ -475,7 +469,7 @@ LABEL_DUMP: char* dataSection = nullptr; //std::cout << fileName << " "; #ifndef STANDALONE - auto file = data1->get_file( fileName ); + auto file = data1->getFile( fileName ); auto sections = file->get_data_sections(); dataSection = §ions.at( 0 )[0]; #else @@ -527,7 +521,7 @@ LABEL_DUMP: char* dataSection = nullptr; //std::cout << fileName << " "; #ifndef STANDALONE - auto file = data1->get_file( fileName ); + auto file = data1->getFile( fileName ); auto sections = file->get_data_sections(); dataSection = §ions.at( 0 )[0]; #else @@ -743,6 +737,8 @@ LABEL_DUMP: std::cout << "\n\n\n[Success] Finished all tasks in " << std::chrono::duration_cast< std::chrono::seconds >( std::chrono::system_clock::now() - startTime ).count() << " seconds\n"; + getchar(); + if( eData ) delete eData; if( data1 ) diff --git a/src/tools/quest_parser/main.cpp b/src/tools/quest_parser/main.cpp index 4a5e0f50..e4f14145 100644 --- a/src/tools/quest_parser/main.cpp +++ b/src/tools/quest_parser/main.cpp @@ -299,7 +299,7 @@ int main( int argc, char** argv ) bool unluac = false; // std::string datLocation( "/opt/sapphire_3_15_0/bin/sqpack" ); - std::string datLocation( "C:/Program Files (x86)/SquareEnix/FINAL FANTASY XIV - A Realm Reborn/game/sqpack/ffxiv" ); + std::string datLocation( "C:/Program Files (x86)/SquareEnix/FINAL FANTASY XIV - A Realm Reborn/game/sqpack" ); if ( argc > 1 ) datLocation = std::string( argv[1] ); if ( argc > 2 ) @@ -350,11 +350,11 @@ int main( int argc, char** argv ) - const xiv::dat::Cat& test = data.get_category( "game_script" ); + const xiv::dat::Cat& test = data.getCategory( "game_script" ); const std::string questPath = "game_script/quest/" + folder + "/" + questInfo->name_intern + ".luab"; - const auto &test_file = data.get_file( questPath ); + const auto &test_file = data.getFile( questPath ); auto §ion = test_file->access_data_sections().at( 0 ); int32_t size = *( uint32_t* ) §ion[4]; From 56f20a735cc0a6a637b3d54fed324300c5c1696e Mon Sep 17 00:00:00 2001 From: goaaats Date: Sun, 11 Feb 2018 17:20:54 +0100 Subject: [PATCH 3/3] Update submodule again --- src/libraries | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libraries b/src/libraries index 153f288d..699d413f 160000 --- a/src/libraries +++ b/src/libraries @@ -1 +1 @@ -Subproject commit 153f288dc17bb5ff5ee2916e16871298aef4f482 +Subproject commit 699d413f17c5e52a764120edcdf09b3f4d330522