diff --git a/.gitignore b/.gitignore index c931620b..00f3f1c8 100644 --- a/.gitignore +++ b/.gitignore @@ -113,4 +113,4 @@ src/common/Version\.cpp .mtime_cache # generated script loader files -scripts/native/*/ScriptLoader.cpp \ No newline at end of file +src/servers/sapphire_zone/Script/Scripts/*/ScriptLoader.cpp \ No newline at end of file diff --git a/CMakeLists.txt b/CMakeLists.txt index b30cf137..ca7af689 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -67,6 +67,4 @@ add_subdirectory("src/tools/exd_common_gen") add_subdirectory("src/tools/exd_struct_gen") add_subdirectory("src/tools/exd_struct_test") add_subdirectory("src/tools/quest_parser") -add_subdirectory("src/tools/pcb_reader") - -add_subdirectory("scripts/native") +#add_subdirectory("src/tools/pcb_reader") diff --git a/bin/config/settings_zone.xml b/bin/config/settings_zone.xml index f50c18ce..547219a7 100644 --- a/bin/config/settings_zone.xml +++ b/bin/config/settings_zone.xml @@ -13,7 +13,7 @@ ./cache/ - 1 + true ../scripts/native/ ../cmake-build-debug/ cmake --build %1% --target %2% diff --git a/sql/update.sql b/sql/update.sql index dee39387..38c3fe04 100644 --- a/sql/update.sql +++ b/sql/update.sql @@ -43,6 +43,7 @@ MODIFY COLUMN UPDATE_DATE DATETIME NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURR ALTER TABLE charainfo ADD `Orchestrion` binary(38) DEFAULT NULL AFTER `Mounts`; -ALTER TABLE `charainfo` CHANGE `Mounts` `Mounts` BINARY(14) NULL DEFAULT NULL; +ALTER TABLE `charainfo` CHANGE `Mounts` `Mounts` BINARY(15) NULL DEFAULT NULL; ALTER TABLE `charainfo` CHANGE `Orchestrion` `Orchestrion` BINARY(40) NULL DEFAULT NULL; -ALTER TABLE `charainfo` CHANGE `Minions` `Minions` BINARY(35) NULL DEFAULT NULL; +ALTER TABLE `charainfo` CHANGE `Minions` `Minions` BINARY(37) NULL DEFAULT NULL; +ALTER TABLE `charainfo` CHANGE `QuestCompleteFlags` `QuestCompleteFlags` VARBINARY(396) NULL DEFAULT NULL; diff --git a/src/common/CMakeLists.txt b/src/common/CMakeLists.txt index 7d9fd527..606f027b 100644 --- a/src/common/CMakeLists.txt +++ b/src/common/CMakeLists.txt @@ -5,7 +5,8 @@ include_directories( ${CMAKE_CURRENT_SOURCE_DIR} ) file(GLOB UTILS_PUBLIC_INCLUDE_FILES "${CMAKE_CURRENT_SOURCE_DIR}" - "${CMAKE_CURRENT_SOURCE_DIR}/*.h") + "${CMAKE_CURRENT_SOURCE_DIR}/*.h" + "${CMAKE_CURRENT_SOURCE_DIR}/Exd/*.h" ) file(GLOB UTILS_SOURCE_FILES "${CMAKE_CURRENT_SOURCE_DIR}/*.cpp" "${CMAKE_CURRENT_SOURCE_DIR}/Config/*.cpp" diff --git a/src/common/Database/DbConnection.cpp b/src/common/Database/DbConnection.cpp index b0633492..b33fbbd2 100644 --- a/src/common/Database/DbConnection.cpp +++ b/src/common/Database/DbConnection.cpp @@ -61,7 +61,7 @@ uint32_t Core::Db::DbConnection::open() try { m_pConnection = base->connect( m_connectionInfo.host, m_connectionInfo.user, m_connectionInfo.password, - options, m_connectionInfo.port ); + options, m_connectionInfo.port ); m_pConnection->setSchema( m_connectionInfo.database ); } @@ -79,9 +79,9 @@ uint32_t Core::Db::DbConnection::getLastError() return m_pConnection->getErrorNo(); } -void Core::Db::DbConnection::ping() +bool Core::Db::DbConnection::ping() { - m_pConnection->ping(); + return m_pConnection->ping(); } bool Core::Db::DbConnection::lockIfReady() @@ -146,6 +146,17 @@ boost::shared_ptr< Mysql::ResultSet > Core::Db::DbConnection::query( boost::shar if( !stmt ) return nullptr; + if( !ping() ) + { + g_log.error( "MysqlConnection went down" ); + // naivly reconnect and hope for the best + open(); + lockIfReady(); + if( !prepareStatements() ) + g_log.error( "Mysql Statements failed to prepare..." ); + g_log.info( "MysqlConnection reestablished" ); + } + uint32_t index = stmt->getIndex(); auto pStmt = getPreparedStatement( index ); diff --git a/src/common/Database/DbConnection.h b/src/common/Database/DbConnection.h index ddb66e17..f304e423 100644 --- a/src/common/Database/DbConnection.h +++ b/src/common/Database/DbConnection.h @@ -72,7 +72,7 @@ namespace Db void rollbackTransaction(); void commitTransaction(); - void ping(); + bool ping(); uint32_t getLastError(); bool lockIfReady(); diff --git a/src/common/Exd/ExdData.cpp b/src/common/Exd/ExdData.cpp index 9ac2197a..4a455f94 100644 --- a/src/common/Exd/ExdData.cpp +++ b/src/common/Exd/ExdData.cpp @@ -85,10 +85,11 @@ bool Core::Data::ExdData::loadZoneInfo() int16_t map_index = getField< int16_t >( mapDataFields, 12 ); bool is_two_bytes = getField< bool >( mapDataFields, 15 ); - uint16_t weather_rate = getField< uint16_t >( fields, 10 ) > 75 ? 0 : getField< uint16_t >( fields, 10 ); + uint8_t weather_rate = getField< uint8_t >( fields, 12 ) > 75 ? 0 : getField< uint8_t >( fields, 12 ); auto weatherRateFields = weatherRate.get_row( weather_rate ); int32_t aetheryte_index = getField< int32_t >( fields, 23 ); + uint8_t zoneType = getField< uint8_t >( fields, 9 ); ZoneInfo info{ 0 }; @@ -101,6 +102,8 @@ bool Core::Data::ExdData::loadZoneInfo() info.map_id = map_id; info.weather_rate = weather_rate; // TODO: deal with weather groups info.aetheryte_index = aetheryte_index; + info.zone_type = zoneType; + uint8_t sumPc = 0; for( size_t i = 0; i < 16; ) @@ -338,34 +341,34 @@ bool Core::Data::ExdData::loadActionInfo() int8_t class_job = getField< int8_t >( fields, 10 ); // 10 uint8_t unlock_level = getField< uint8_t >( fields, 11 ); // 11 - int8_t range = getField< int8_t >( fields, 13 ); // 13 - bool can_target_self = getField< bool >( fields, 14 ); // 14 - bool can_target_party = getField< bool>( fields, 15 ); // 15 - bool can_target_friendly = getField< bool >( fields, 16 ); // 16 - bool can_target_enemy = getField< bool >( fields, 17 ); // 17 + int8_t range = getField< int8_t >( fields, 14 ); // 13 + bool can_target_self = getField< bool >( fields, 15 ); // 14 + bool can_target_party = getField< bool>( fields, 16 ); // 15 + bool can_target_friendly = getField< bool >( fields, 17 ); // 16 + bool can_target_enemy = getField< bool >( fields, 18 ); // 17 - bool is_ground_aoe = getField< bool >( fields, 20 ); // 20 + bool is_ground_aoe = getField< bool >( fields, 21 ); // 20 // Column 23: Seems to be related to raising skills (Raise, Resurrection, Reanimate) - bool can_target_ko = getField< bool >( fields, 24 ); // 24 + bool can_target_ko = getField< bool >( fields, 25 ); // 24 - uint8_t aoe_type = getField< uint8_t >( fields, 26 ); // 26 - uint8_t aoe_range = getField< uint8_t >( fields, 27 ); // 27 - uint8_t aoe_width = getField< uint8_t >( fields, 28 ); // 28 + uint8_t aoe_type = getField< uint8_t >( fields, 27 ); // 26 + uint8_t aoe_range = getField< uint8_t >( fields, 28 ); // 27 + uint8_t aoe_width = getField< uint8_t >( fields, 29 ); // 28 - uint8_t points_type = getField< uint8_t >( fields, 30 ); // 30 - uint16_t points_cost = getField< uint16_t >( fields, 31 ); // 31 + uint8_t points_type = getField< uint8_t >( fields, 31 ); // 30 + uint16_t points_cost = getField< uint16_t >( fields, 32 ); // 31 - bool is_instant = getField< bool >( fields, 35 ); // 35 - uint16_t cast_time = getField< uint16_t >( fields, 36 ); // 36 - uint16_t recast_time = getField< uint16_t >( fields, 37 ); // 37 + bool is_instant = getField< bool >( fields, 36 ); // 35 + uint16_t cast_time = getField< uint16_t >( fields, 37 ); // 36 + uint16_t recast_time = getField< uint16_t >( fields, 38 ); // 37 - int8_t model = getField< int8_t >( fields, 39 ); // 39 - uint8_t aspect = getField< uint8_t >( fields, 40 ); // 40 + int8_t model = getField< int8_t >( fields, 40 ); // 39 + uint8_t aspect = getField< uint8_t >( fields, 41 ); // 40 - uint16_t toggle_status_id = getField< uint16_t >( fields, 42 ); // 42 - bool affects_position = getField< bool >( fields, 47 ); // 47 + uint16_t toggle_status_id = getField< uint16_t >( fields, 43 ); // 42 + bool affects_position = getField< bool >( fields, 48 ); // 47 - bool no_effect_in_battle = getField< bool >( fields, 60 ); // 60 + bool no_effect_in_battle = getField< bool >( fields, 61 ); // 60 info->id = id; diff --git a/src/common/Exd/ExdData.h b/src/common/Exd/ExdData.h index 3a5dedf9..d17bffb8 100644 --- a/src/common/Exd/ExdData.h +++ b/src/common/Exd/ExdData.h @@ -37,6 +37,7 @@ namespace Core { std::map< uint8_t, int32_t> weather_rate_map; int32_t aetheryte_index; + uint8_t zone_type; }; struct ClassJobInfo diff --git a/src/tools/exd_struct_test/ExdDataGenerated.cpp b/src/common/Exd/ExdDataGenerated.cpp similarity index 92% rename from src/tools/exd_struct_test/ExdDataGenerated.cpp rename to src/common/Exd/ExdDataGenerated.cpp index f8d711b8..a35c11a4 100644 --- a/src/tools/exd_struct_test/ExdDataGenerated.cpp +++ b/src/common/Exd/ExdDataGenerated.cpp @@ -50,34 +50,34 @@ actionTimelineUse = exdData->getField< int16_t >( row, 7 ); actionTimelineHit = exdData->getField< uint16_t >( row, 8 ); classJob = exdData->getField< int8_t >( row, 10 ); - classJobLevel = exdData->getField< uint8_t >( row, 11 ); - isRoleAction = exdData->getField< bool >( row, 12 ); - range = exdData->getField< int8_t >( row, 13 ); - canTargetSelf = exdData->getField< bool >( row, 14 ); - canTargetParty = exdData->getField< bool >( row, 15 ); - canTargetFriendly = exdData->getField< bool >( row, 16 ); - canTargetHostile = exdData->getField< bool >( row, 17 ); - targetArea = exdData->getField< bool >( row, 20 ); - canTargetDead = exdData->getField< bool >( row, 24 ); - castType = exdData->getField< uint8_t >( row, 26 ); - effectRange = exdData->getField< uint8_t >( row, 27 ); - xAxisModifier = exdData->getField< uint8_t >( row, 28 ); - costType = exdData->getField< uint8_t >( row, 30 ); - cost = exdData->getField< uint16_t >( row, 31 ); - actionCombo = exdData->getField< uint16_t >( row, 34 ); - preservesCombo = exdData->getField< bool >( row, 35 ); - cast100ms = exdData->getField< uint16_t >( row, 36 ); - recast100ms = exdData->getField< uint16_t >( row, 37 ); - cooldownGroup = exdData->getField< uint8_t >( row, 38 ); - attackType = exdData->getField< int8_t >( row, 39 ); - aspect = exdData->getField< uint8_t >( row, 40 ); - actionProcStatus = exdData->getField< uint8_t >( row, 41 ); - statusGainSelf = exdData->getField< uint16_t >( row, 42 ); - actionData = exdData->getField< uint32_t >( row, 43 ); - classJobCategory = exdData->getField< uint8_t >( row, 44 ); - affectsPosition = exdData->getField< bool >( row, 47 ); - omen = exdData->getField< uint8_t >( row, 48 ); - isPvP = exdData->getField< bool >( row, 49 ); + classJobLevel = exdData->getField< uint8_t >( row, 12 ); + isRoleAction = exdData->getField< bool >( row, 13 ); + range = exdData->getField< int8_t >( row, 14 ); + canTargetSelf = exdData->getField< bool >( row, 15 ); + canTargetParty = exdData->getField< bool >( row, 16 ); + canTargetFriendly = exdData->getField< bool >( row, 17 ); + canTargetHostile = exdData->getField< bool >( row, 18 ); + targetArea = exdData->getField< bool >( row, 21 ); + canTargetDead = exdData->getField< bool >( row, 25 ); + castType = exdData->getField< uint8_t >( row, 27 ); + effectRange = exdData->getField< uint8_t >( row, 28 ); + xAxisModifier = exdData->getField< uint8_t >( row, 29 ); + costType = exdData->getField< uint8_t >( row, 31 ); + cost = exdData->getField< uint16_t >( row, 32 ); + actionCombo = exdData->getField< uint16_t >( row, 35 ); + preservesCombo = exdData->getField< bool >( row, 36 ); + cast100ms = exdData->getField< uint16_t >( row, 37 ); + recast100ms = exdData->getField< uint16_t >( row, 38 ); + cooldownGroup = exdData->getField< uint8_t >( row, 39 ); + attackType = exdData->getField< int8_t >( row, 40 ); + aspect = exdData->getField< uint8_t >( row, 41 ); + actionProcStatus = exdData->getField< uint8_t >( row, 42 ); + statusGainSelf = exdData->getField< uint16_t >( row, 43 ); + actionData = exdData->getField< uint32_t >( row, 44 ); + classJobCategory = exdData->getField< uint8_t >( row, 45 ); + affectsPosition = exdData->getField< bool >( row, 48 ); + omen = exdData->getField< uint8_t >( row, 49 ); + isPvP = exdData->getField< bool >( row, 50 ); } Core::Data::ActionCategory::ActionCategory( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ) @@ -172,6 +172,7 @@ placeName = exdData->getField< uint16_t >( row, 8 ); aethernetName = exdData->getField< uint16_t >( row, 9 ); territory = exdData->getField< uint16_t >( row, 10 ); + destination = exdData->getField< uint32_t >( row, 11 ); isAetheryte = exdData->getField< bool >( row, 15 ); aethernetGroup = exdData->getField< uint8_t >( row, 16 ); map = exdData->getField< uint16_t >( row, 19 ); @@ -415,8 +416,8 @@ beastRankBonus = exdData->getField< uint8_t >( row, 2 ); iconReputation = exdData->getField< uint32_t >( row, 3 ); icon = exdData->getField< uint32_t >( row, 4 ); - name = exdData->getField< std::string >( row, 11 ); - nameRelation = exdData->getField< std::string >( row, 19 ); + name = exdData->getField< std::string >( row, 10 ); + nameRelation = exdData->getField< std::string >( row, 18 ); } Core::Data::Behavior::Behavior( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ) @@ -612,13 +613,6 @@ day.push_back( exdData->getField< uint8_t >( row, 63 ) ); } - Core::Data::ChainBonus::ChainBonus( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ) - { - auto row = exdData->m_ChainBonusDat.get_row( row_id ); - bonus = exdData->getField< uint8_t >( row, 0 ); - timeouts = exdData->getField< uint8_t >( row, 1 ); - } - Core::Data::CharaMakeCustomize::CharaMakeCustomize( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ) { auto row = exdData->m_CharaMakeCustomizeDat.get_row( row_id ); @@ -742,7 +736,9 @@ name = exdData->getField< std::string >( row, 0 ); abbreviation = exdData->getField< std::string >( row, 1 ); classJobCategory = exdData->getField< uint8_t >( row, 3 ); + expArrayIndex = exdData->getField< int8_t >( row, 4 ); modifierHitPoints = exdData->getField< uint16_t >( row, 9 ); + modifierManaPoints = exdData->getField< uint16_t >( row, 10 ); modifierStrength = exdData->getField< uint16_t >( row, 11 ); modifierVitality = exdData->getField< uint16_t >( row, 12 ); modifierDexterity = exdData->getField< uint16_t >( row, 13 ); @@ -960,12 +956,14 @@ Core::Data::ContentFinderCondition::ContentFinderCondition( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ) { auto row = exdData->m_ContentFinderConditionDat.get_row( row_id ); - contentIndicator = exdData->getField< uint8_t >( row, 0 ); - instanceContent = exdData->getField< uint16_t >( row, 1 ); - contentMemberType = exdData->getField< uint8_t >( row, 5 ); - classJobLevel = exdData->getField< uint8_t >( row, 8 ); - itemLevelRequired = exdData->getField< uint16_t >( row, 10 ); - icon = exdData->getField< uint32_t >( row, 29 ); + contentIndicator = exdData->getField< uint8_t >( row, 1 ); + instanceContent = exdData->getField< uint16_t >( row, 2 ); + contentMemberType = exdData->getField< uint8_t >( row, 7 ); + classJobLevelRequired = exdData->getField< uint8_t >( row, 13 ); + classJobLevelSync = exdData->getField< uint8_t >( row, 14 ); + itemLevelRequired = exdData->getField< uint16_t >( row, 15 ); + itemLevelSync = exdData->getField< uint16_t >( row, 16 ); + icon = exdData->getField< uint32_t >( row, 36 ); } Core::Data::ContentFinderConditionTransient::ContentFinderConditionTransient( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ) @@ -989,15 +987,15 @@ name = exdData->getField< std::string >( row, 0 ); description = exdData->getField< std::string >( row, 2 ); dutyType = exdData->getField< std::string >( row, 3 ); - isInDutyFinder = exdData->getField< bool >( row, 5 ); - requireAllDuties = exdData->getField< bool >( row, 6 ); - itemLevelRequired = exdData->getField< uint16_t >( row, 9 ); - icon = exdData->getField< uint32_t >( row, 11 ); - rewardTomeA = exdData->getField< uint16_t >( row, 13 ); - rewardTomeB = exdData->getField< uint16_t >( row, 14 ); - rewardTomeC = exdData->getField< uint16_t >( row, 15 ); - sortKey = exdData->getField< uint8_t >( row, 18 ); - contentMemberType = exdData->getField< uint8_t >( row, 20 ); + isInDutyFinder = exdData->getField< bool >( row, 6 ); + itemLevelRequired = exdData->getField< uint16_t >( row, 10 ); + icon = exdData->getField< uint32_t >( row, 12 ); + rewardTomeA = exdData->getField< uint16_t >( row, 14 ); + rewardTomeB = exdData->getField< uint16_t >( row, 15 ); + rewardTomeC = exdData->getField< uint16_t >( row, 16 ); + sortKey = exdData->getField< uint8_t >( row, 19 ); + contentMemberType = exdData->getField< uint8_t >( row, 21 ); + requireAllDuties = exdData->getField< bool >( row, 31 ); } Core::Data::ContentType::ContentType( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ) @@ -1434,6 +1432,7 @@ auto row = exdData->m_EventActionDat.get_row( row_id ); name = exdData->getField< std::string >( row, 0 ); icon = exdData->getField< uint16_t >( row, 1 ); + castTime = exdData->getField< uint8_t >( row, 2 ); } Core::Data::EventIconPriority::EventIconPriority( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ) @@ -1477,6 +1476,7 @@ icon = exdData->getField< uint16_t >( row, 10 ); stackSize = exdData->getField< uint8_t >( row, 12 ); quest = exdData->getField< uint32_t >( row, 14 ); + castTime = exdData->getField< uint8_t >( row, 15 ); } Core::Data::EventItemHelp::EventItemHelp( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ) @@ -1494,23 +1494,30 @@ Core::Data::Fate::Fate( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ) { auto row = exdData->m_FateDat.get_row( row_id ); - classJobLevel = exdData->getField< uint8_t >( row, 2 ); - classJobLevelMax = exdData->getField< uint8_t >( row, 3 ); - eventItem = exdData->getField< uint32_t >( row, 4 ); - iconObjective = exdData->getField< uint32_t >( row, 9 ); - iconMap = exdData->getField< uint32_t >( row, 10 ); - name = exdData->getField< std::string >( row, 26 ); - description = exdData->getField< std::string >( row, 27 ); - objective = exdData->getField< std::string >( row, 28 ); - statusText.push_back( exdData->getField< std::string >( row, 29 ) ); + classJobLevel = exdData->getField< uint8_t >( row, 3 ); + classJobLevelMax = exdData->getField< uint8_t >( row, 4 ); + eventItem = exdData->getField< uint32_t >( row, 5 ); + iconObjective = exdData->getField< uint32_t >( row, 10 ); + iconMap = exdData->getField< uint32_t >( row, 11 ); + name = exdData->getField< std::string >( row, 27 ); + description = exdData->getField< std::string >( row, 28 ); + objective = exdData->getField< std::string >( row, 29 ); statusText.push_back( exdData->getField< std::string >( row, 30 ) ); statusText.push_back( exdData->getField< std::string >( row, 31 ) ); + statusText.push_back( exdData->getField< std::string >( row, 32 ) ); } Core::Data::FCActivity::FCActivity( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ) { auto row = exdData->m_FCActivityDat.get_row( row_id ); text = exdData->getField< std::string >( row, 0 ); + fCActivityCategory = exdData->getField< uint8_t >( row, 4 ); + } + + Core::Data::FCActivityCategory::FCActivityCategory( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ) + { + auto row = exdData->m_FCActivityCategoryDat.get_row( row_id ); + name = exdData->getField< std::string >( row, 1 ); } Core::Data::FCAuthority::FCAuthority( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ) @@ -1544,6 +1551,12 @@ name = exdData->getField< std::string >( row, 0 ); } + Core::Data::FCProfile::FCProfile( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ) + { + auto row = exdData->m_FCProfileDat.get_row( row_id ); + name = exdData->getField< std::string >( row, 1 ); + } + Core::Data::FCReputation::FCReputation( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ) { auto row = exdData->m_FCReputationDat.get_row( row_id ); @@ -1850,6 +1863,54 @@ description = exdData->getField< std::string >( row, 5 ); } + Core::Data::GCRankGridaniaFemaleText::GCRankGridaniaFemaleText( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ) + { + auto row = exdData->m_GCRankGridaniaFemaleTextDat.get_row( row_id ); + name = exdData->getField< std::string >( row, 0 ); + plural = exdData->getField< std::string >( row, 2 ); + nameRank = exdData->getField< std::string >( row, 8 ); + } + + Core::Data::GCRankGridaniaMaleText::GCRankGridaniaMaleText( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ) + { + auto row = exdData->m_GCRankGridaniaMaleTextDat.get_row( row_id ); + name = exdData->getField< std::string >( row, 0 ); + plural = exdData->getField< std::string >( row, 2 ); + nameRank = exdData->getField< std::string >( row, 8 ); + } + + Core::Data::GCRankLimsaFemaleText::GCRankLimsaFemaleText( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ) + { + auto row = exdData->m_GCRankLimsaFemaleTextDat.get_row( row_id ); + name = exdData->getField< std::string >( row, 0 ); + plural = exdData->getField< std::string >( row, 2 ); + nameRank = exdData->getField< std::string >( row, 8 ); + } + + Core::Data::GCRankLimsaMaleText::GCRankLimsaMaleText( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ) + { + auto row = exdData->m_GCRankLimsaMaleTextDat.get_row( row_id ); + name = exdData->getField< std::string >( row, 0 ); + plural = exdData->getField< std::string >( row, 2 ); + nameRank = exdData->getField< std::string >( row, 8 ); + } + + Core::Data::GCRankUldahFemaleText::GCRankUldahFemaleText( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ) + { + auto row = exdData->m_GCRankUldahFemaleTextDat.get_row( row_id ); + name = exdData->getField< std::string >( row, 0 ); + plural = exdData->getField< std::string >( row, 2 ); + nameRank = exdData->getField< std::string >( row, 8 ); + } + + Core::Data::GCRankUldahMaleText::GCRankUldahMaleText( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ) + { + auto row = exdData->m_GCRankUldahMaleTextDat.get_row( row_id ); + name = exdData->getField< std::string >( row, 0 ); + plural = exdData->getField< std::string >( row, 2 ); + nameRank = exdData->getField< std::string >( row, 8 ); + } + Core::Data::GCScripShopCategory::GCScripShopCategory( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ) { auto row = exdData->m_GCScripShopCategoryDat.get_row( row_id ); @@ -2004,25 +2065,22 @@ instanceContentType = exdData->getField< uint8_t >( row, 0 ); weekRestriction = exdData->getField< uint8_t >( row, 1 ); timeLimitmin = exdData->getField< uint16_t >( row, 2 ); - classJobLevelSync = exdData->getField< uint8_t >( row, 3 ); - name = exdData->getField< std::string >( row, 4 ); - bGM = exdData->getField< uint16_t >( row, 6 ); - itemLevelSync = exdData->getField< uint16_t >( row, 9 ); - territoryType = exdData->getField< uint32_t >( row, 11 ); - icon = exdData->getField< uint32_t >( row, 13 ); - instanceContentTextDataBossStart = exdData->getField< uint32_t >( row, 15 ); - instanceContentTextDataBossEnd = exdData->getField< uint32_t >( row, 16 ); - bNpcBaseBoss = exdData->getField< uint32_t >( row, 17 ); - instanceContentTextDataObjectiveStart = exdData->getField< uint32_t >( row, 18 ); - instanceContentTextDataObjectiveEnd = exdData->getField< uint32_t >( row, 19 ); - sortKey = exdData->getField< uint16_t >( row, 20 ); - newPlayerBonusA = exdData->getField< uint16_t >( row, 23 ); - newPlayerBonusB = exdData->getField< uint16_t >( row, 24 ); - finalBossCurrencyA = exdData->getField< uint16_t >( row, 26 ); - finalBossCurrencyB = exdData->getField< uint16_t >( row, 27 ); - finalBossCurrencyC = exdData->getField< uint16_t >( row, 28 ); - instanceContentBuff = exdData->getField< int32_t >( row, 54 ); - partyCondition = exdData->getField< uint8_t >( row, 58 ); + name = exdData->getField< std::string >( row, 3 ); + bGM = exdData->getField< uint16_t >( row, 5 ); + territoryType = exdData->getField< uint32_t >( row, 9 ); + instanceContentTextDataBossStart = exdData->getField< uint32_t >( row, 13 ); + instanceContentTextDataBossEnd = exdData->getField< uint32_t >( row, 14 ); + bNpcBaseBoss = exdData->getField< uint32_t >( row, 15 ); + instanceContentTextDataObjectiveStart = exdData->getField< uint32_t >( row, 16 ); + instanceContentTextDataObjectiveEnd = exdData->getField< uint32_t >( row, 17 ); + sortKey = exdData->getField< uint16_t >( row, 18 ); + newPlayerBonusA = exdData->getField< uint16_t >( row, 21 ); + newPlayerBonusB = exdData->getField< uint16_t >( row, 22 ); + finalBossCurrencyA = exdData->getField< uint16_t >( row, 24 ); + finalBossCurrencyB = exdData->getField< uint16_t >( row, 25 ); + finalBossCurrencyC = exdData->getField< uint16_t >( row, 26 ); + instanceContentBuff = exdData->getField< int32_t >( row, 52 ); + partyCondition = exdData->getField< uint8_t >( row, 56 ); } Core::Data::InstanceContentBuff::InstanceContentBuff( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ) @@ -2195,7 +2253,6 @@ placeNameStart = exdData->getField< int32_t >( row, 9 ); placeNameIssued = exdData->getField< int32_t >( row, 10 ); classJobCategory = exdData->getField< uint8_t >( row, 12 ); - journalCategory = exdData->getField< int32_t >( row, 13 ); placeNameStartZone = exdData->getField< int32_t >( row, 15 ); iconCityState = exdData->getField< int32_t >( row, 16 ); dataId = exdData->getField< int32_t >( row, 17 ); @@ -2235,6 +2292,7 @@ type = exdData->getField< uint8_t >( row, 5 ); objectKey = exdData->getField< uint32_t >( row, 6 ); map = exdData->getField< uint16_t >( row, 7 ); + eventId = exdData->getField< uint32_t >( row, 8 ); territory = exdData->getField< uint16_t >( row, 9 ); } @@ -2325,7 +2383,9 @@ placeNameRegion = exdData->getField< uint16_t >( row, 9 ); placeName = exdData->getField< uint16_t >( row, 10 ); placeNameSub = exdData->getField< uint16_t >( row, 11 ); + discoveryIndex = exdData->getField< int16_t >( row, 12 ); territoryType = exdData->getField< uint16_t >( row, 14 ); + discoveryArrayByte = exdData->getField< bool >( row, 15 ); } Core::Data::MapMarker::MapMarker( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ) @@ -2458,8 +2518,8 @@ plural = exdData->getField< std::string >( row, 2 ); flyingCondition = exdData->getField< uint8_t >( row, 10 ); isFlying = exdData->getField< uint8_t >( row, 14 ); - rideBGM = exdData->getField< uint16_t >( row, 28 ); - icon = exdData->getField< uint16_t >( row, 41 ); + rideBGM = exdData->getField< uint16_t >( row, 17 ); + icon = exdData->getField< uint16_t >( row, 30 ); } Core::Data::MountAction::MountAction( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ) @@ -2512,8 +2572,14 @@ Core::Data::OnlineStatus::OnlineStatus( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ) { auto row = exdData->m_OnlineStatusDat.get_row( row_id ); - name = exdData->getField< std::string >( row, 2 ); - icon = exdData->getField< uint32_t >( row, 3 ); + name = exdData->getField< std::string >( row, 3 ); + icon = exdData->getField< uint32_t >( row, 4 ); + } + + Core::Data::Opening::Opening( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ) + { + auto row = exdData->m_OpeningDat.get_row( row_id ); + name = exdData->getField< std::string >( row, 0 ); } Core::Data::Orchestrion::Orchestrion( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ) @@ -3532,6 +3598,7 @@ placeNameZone = exdData->getField< uint16_t >( row, 4 ); placeName = exdData->getField< uint16_t >( row, 5 ); map = exdData->getField< uint16_t >( row, 6 ); + territoryIntendedUse = exdData->getField< uint8_t >( row, 9 ); weatherRate = exdData->getField< uint8_t >( row, 12 ); aetheryte = exdData->getField< int32_t >( row, 23 ); } @@ -3646,6 +3713,10 @@ defaultTalkNPCWin = exdData->getField< uint32_t >( row, 22 ); defaultTalkDraw = exdData->getField< uint32_t >( row, 23 ); defaultTalkPCWin = exdData->getField< uint32_t >( row, 24 ); + itemPossibleReward.push_back( exdData->getField< uint32_t >( row, 26 ) ); + itemPossibleReward.push_back( exdData->getField< uint32_t >( row, 27 ) ); + itemPossibleReward.push_back( exdData->getField< uint32_t >( row, 28 ) ); + itemPossibleReward.push_back( exdData->getField< uint32_t >( row, 29 ) ); } Core::Data::TripleTriadCard::TripleTriadCard( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ) @@ -3869,7 +3940,6 @@ bool Core::Data::ExdDataGenerated::init( const std::string& path ) m_CabinetDat = setupDatAccess( "Cabinet", xiv::exd::Language::none ); m_CabinetCategoryDat = setupDatAccess( "CabinetCategory", xiv::exd::Language::none ); m_CalendarDat = setupDatAccess( "Calendar", xiv::exd::Language::none ); - m_ChainBonusDat = setupDatAccess( "ChainBonus", xiv::exd::Language::none ); m_CharaMakeCustomizeDat = setupDatAccess( "CharaMakeCustomize", xiv::exd::Language::none ); m_CharaMakeTypeDat = setupDatAccess( "CharaMakeType", xiv::exd::Language::en ); m_ChocoboRaceDat = setupDatAccess( "ChocoboRace", xiv::exd::Language::none ); @@ -3939,11 +4009,13 @@ bool Core::Data::ExdDataGenerated::init( const std::string& path ) m_ExVersionDat = setupDatAccess( "ExVersion", xiv::exd::Language::en ); m_FateDat = setupDatAccess( "Fate", xiv::exd::Language::en ); m_FCActivityDat = setupDatAccess( "FCActivity", xiv::exd::Language::en ); + m_FCActivityCategoryDat = setupDatAccess( "FCActivityCategory", xiv::exd::Language::en ); m_FCAuthorityDat = setupDatAccess( "FCAuthority", xiv::exd::Language::en ); m_FCAuthorityCategoryDat = setupDatAccess( "FCAuthorityCategory", xiv::exd::Language::en ); m_FCChestNameDat = setupDatAccess( "FCChestName", xiv::exd::Language::en ); m_FccShopDat = setupDatAccess( "FccShop", xiv::exd::Language::en ); m_FCHierarchyDat = setupDatAccess( "FCHierarchy", xiv::exd::Language::en ); + m_FCProfileDat = setupDatAccess( "FCProfile", xiv::exd::Language::en ); m_FCReputationDat = setupDatAccess( "FCReputation", xiv::exd::Language::en ); m_FCRightsDat = setupDatAccess( "FCRights", xiv::exd::Language::en ); m_FishingSpotDat = setupDatAccess( "FishingSpot", xiv::exd::Language::en ); @@ -3967,6 +4039,12 @@ bool Core::Data::ExdDataGenerated::init( const std::string& path ) m_GcArmyExpeditionTypeDat = setupDatAccess( "GcArmyExpeditionType", xiv::exd::Language::en ); m_GcArmyMemberGrowDat = setupDatAccess( "GcArmyMemberGrow", xiv::exd::Language::none ); m_GcArmyTrainingDat = setupDatAccess( "GcArmyTraining", xiv::exd::Language::en ); + m_GCRankGridaniaFemaleTextDat = setupDatAccess( "GCRankGridaniaFemaleText", xiv::exd::Language::en ); + m_GCRankGridaniaMaleTextDat = setupDatAccess( "GCRankGridaniaMaleText", xiv::exd::Language::en ); + m_GCRankLimsaFemaleTextDat = setupDatAccess( "GCRankLimsaFemaleText", xiv::exd::Language::en ); + m_GCRankLimsaMaleTextDat = setupDatAccess( "GCRankLimsaMaleText", xiv::exd::Language::en ); + m_GCRankUldahFemaleTextDat = setupDatAccess( "GCRankUldahFemaleText", xiv::exd::Language::en ); + m_GCRankUldahMaleTextDat = setupDatAccess( "GCRankUldahMaleText", xiv::exd::Language::en ); m_GCScripShopCategoryDat = setupDatAccess( "GCScripShopCategory", xiv::exd::Language::none ); m_GCScripShopItemDat = setupDatAccess( "GCScripShopItem", xiv::exd::Language::none ); m_GCShopDat = setupDatAccess( "GCShop", xiv::exd::Language::none ); @@ -4033,6 +4111,7 @@ bool Core::Data::ExdDataGenerated::init( const std::string& path ) m_NpcEquipDat = setupDatAccess( "NpcEquip", xiv::exd::Language::none ); m_OmenDat = setupDatAccess( "Omen", xiv::exd::Language::none ); m_OnlineStatusDat = setupDatAccess( "OnlineStatus", xiv::exd::Language::en ); + m_OpeningDat = setupDatAccess( "Opening", xiv::exd::Language::none ); m_OrchestrionDat = setupDatAccess( "Orchestrion", xiv::exd::Language::en ); m_OrchestrionPathDat = setupDatAccess( "OrchestrionPath", xiv::exd::Language::none ); m_ParamGrowDat = setupDatAccess( "ParamGrow", xiv::exd::Language::none ); @@ -4117,7 +4196,7 @@ bool Core::Data::ExdDataGenerated::init( const std::string& path ) /////////////////////////////////////////////////////////////// // DIRECT GETTERS -boost::shared_ptr< Core::Data::Achievement > +Core::Data::ExdDataGenerated::AchievementPtr Core::Data::ExdDataGenerated::getAchievement( uint32_t AchievementId ) { try @@ -4132,7 +4211,7 @@ boost::shared_ptr< Core::Data::Achievement > } return nullptr; } -boost::shared_ptr< Core::Data::AchievementCategory > +Core::Data::ExdDataGenerated::AchievementCategoryPtr Core::Data::ExdDataGenerated::getAchievementCategory( uint32_t AchievementCategoryId ) { try @@ -4147,7 +4226,7 @@ boost::shared_ptr< Core::Data::AchievementCategory > } return nullptr; } -boost::shared_ptr< Core::Data::AchievementKind > +Core::Data::ExdDataGenerated::AchievementKindPtr Core::Data::ExdDataGenerated::getAchievementKind( uint32_t AchievementKindId ) { try @@ -4162,7 +4241,7 @@ boost::shared_ptr< Core::Data::AchievementKind > } return nullptr; } -boost::shared_ptr< Core::Data::Action > +Core::Data::ExdDataGenerated::ActionPtr Core::Data::ExdDataGenerated::getAction( uint32_t ActionId ) { try @@ -4177,7 +4256,7 @@ boost::shared_ptr< Core::Data::Action > } return nullptr; } -boost::shared_ptr< Core::Data::ActionCategory > +Core::Data::ExdDataGenerated::ActionCategoryPtr Core::Data::ExdDataGenerated::getActionCategory( uint32_t ActionCategoryId ) { try @@ -4192,7 +4271,7 @@ boost::shared_ptr< Core::Data::ActionCategory > } return nullptr; } -boost::shared_ptr< Core::Data::ActionComboRoute > +Core::Data::ExdDataGenerated::ActionComboRoutePtr Core::Data::ExdDataGenerated::getActionComboRoute( uint32_t ActionComboRouteId ) { try @@ -4207,7 +4286,7 @@ boost::shared_ptr< Core::Data::ActionComboRoute > } return nullptr; } -boost::shared_ptr< Core::Data::ActionIndirection > +Core::Data::ExdDataGenerated::ActionIndirectionPtr Core::Data::ExdDataGenerated::getActionIndirection( uint32_t ActionIndirectionId ) { try @@ -4222,7 +4301,7 @@ boost::shared_ptr< Core::Data::ActionIndirection > } return nullptr; } -boost::shared_ptr< Core::Data::ActionProcStatus > +Core::Data::ExdDataGenerated::ActionProcStatusPtr Core::Data::ExdDataGenerated::getActionProcStatus( uint32_t ActionProcStatusId ) { try @@ -4237,7 +4316,7 @@ boost::shared_ptr< Core::Data::ActionProcStatus > } return nullptr; } -boost::shared_ptr< Core::Data::ActionTimeline > +Core::Data::ExdDataGenerated::ActionTimelinePtr Core::Data::ExdDataGenerated::getActionTimeline( uint32_t ActionTimelineId ) { try @@ -4252,7 +4331,7 @@ boost::shared_ptr< Core::Data::ActionTimeline > } return nullptr; } -boost::shared_ptr< Core::Data::ActionTransient > +Core::Data::ExdDataGenerated::ActionTransientPtr Core::Data::ExdDataGenerated::getActionTransient( uint32_t ActionTransientId ) { try @@ -4267,7 +4346,7 @@ boost::shared_ptr< Core::Data::ActionTransient > } return nullptr; } -boost::shared_ptr< Core::Data::Addon > +Core::Data::ExdDataGenerated::AddonPtr Core::Data::ExdDataGenerated::getAddon( uint32_t AddonId ) { try @@ -4282,7 +4361,7 @@ boost::shared_ptr< Core::Data::Addon > } return nullptr; } -boost::shared_ptr< Core::Data::Adventure > +Core::Data::ExdDataGenerated::AdventurePtr Core::Data::ExdDataGenerated::getAdventure( uint32_t AdventureId ) { try @@ -4297,7 +4376,7 @@ boost::shared_ptr< Core::Data::Adventure > } return nullptr; } -boost::shared_ptr< Core::Data::AdventureExPhase > +Core::Data::ExdDataGenerated::AdventureExPhasePtr Core::Data::ExdDataGenerated::getAdventureExPhase( uint32_t AdventureExPhaseId ) { try @@ -4312,7 +4391,7 @@ boost::shared_ptr< Core::Data::AdventureExPhase > } return nullptr; } -boost::shared_ptr< Core::Data::AetherCurrent > +Core::Data::ExdDataGenerated::AetherCurrentPtr Core::Data::ExdDataGenerated::getAetherCurrent( uint32_t AetherCurrentId ) { try @@ -4327,7 +4406,7 @@ boost::shared_ptr< Core::Data::AetherCurrent > } return nullptr; } -boost::shared_ptr< Core::Data::AetherialWheel > +Core::Data::ExdDataGenerated::AetherialWheelPtr Core::Data::ExdDataGenerated::getAetherialWheel( uint32_t AetherialWheelId ) { try @@ -4342,7 +4421,7 @@ boost::shared_ptr< Core::Data::AetherialWheel > } return nullptr; } -boost::shared_ptr< Core::Data::Aetheryte > +Core::Data::ExdDataGenerated::AetherytePtr Core::Data::ExdDataGenerated::getAetheryte( uint32_t AetheryteId ) { try @@ -4357,7 +4436,7 @@ boost::shared_ptr< Core::Data::Aetheryte > } return nullptr; } -boost::shared_ptr< Core::Data::AirshipExplorationLevel > +Core::Data::ExdDataGenerated::AirshipExplorationLevelPtr Core::Data::ExdDataGenerated::getAirshipExplorationLevel( uint32_t AirshipExplorationLevelId ) { try @@ -4372,7 +4451,7 @@ boost::shared_ptr< Core::Data::AirshipExplorationLevel > } return nullptr; } -boost::shared_ptr< Core::Data::AirshipExplorationLog > +Core::Data::ExdDataGenerated::AirshipExplorationLogPtr Core::Data::ExdDataGenerated::getAirshipExplorationLog( uint32_t AirshipExplorationLogId ) { try @@ -4387,7 +4466,7 @@ boost::shared_ptr< Core::Data::AirshipExplorationLog > } return nullptr; } -boost::shared_ptr< Core::Data::AirshipExplorationParamType > +Core::Data::ExdDataGenerated::AirshipExplorationParamTypePtr Core::Data::ExdDataGenerated::getAirshipExplorationParamType( uint32_t AirshipExplorationParamTypeId ) { try @@ -4402,7 +4481,7 @@ boost::shared_ptr< Core::Data::AirshipExplorationParamType > } return nullptr; } -boost::shared_ptr< Core::Data::AirshipExplorationPart > +Core::Data::ExdDataGenerated::AirshipExplorationPartPtr Core::Data::ExdDataGenerated::getAirshipExplorationPart( uint32_t AirshipExplorationPartId ) { try @@ -4417,7 +4496,7 @@ boost::shared_ptr< Core::Data::AirshipExplorationPart > } return nullptr; } -boost::shared_ptr< Core::Data::AirshipExplorationPoint > +Core::Data::ExdDataGenerated::AirshipExplorationPointPtr Core::Data::ExdDataGenerated::getAirshipExplorationPoint( uint32_t AirshipExplorationPointId ) { try @@ -4432,7 +4511,7 @@ boost::shared_ptr< Core::Data::AirshipExplorationPoint > } return nullptr; } -boost::shared_ptr< Core::Data::AnimaWeapon5 > +Core::Data::ExdDataGenerated::AnimaWeapon5Ptr Core::Data::ExdDataGenerated::getAnimaWeapon5( uint32_t AnimaWeapon5Id ) { try @@ -4447,7 +4526,7 @@ boost::shared_ptr< Core::Data::AnimaWeapon5 > } return nullptr; } -boost::shared_ptr< Core::Data::AnimaWeapon5Param > +Core::Data::ExdDataGenerated::AnimaWeapon5ParamPtr Core::Data::ExdDataGenerated::getAnimaWeapon5Param( uint32_t AnimaWeapon5ParamId ) { try @@ -4462,7 +4541,7 @@ boost::shared_ptr< Core::Data::AnimaWeapon5Param > } return nullptr; } -boost::shared_ptr< Core::Data::AnimaWeapon5PatternGroup > +Core::Data::ExdDataGenerated::AnimaWeapon5PatternGroupPtr Core::Data::ExdDataGenerated::getAnimaWeapon5PatternGroup( uint32_t AnimaWeapon5PatternGroupId ) { try @@ -4477,7 +4556,7 @@ boost::shared_ptr< Core::Data::AnimaWeapon5PatternGroup > } return nullptr; } -boost::shared_ptr< Core::Data::AnimaWeapon5SpiritTalk > +Core::Data::ExdDataGenerated::AnimaWeapon5SpiritTalkPtr Core::Data::ExdDataGenerated::getAnimaWeapon5SpiritTalk( uint32_t AnimaWeapon5SpiritTalkId ) { try @@ -4492,7 +4571,7 @@ boost::shared_ptr< Core::Data::AnimaWeapon5SpiritTalk > } return nullptr; } -boost::shared_ptr< Core::Data::AnimaWeapon5SpiritTalkParam > +Core::Data::ExdDataGenerated::AnimaWeapon5SpiritTalkParamPtr Core::Data::ExdDataGenerated::getAnimaWeapon5SpiritTalkParam( uint32_t AnimaWeapon5SpiritTalkParamId ) { try @@ -4507,7 +4586,7 @@ boost::shared_ptr< Core::Data::AnimaWeapon5SpiritTalkParam > } return nullptr; } -boost::shared_ptr< Core::Data::AnimaWeapon5TradeItem > +Core::Data::ExdDataGenerated::AnimaWeapon5TradeItemPtr Core::Data::ExdDataGenerated::getAnimaWeapon5TradeItem( uint32_t AnimaWeapon5TradeItemId ) { try @@ -4522,7 +4601,7 @@ boost::shared_ptr< Core::Data::AnimaWeapon5TradeItem > } return nullptr; } -boost::shared_ptr< Core::Data::AnimaWeaponFUITalk > +Core::Data::ExdDataGenerated::AnimaWeaponFUITalkPtr Core::Data::ExdDataGenerated::getAnimaWeaponFUITalk( uint32_t AnimaWeaponFUITalkId ) { try @@ -4537,7 +4616,7 @@ boost::shared_ptr< Core::Data::AnimaWeaponFUITalk > } return nullptr; } -boost::shared_ptr< Core::Data::AnimaWeaponFUITalkParam > +Core::Data::ExdDataGenerated::AnimaWeaponFUITalkParamPtr Core::Data::ExdDataGenerated::getAnimaWeaponFUITalkParam( uint32_t AnimaWeaponFUITalkParamId ) { try @@ -4552,7 +4631,7 @@ boost::shared_ptr< Core::Data::AnimaWeaponFUITalkParam > } return nullptr; } -boost::shared_ptr< Core::Data::AnimaWeaponIcon > +Core::Data::ExdDataGenerated::AnimaWeaponIconPtr Core::Data::ExdDataGenerated::getAnimaWeaponIcon( uint32_t AnimaWeaponIconId ) { try @@ -4567,7 +4646,7 @@ boost::shared_ptr< Core::Data::AnimaWeaponIcon > } return nullptr; } -boost::shared_ptr< Core::Data::AnimaWeaponItem > +Core::Data::ExdDataGenerated::AnimaWeaponItemPtr Core::Data::ExdDataGenerated::getAnimaWeaponItem( uint32_t AnimaWeaponItemId ) { try @@ -4582,7 +4661,7 @@ boost::shared_ptr< Core::Data::AnimaWeaponItem > } return nullptr; } -boost::shared_ptr< Core::Data::AquariumFish > +Core::Data::ExdDataGenerated::AquariumFishPtr Core::Data::ExdDataGenerated::getAquariumFish( uint32_t AquariumFishId ) { try @@ -4597,7 +4676,7 @@ boost::shared_ptr< Core::Data::AquariumFish > } return nullptr; } -boost::shared_ptr< Core::Data::AquariumWater > +Core::Data::ExdDataGenerated::AquariumWaterPtr Core::Data::ExdDataGenerated::getAquariumWater( uint32_t AquariumWaterId ) { try @@ -4612,7 +4691,7 @@ boost::shared_ptr< Core::Data::AquariumWater > } return nullptr; } -boost::shared_ptr< Core::Data::AttackType > +Core::Data::ExdDataGenerated::AttackTypePtr Core::Data::ExdDataGenerated::getAttackType( uint32_t AttackTypeId ) { try @@ -4627,7 +4706,7 @@ boost::shared_ptr< Core::Data::AttackType > } return nullptr; } -boost::shared_ptr< Core::Data::Balloon > +Core::Data::ExdDataGenerated::BalloonPtr Core::Data::ExdDataGenerated::getBalloon( uint32_t BalloonId ) { try @@ -4642,7 +4721,7 @@ boost::shared_ptr< Core::Data::Balloon > } return nullptr; } -boost::shared_ptr< Core::Data::BaseParam > +Core::Data::ExdDataGenerated::BaseParamPtr Core::Data::ExdDataGenerated::getBaseParam( uint32_t BaseParamId ) { try @@ -4657,7 +4736,7 @@ boost::shared_ptr< Core::Data::BaseParam > } return nullptr; } -boost::shared_ptr< Core::Data::BattleLeve > +Core::Data::ExdDataGenerated::BattleLevePtr Core::Data::ExdDataGenerated::getBattleLeve( uint32_t BattleLeveId ) { try @@ -4672,7 +4751,7 @@ boost::shared_ptr< Core::Data::BattleLeve > } return nullptr; } -boost::shared_ptr< Core::Data::BeastRankBonus > +Core::Data::ExdDataGenerated::BeastRankBonusPtr Core::Data::ExdDataGenerated::getBeastRankBonus( uint32_t BeastRankBonusId ) { try @@ -4687,7 +4766,7 @@ boost::shared_ptr< Core::Data::BeastRankBonus > } return nullptr; } -boost::shared_ptr< Core::Data::BeastReputationRank > +Core::Data::ExdDataGenerated::BeastReputationRankPtr Core::Data::ExdDataGenerated::getBeastReputationRank( uint32_t BeastReputationRankId ) { try @@ -4702,7 +4781,7 @@ boost::shared_ptr< Core::Data::BeastReputationRank > } return nullptr; } -boost::shared_ptr< Core::Data::BeastTribe > +Core::Data::ExdDataGenerated::BeastTribePtr Core::Data::ExdDataGenerated::getBeastTribe( uint32_t BeastTribeId ) { try @@ -4717,7 +4796,7 @@ boost::shared_ptr< Core::Data::BeastTribe > } return nullptr; } -boost::shared_ptr< Core::Data::Behavior > +Core::Data::ExdDataGenerated::BehaviorPtr Core::Data::ExdDataGenerated::getBehavior( uint32_t BehaviorId ) { try @@ -4732,7 +4811,7 @@ boost::shared_ptr< Core::Data::Behavior > } return nullptr; } -boost::shared_ptr< Core::Data::BGM > +Core::Data::ExdDataGenerated::BGMPtr Core::Data::ExdDataGenerated::getBGM( uint32_t BGMId ) { try @@ -4747,7 +4826,7 @@ boost::shared_ptr< Core::Data::BGM > } return nullptr; } -boost::shared_ptr< Core::Data::BNpcAnnounceIcon > +Core::Data::ExdDataGenerated::BNpcAnnounceIconPtr Core::Data::ExdDataGenerated::getBNpcAnnounceIcon( uint32_t BNpcAnnounceIconId ) { try @@ -4762,7 +4841,7 @@ boost::shared_ptr< Core::Data::BNpcAnnounceIcon > } return nullptr; } -boost::shared_ptr< Core::Data::BNpcBase > +Core::Data::ExdDataGenerated::BNpcBasePtr Core::Data::ExdDataGenerated::getBNpcBase( uint32_t BNpcBaseId ) { try @@ -4777,7 +4856,7 @@ boost::shared_ptr< Core::Data::BNpcBase > } return nullptr; } -boost::shared_ptr< Core::Data::BNpcCustomize > +Core::Data::ExdDataGenerated::BNpcCustomizePtr Core::Data::ExdDataGenerated::getBNpcCustomize( uint32_t BNpcCustomizeId ) { try @@ -4792,7 +4871,7 @@ boost::shared_ptr< Core::Data::BNpcCustomize > } return nullptr; } -boost::shared_ptr< Core::Data::BNpcName > +Core::Data::ExdDataGenerated::BNpcNamePtr Core::Data::ExdDataGenerated::getBNpcName( uint32_t BNpcNameId ) { try @@ -4807,7 +4886,7 @@ boost::shared_ptr< Core::Data::BNpcName > } return nullptr; } -boost::shared_ptr< Core::Data::BuddyAction > +Core::Data::ExdDataGenerated::BuddyActionPtr Core::Data::ExdDataGenerated::getBuddyAction( uint32_t BuddyActionId ) { try @@ -4822,7 +4901,7 @@ boost::shared_ptr< Core::Data::BuddyAction > } return nullptr; } -boost::shared_ptr< Core::Data::BuddyEquip > +Core::Data::ExdDataGenerated::BuddyEquipPtr Core::Data::ExdDataGenerated::getBuddyEquip( uint32_t BuddyEquipId ) { try @@ -4837,7 +4916,7 @@ boost::shared_ptr< Core::Data::BuddyEquip > } return nullptr; } -boost::shared_ptr< Core::Data::BuddyItem > +Core::Data::ExdDataGenerated::BuddyItemPtr Core::Data::ExdDataGenerated::getBuddyItem( uint32_t BuddyItemId ) { try @@ -4852,7 +4931,7 @@ boost::shared_ptr< Core::Data::BuddyItem > } return nullptr; } -boost::shared_ptr< Core::Data::BuddyRank > +Core::Data::ExdDataGenerated::BuddyRankPtr Core::Data::ExdDataGenerated::getBuddyRank( uint32_t BuddyRankId ) { try @@ -4867,7 +4946,7 @@ boost::shared_ptr< Core::Data::BuddyRank > } return nullptr; } -boost::shared_ptr< Core::Data::BuddySkill > +Core::Data::ExdDataGenerated::BuddySkillPtr Core::Data::ExdDataGenerated::getBuddySkill( uint32_t BuddySkillId ) { try @@ -4882,7 +4961,7 @@ boost::shared_ptr< Core::Data::BuddySkill > } return nullptr; } -boost::shared_ptr< Core::Data::Cabinet > +Core::Data::ExdDataGenerated::CabinetPtr Core::Data::ExdDataGenerated::getCabinet( uint32_t CabinetId ) { try @@ -4897,7 +4976,7 @@ boost::shared_ptr< Core::Data::Cabinet > } return nullptr; } -boost::shared_ptr< Core::Data::CabinetCategory > +Core::Data::ExdDataGenerated::CabinetCategoryPtr Core::Data::ExdDataGenerated::getCabinetCategory( uint32_t CabinetCategoryId ) { try @@ -4912,7 +4991,7 @@ boost::shared_ptr< Core::Data::CabinetCategory > } return nullptr; } -boost::shared_ptr< Core::Data::Calendar > +Core::Data::ExdDataGenerated::CalendarPtr Core::Data::ExdDataGenerated::getCalendar( uint32_t CalendarId ) { try @@ -4927,22 +5006,7 @@ boost::shared_ptr< Core::Data::Calendar > } return nullptr; } -boost::shared_ptr< Core::Data::ChainBonus > - Core::Data::ExdDataGenerated::getChainBonus( uint32_t ChainBonusId ) -{ - try - { - auto row = m_ChainBonusDat.get_row( ChainBonusId ); - auto info = boost::make_shared< ChainBonus >( ChainBonusId, this ); - return info; - } - catch( ... ) - { - return nullptr; - } - return nullptr; -} -boost::shared_ptr< Core::Data::CharaMakeCustomize > +Core::Data::ExdDataGenerated::CharaMakeCustomizePtr Core::Data::ExdDataGenerated::getCharaMakeCustomize( uint32_t CharaMakeCustomizeId ) { try @@ -4957,7 +5021,7 @@ boost::shared_ptr< Core::Data::CharaMakeCustomize > } return nullptr; } -boost::shared_ptr< Core::Data::CharaMakeType > +Core::Data::ExdDataGenerated::CharaMakeTypePtr Core::Data::ExdDataGenerated::getCharaMakeType( uint32_t CharaMakeTypeId ) { try @@ -4972,7 +5036,7 @@ boost::shared_ptr< Core::Data::CharaMakeType > } return nullptr; } -boost::shared_ptr< Core::Data::ChocoboRace > +Core::Data::ExdDataGenerated::ChocoboRacePtr Core::Data::ExdDataGenerated::getChocoboRace( uint32_t ChocoboRaceId ) { try @@ -4987,7 +5051,7 @@ boost::shared_ptr< Core::Data::ChocoboRace > } return nullptr; } -boost::shared_ptr< Core::Data::ChocoboRaceAbility > +Core::Data::ExdDataGenerated::ChocoboRaceAbilityPtr Core::Data::ExdDataGenerated::getChocoboRaceAbility( uint32_t ChocoboRaceAbilityId ) { try @@ -5002,7 +5066,7 @@ boost::shared_ptr< Core::Data::ChocoboRaceAbility > } return nullptr; } -boost::shared_ptr< Core::Data::ChocoboRaceAbilityType > +Core::Data::ExdDataGenerated::ChocoboRaceAbilityTypePtr Core::Data::ExdDataGenerated::getChocoboRaceAbilityType( uint32_t ChocoboRaceAbilityTypeId ) { try @@ -5017,7 +5081,7 @@ boost::shared_ptr< Core::Data::ChocoboRaceAbilityType > } return nullptr; } -boost::shared_ptr< Core::Data::ChocoboRaceItem > +Core::Data::ExdDataGenerated::ChocoboRaceItemPtr Core::Data::ExdDataGenerated::getChocoboRaceItem( uint32_t ChocoboRaceItemId ) { try @@ -5032,7 +5096,7 @@ boost::shared_ptr< Core::Data::ChocoboRaceItem > } return nullptr; } -boost::shared_ptr< Core::Data::ChocoboRaceRank > +Core::Data::ExdDataGenerated::ChocoboRaceRankPtr Core::Data::ExdDataGenerated::getChocoboRaceRank( uint32_t ChocoboRaceRankId ) { try @@ -5047,7 +5111,7 @@ boost::shared_ptr< Core::Data::ChocoboRaceRank > } return nullptr; } -boost::shared_ptr< Core::Data::ChocoboRaceStatus > +Core::Data::ExdDataGenerated::ChocoboRaceStatusPtr Core::Data::ExdDataGenerated::getChocoboRaceStatus( uint32_t ChocoboRaceStatusId ) { try @@ -5062,7 +5126,7 @@ boost::shared_ptr< Core::Data::ChocoboRaceStatus > } return nullptr; } -boost::shared_ptr< Core::Data::ChocoboRaceTerritory > +Core::Data::ExdDataGenerated::ChocoboRaceTerritoryPtr Core::Data::ExdDataGenerated::getChocoboRaceTerritory( uint32_t ChocoboRaceTerritoryId ) { try @@ -5077,7 +5141,7 @@ boost::shared_ptr< Core::Data::ChocoboRaceTerritory > } return nullptr; } -boost::shared_ptr< Core::Data::ChocoboTaxiStand > +Core::Data::ExdDataGenerated::ChocoboTaxiStandPtr Core::Data::ExdDataGenerated::getChocoboTaxiStand( uint32_t ChocoboTaxiStandId ) { try @@ -5092,7 +5156,7 @@ boost::shared_ptr< Core::Data::ChocoboTaxiStand > } return nullptr; } -boost::shared_ptr< Core::Data::ClassJob > +Core::Data::ExdDataGenerated::ClassJobPtr Core::Data::ExdDataGenerated::getClassJob( uint32_t ClassJobId ) { try @@ -5107,7 +5171,7 @@ boost::shared_ptr< Core::Data::ClassJob > } return nullptr; } -boost::shared_ptr< Core::Data::ClassJobCategory > +Core::Data::ExdDataGenerated::ClassJobCategoryPtr Core::Data::ExdDataGenerated::getClassJobCategory( uint32_t ClassJobCategoryId ) { try @@ -5122,7 +5186,7 @@ boost::shared_ptr< Core::Data::ClassJobCategory > } return nullptr; } -boost::shared_ptr< Core::Data::Companion > +Core::Data::ExdDataGenerated::CompanionPtr Core::Data::ExdDataGenerated::getCompanion( uint32_t CompanionId ) { try @@ -5137,7 +5201,7 @@ boost::shared_ptr< Core::Data::Companion > } return nullptr; } -boost::shared_ptr< Core::Data::CompanionMove > +Core::Data::ExdDataGenerated::CompanionMovePtr Core::Data::ExdDataGenerated::getCompanionMove( uint32_t CompanionMoveId ) { try @@ -5152,7 +5216,7 @@ boost::shared_ptr< Core::Data::CompanionMove > } return nullptr; } -boost::shared_ptr< Core::Data::CompanionTransient > +Core::Data::ExdDataGenerated::CompanionTransientPtr Core::Data::ExdDataGenerated::getCompanionTransient( uint32_t CompanionTransientId ) { try @@ -5167,7 +5231,7 @@ boost::shared_ptr< Core::Data::CompanionTransient > } return nullptr; } -boost::shared_ptr< Core::Data::CompanyAction > +Core::Data::ExdDataGenerated::CompanyActionPtr Core::Data::ExdDataGenerated::getCompanyAction( uint32_t CompanyActionId ) { try @@ -5182,7 +5246,7 @@ boost::shared_ptr< Core::Data::CompanyAction > } return nullptr; } -boost::shared_ptr< Core::Data::CompanyCraftDraft > +Core::Data::ExdDataGenerated::CompanyCraftDraftPtr Core::Data::ExdDataGenerated::getCompanyCraftDraft( uint32_t CompanyCraftDraftId ) { try @@ -5197,7 +5261,7 @@ boost::shared_ptr< Core::Data::CompanyCraftDraft > } return nullptr; } -boost::shared_ptr< Core::Data::CompanyCraftDraftCategory > +Core::Data::ExdDataGenerated::CompanyCraftDraftCategoryPtr Core::Data::ExdDataGenerated::getCompanyCraftDraftCategory( uint32_t CompanyCraftDraftCategoryId ) { try @@ -5212,7 +5276,7 @@ boost::shared_ptr< Core::Data::CompanyCraftDraftCategory > } return nullptr; } -boost::shared_ptr< Core::Data::CompanyCraftManufactoryState > +Core::Data::ExdDataGenerated::CompanyCraftManufactoryStatePtr Core::Data::ExdDataGenerated::getCompanyCraftManufactoryState( uint32_t CompanyCraftManufactoryStateId ) { try @@ -5227,7 +5291,7 @@ boost::shared_ptr< Core::Data::CompanyCraftManufactoryState > } return nullptr; } -boost::shared_ptr< Core::Data::CompanyCraftPart > +Core::Data::ExdDataGenerated::CompanyCraftPartPtr Core::Data::ExdDataGenerated::getCompanyCraftPart( uint32_t CompanyCraftPartId ) { try @@ -5242,7 +5306,7 @@ boost::shared_ptr< Core::Data::CompanyCraftPart > } return nullptr; } -boost::shared_ptr< Core::Data::CompanyCraftProcess > +Core::Data::ExdDataGenerated::CompanyCraftProcessPtr Core::Data::ExdDataGenerated::getCompanyCraftProcess( uint32_t CompanyCraftProcessId ) { try @@ -5257,7 +5321,7 @@ boost::shared_ptr< Core::Data::CompanyCraftProcess > } return nullptr; } -boost::shared_ptr< Core::Data::CompanyCraftSequence > +Core::Data::ExdDataGenerated::CompanyCraftSequencePtr Core::Data::ExdDataGenerated::getCompanyCraftSequence( uint32_t CompanyCraftSequenceId ) { try @@ -5272,7 +5336,7 @@ boost::shared_ptr< Core::Data::CompanyCraftSequence > } return nullptr; } -boost::shared_ptr< Core::Data::CompanyCraftSupplyItem > +Core::Data::ExdDataGenerated::CompanyCraftSupplyItemPtr Core::Data::ExdDataGenerated::getCompanyCraftSupplyItem( uint32_t CompanyCraftSupplyItemId ) { try @@ -5287,7 +5351,7 @@ boost::shared_ptr< Core::Data::CompanyCraftSupplyItem > } return nullptr; } -boost::shared_ptr< Core::Data::CompanyCraftType > +Core::Data::ExdDataGenerated::CompanyCraftTypePtr Core::Data::ExdDataGenerated::getCompanyCraftType( uint32_t CompanyCraftTypeId ) { try @@ -5302,7 +5366,7 @@ boost::shared_ptr< Core::Data::CompanyCraftType > } return nullptr; } -boost::shared_ptr< Core::Data::CompleteJournal > +Core::Data::ExdDataGenerated::CompleteJournalPtr Core::Data::ExdDataGenerated::getCompleteJournal( uint32_t CompleteJournalId ) { try @@ -5317,7 +5381,7 @@ boost::shared_ptr< Core::Data::CompleteJournal > } return nullptr; } -boost::shared_ptr< Core::Data::CompleteJournalCategory > +Core::Data::ExdDataGenerated::CompleteJournalCategoryPtr Core::Data::ExdDataGenerated::getCompleteJournalCategory( uint32_t CompleteJournalCategoryId ) { try @@ -5332,7 +5396,7 @@ boost::shared_ptr< Core::Data::CompleteJournalCategory > } return nullptr; } -boost::shared_ptr< Core::Data::ContentExAction > +Core::Data::ExdDataGenerated::ContentExActionPtr Core::Data::ExdDataGenerated::getContentExAction( uint32_t ContentExActionId ) { try @@ -5347,7 +5411,7 @@ boost::shared_ptr< Core::Data::ContentExAction > } return nullptr; } -boost::shared_ptr< Core::Data::ContentFinderCondition > +Core::Data::ExdDataGenerated::ContentFinderConditionPtr Core::Data::ExdDataGenerated::getContentFinderCondition( uint32_t ContentFinderConditionId ) { try @@ -5362,7 +5426,7 @@ boost::shared_ptr< Core::Data::ContentFinderCondition > } return nullptr; } -boost::shared_ptr< Core::Data::ContentFinderConditionTransient > +Core::Data::ExdDataGenerated::ContentFinderConditionTransientPtr Core::Data::ExdDataGenerated::getContentFinderConditionTransient( uint32_t ContentFinderConditionTransientId ) { try @@ -5377,7 +5441,7 @@ boost::shared_ptr< Core::Data::ContentFinderConditionTransient > } return nullptr; } -boost::shared_ptr< Core::Data::ContentMemberType > +Core::Data::ExdDataGenerated::ContentMemberTypePtr Core::Data::ExdDataGenerated::getContentMemberType( uint32_t ContentMemberTypeId ) { try @@ -5392,7 +5456,7 @@ boost::shared_ptr< Core::Data::ContentMemberType > } return nullptr; } -boost::shared_ptr< Core::Data::ContentRoulette > +Core::Data::ExdDataGenerated::ContentRoulettePtr Core::Data::ExdDataGenerated::getContentRoulette( uint32_t ContentRouletteId ) { try @@ -5407,7 +5471,7 @@ boost::shared_ptr< Core::Data::ContentRoulette > } return nullptr; } -boost::shared_ptr< Core::Data::ContentType > +Core::Data::ExdDataGenerated::ContentTypePtr Core::Data::ExdDataGenerated::getContentType( uint32_t ContentTypeId ) { try @@ -5422,7 +5486,7 @@ boost::shared_ptr< Core::Data::ContentType > } return nullptr; } -boost::shared_ptr< Core::Data::CraftAction > +Core::Data::ExdDataGenerated::CraftActionPtr Core::Data::ExdDataGenerated::getCraftAction( uint32_t CraftActionId ) { try @@ -5437,7 +5501,7 @@ boost::shared_ptr< Core::Data::CraftAction > } return nullptr; } -boost::shared_ptr< Core::Data::CraftLeve > +Core::Data::ExdDataGenerated::CraftLevePtr Core::Data::ExdDataGenerated::getCraftLeve( uint32_t CraftLeveId ) { try @@ -5452,7 +5516,7 @@ boost::shared_ptr< Core::Data::CraftLeve > } return nullptr; } -boost::shared_ptr< Core::Data::CraftType > +Core::Data::ExdDataGenerated::CraftTypePtr Core::Data::ExdDataGenerated::getCraftType( uint32_t CraftTypeId ) { try @@ -5467,7 +5531,7 @@ boost::shared_ptr< Core::Data::CraftType > } return nullptr; } -boost::shared_ptr< Core::Data::Currency > +Core::Data::ExdDataGenerated::CurrencyPtr Core::Data::ExdDataGenerated::getCurrency( uint32_t CurrencyId ) { try @@ -5482,7 +5546,7 @@ boost::shared_ptr< Core::Data::Currency > } return nullptr; } -boost::shared_ptr< Core::Data::CustomTalk > +Core::Data::ExdDataGenerated::CustomTalkPtr Core::Data::ExdDataGenerated::getCustomTalk( uint32_t CustomTalkId ) { try @@ -5497,7 +5561,7 @@ boost::shared_ptr< Core::Data::CustomTalk > } return nullptr; } -boost::shared_ptr< Core::Data::Cutscene > +Core::Data::ExdDataGenerated::CutscenePtr Core::Data::ExdDataGenerated::getCutscene( uint32_t CutsceneId ) { try @@ -5512,7 +5576,7 @@ boost::shared_ptr< Core::Data::Cutscene > } return nullptr; } -boost::shared_ptr< Core::Data::CutScreenImage > +Core::Data::ExdDataGenerated::CutScreenImagePtr Core::Data::ExdDataGenerated::getCutScreenImage( uint32_t CutScreenImageId ) { try @@ -5527,7 +5591,7 @@ boost::shared_ptr< Core::Data::CutScreenImage > } return nullptr; } -boost::shared_ptr< Core::Data::DailySupplyItem > +Core::Data::ExdDataGenerated::DailySupplyItemPtr Core::Data::ExdDataGenerated::getDailySupplyItem( uint32_t DailySupplyItemId ) { try @@ -5542,7 +5606,7 @@ boost::shared_ptr< Core::Data::DailySupplyItem > } return nullptr; } -boost::shared_ptr< Core::Data::DeepDungeonBan > +Core::Data::ExdDataGenerated::DeepDungeonBanPtr Core::Data::ExdDataGenerated::getDeepDungeonBan( uint32_t DeepDungeonBanId ) { try @@ -5557,7 +5621,7 @@ boost::shared_ptr< Core::Data::DeepDungeonBan > } return nullptr; } -boost::shared_ptr< Core::Data::DeepDungeonDanger > +Core::Data::ExdDataGenerated::DeepDungeonDangerPtr Core::Data::ExdDataGenerated::getDeepDungeonDanger( uint32_t DeepDungeonDangerId ) { try @@ -5572,7 +5636,7 @@ boost::shared_ptr< Core::Data::DeepDungeonDanger > } return nullptr; } -boost::shared_ptr< Core::Data::DeepDungeonEquipment > +Core::Data::ExdDataGenerated::DeepDungeonEquipmentPtr Core::Data::ExdDataGenerated::getDeepDungeonEquipment( uint32_t DeepDungeonEquipmentId ) { try @@ -5587,7 +5651,7 @@ boost::shared_ptr< Core::Data::DeepDungeonEquipment > } return nullptr; } -boost::shared_ptr< Core::Data::DeepDungeonFloorEffectUI > +Core::Data::ExdDataGenerated::DeepDungeonFloorEffectUIPtr Core::Data::ExdDataGenerated::getDeepDungeonFloorEffectUI( uint32_t DeepDungeonFloorEffectUIId ) { try @@ -5602,7 +5666,7 @@ boost::shared_ptr< Core::Data::DeepDungeonFloorEffectUI > } return nullptr; } -boost::shared_ptr< Core::Data::DeepDungeonItem > +Core::Data::ExdDataGenerated::DeepDungeonItemPtr Core::Data::ExdDataGenerated::getDeepDungeonItem( uint32_t DeepDungeonItemId ) { try @@ -5617,7 +5681,7 @@ boost::shared_ptr< Core::Data::DeepDungeonItem > } return nullptr; } -boost::shared_ptr< Core::Data::DeepDungeonStatus > +Core::Data::ExdDataGenerated::DeepDungeonStatusPtr Core::Data::ExdDataGenerated::getDeepDungeonStatus( uint32_t DeepDungeonStatusId ) { try @@ -5632,7 +5696,7 @@ boost::shared_ptr< Core::Data::DeepDungeonStatus > } return nullptr; } -boost::shared_ptr< Core::Data::DefaultTalk > +Core::Data::ExdDataGenerated::DefaultTalkPtr Core::Data::ExdDataGenerated::getDefaultTalk( uint32_t DefaultTalkId ) { try @@ -5647,7 +5711,7 @@ boost::shared_ptr< Core::Data::DefaultTalk > } return nullptr; } -boost::shared_ptr< Core::Data::DeliveryQuest > +Core::Data::ExdDataGenerated::DeliveryQuestPtr Core::Data::ExdDataGenerated::getDeliveryQuest( uint32_t DeliveryQuestId ) { try @@ -5662,7 +5726,7 @@ boost::shared_ptr< Core::Data::DeliveryQuest > } return nullptr; } -boost::shared_ptr< Core::Data::DisposalShop > +Core::Data::ExdDataGenerated::DisposalShopPtr Core::Data::ExdDataGenerated::getDisposalShop( uint32_t DisposalShopId ) { try @@ -5677,7 +5741,7 @@ boost::shared_ptr< Core::Data::DisposalShop > } return nullptr; } -boost::shared_ptr< Core::Data::DisposalShopFilterType > +Core::Data::ExdDataGenerated::DisposalShopFilterTypePtr Core::Data::ExdDataGenerated::getDisposalShopFilterType( uint32_t DisposalShopFilterTypeId ) { try @@ -5692,7 +5756,7 @@ boost::shared_ptr< Core::Data::DisposalShopFilterType > } return nullptr; } -boost::shared_ptr< Core::Data::DisposalShopItem > +Core::Data::ExdDataGenerated::DisposalShopItemPtr Core::Data::ExdDataGenerated::getDisposalShopItem( uint32_t DisposalShopItemId ) { try @@ -5707,7 +5771,7 @@ boost::shared_ptr< Core::Data::DisposalShopItem > } return nullptr; } -boost::shared_ptr< Core::Data::DpsChallenge > +Core::Data::ExdDataGenerated::DpsChallengePtr Core::Data::ExdDataGenerated::getDpsChallenge( uint32_t DpsChallengeId ) { try @@ -5722,7 +5786,7 @@ boost::shared_ptr< Core::Data::DpsChallenge > } return nullptr; } -boost::shared_ptr< Core::Data::DpsChallengeOfficer > +Core::Data::ExdDataGenerated::DpsChallengeOfficerPtr Core::Data::ExdDataGenerated::getDpsChallengeOfficer( uint32_t DpsChallengeOfficerId ) { try @@ -5737,7 +5801,7 @@ boost::shared_ptr< Core::Data::DpsChallengeOfficer > } return nullptr; } -boost::shared_ptr< Core::Data::DpsChallengeTransient > +Core::Data::ExdDataGenerated::DpsChallengeTransientPtr Core::Data::ExdDataGenerated::getDpsChallengeTransient( uint32_t DpsChallengeTransientId ) { try @@ -5752,7 +5816,7 @@ boost::shared_ptr< Core::Data::DpsChallengeTransient > } return nullptr; } -boost::shared_ptr< Core::Data::Emote > +Core::Data::ExdDataGenerated::EmotePtr Core::Data::ExdDataGenerated::getEmote( uint32_t EmoteId ) { try @@ -5767,7 +5831,7 @@ boost::shared_ptr< Core::Data::Emote > } return nullptr; } -boost::shared_ptr< Core::Data::EmoteCategory > +Core::Data::ExdDataGenerated::EmoteCategoryPtr Core::Data::ExdDataGenerated::getEmoteCategory( uint32_t EmoteCategoryId ) { try @@ -5782,7 +5846,7 @@ boost::shared_ptr< Core::Data::EmoteCategory > } return nullptr; } -boost::shared_ptr< Core::Data::ENpcBase > +Core::Data::ExdDataGenerated::ENpcBasePtr Core::Data::ExdDataGenerated::getENpcBase( uint32_t ENpcBaseId ) { try @@ -5797,7 +5861,7 @@ boost::shared_ptr< Core::Data::ENpcBase > } return nullptr; } -boost::shared_ptr< Core::Data::ENpcResident > +Core::Data::ExdDataGenerated::ENpcResidentPtr Core::Data::ExdDataGenerated::getENpcResident( uint32_t ENpcResidentId ) { try @@ -5812,7 +5876,7 @@ boost::shared_ptr< Core::Data::ENpcResident > } return nullptr; } -boost::shared_ptr< Core::Data::EObj > +Core::Data::ExdDataGenerated::EObjPtr Core::Data::ExdDataGenerated::getEObj( uint32_t EObjId ) { try @@ -5827,7 +5891,7 @@ boost::shared_ptr< Core::Data::EObj > } return nullptr; } -boost::shared_ptr< Core::Data::EquipRaceCategory > +Core::Data::ExdDataGenerated::EquipRaceCategoryPtr Core::Data::ExdDataGenerated::getEquipRaceCategory( uint32_t EquipRaceCategoryId ) { try @@ -5842,7 +5906,7 @@ boost::shared_ptr< Core::Data::EquipRaceCategory > } return nullptr; } -boost::shared_ptr< Core::Data::EquipSlotCategory > +Core::Data::ExdDataGenerated::EquipSlotCategoryPtr Core::Data::ExdDataGenerated::getEquipSlotCategory( uint32_t EquipSlotCategoryId ) { try @@ -5857,7 +5921,7 @@ boost::shared_ptr< Core::Data::EquipSlotCategory > } return nullptr; } -boost::shared_ptr< Core::Data::EventAction > +Core::Data::ExdDataGenerated::EventActionPtr Core::Data::ExdDataGenerated::getEventAction( uint32_t EventActionId ) { try @@ -5872,7 +5936,7 @@ boost::shared_ptr< Core::Data::EventAction > } return nullptr; } -boost::shared_ptr< Core::Data::EventIconPriority > +Core::Data::ExdDataGenerated::EventIconPriorityPtr Core::Data::ExdDataGenerated::getEventIconPriority( uint32_t EventIconPriorityId ) { try @@ -5887,7 +5951,7 @@ boost::shared_ptr< Core::Data::EventIconPriority > } return nullptr; } -boost::shared_ptr< Core::Data::EventIconType > +Core::Data::ExdDataGenerated::EventIconTypePtr Core::Data::ExdDataGenerated::getEventIconType( uint32_t EventIconTypeId ) { try @@ -5902,7 +5966,7 @@ boost::shared_ptr< Core::Data::EventIconType > } return nullptr; } -boost::shared_ptr< Core::Data::EventItem > +Core::Data::ExdDataGenerated::EventItemPtr Core::Data::ExdDataGenerated::getEventItem( uint32_t EventItemId ) { try @@ -5917,7 +5981,7 @@ boost::shared_ptr< Core::Data::EventItem > } return nullptr; } -boost::shared_ptr< Core::Data::EventItemHelp > +Core::Data::ExdDataGenerated::EventItemHelpPtr Core::Data::ExdDataGenerated::getEventItemHelp( uint32_t EventItemHelpId ) { try @@ -5932,7 +5996,7 @@ boost::shared_ptr< Core::Data::EventItemHelp > } return nullptr; } -boost::shared_ptr< Core::Data::ExVersion > +Core::Data::ExdDataGenerated::ExVersionPtr Core::Data::ExdDataGenerated::getExVersion( uint32_t ExVersionId ) { try @@ -5947,7 +6011,7 @@ boost::shared_ptr< Core::Data::ExVersion > } return nullptr; } -boost::shared_ptr< Core::Data::Fate > +Core::Data::ExdDataGenerated::FatePtr Core::Data::ExdDataGenerated::getFate( uint32_t FateId ) { try @@ -5962,7 +6026,7 @@ boost::shared_ptr< Core::Data::Fate > } return nullptr; } -boost::shared_ptr< Core::Data::FCActivity > +Core::Data::ExdDataGenerated::FCActivityPtr Core::Data::ExdDataGenerated::getFCActivity( uint32_t FCActivityId ) { try @@ -5977,7 +6041,22 @@ boost::shared_ptr< Core::Data::FCActivity > } return nullptr; } -boost::shared_ptr< Core::Data::FCAuthority > +Core::Data::ExdDataGenerated::FCActivityCategoryPtr + Core::Data::ExdDataGenerated::getFCActivityCategory( uint32_t FCActivityCategoryId ) +{ + try + { + auto row = m_FCActivityCategoryDat.get_row( FCActivityCategoryId ); + auto info = boost::make_shared< FCActivityCategory >( FCActivityCategoryId, this ); + return info; + } + catch( ... ) + { + return nullptr; + } + return nullptr; +} +Core::Data::ExdDataGenerated::FCAuthorityPtr Core::Data::ExdDataGenerated::getFCAuthority( uint32_t FCAuthorityId ) { try @@ -5992,7 +6071,7 @@ boost::shared_ptr< Core::Data::FCAuthority > } return nullptr; } -boost::shared_ptr< Core::Data::FCAuthorityCategory > +Core::Data::ExdDataGenerated::FCAuthorityCategoryPtr Core::Data::ExdDataGenerated::getFCAuthorityCategory( uint32_t FCAuthorityCategoryId ) { try @@ -6007,7 +6086,7 @@ boost::shared_ptr< Core::Data::FCAuthorityCategory > } return nullptr; } -boost::shared_ptr< Core::Data::FCChestName > +Core::Data::ExdDataGenerated::FCChestNamePtr Core::Data::ExdDataGenerated::getFCChestName( uint32_t FCChestNameId ) { try @@ -6022,7 +6101,7 @@ boost::shared_ptr< Core::Data::FCChestName > } return nullptr; } -boost::shared_ptr< Core::Data::FccShop > +Core::Data::ExdDataGenerated::FccShopPtr Core::Data::ExdDataGenerated::getFccShop( uint32_t FccShopId ) { try @@ -6037,7 +6116,7 @@ boost::shared_ptr< Core::Data::FccShop > } return nullptr; } -boost::shared_ptr< Core::Data::FCHierarchy > +Core::Data::ExdDataGenerated::FCHierarchyPtr Core::Data::ExdDataGenerated::getFCHierarchy( uint32_t FCHierarchyId ) { try @@ -6052,7 +6131,22 @@ boost::shared_ptr< Core::Data::FCHierarchy > } return nullptr; } -boost::shared_ptr< Core::Data::FCReputation > +Core::Data::ExdDataGenerated::FCProfilePtr + Core::Data::ExdDataGenerated::getFCProfile( uint32_t FCProfileId ) +{ + try + { + auto row = m_FCProfileDat.get_row( FCProfileId ); + auto info = boost::make_shared< FCProfile >( FCProfileId, this ); + return info; + } + catch( ... ) + { + return nullptr; + } + return nullptr; +} +Core::Data::ExdDataGenerated::FCReputationPtr Core::Data::ExdDataGenerated::getFCReputation( uint32_t FCReputationId ) { try @@ -6067,7 +6161,7 @@ boost::shared_ptr< Core::Data::FCReputation > } return nullptr; } -boost::shared_ptr< Core::Data::FCRights > +Core::Data::ExdDataGenerated::FCRightsPtr Core::Data::ExdDataGenerated::getFCRights( uint32_t FCRightsId ) { try @@ -6082,7 +6176,7 @@ boost::shared_ptr< Core::Data::FCRights > } return nullptr; } -boost::shared_ptr< Core::Data::FishingSpot > +Core::Data::ExdDataGenerated::FishingSpotPtr Core::Data::ExdDataGenerated::getFishingSpot( uint32_t FishingSpotId ) { try @@ -6097,7 +6191,7 @@ boost::shared_ptr< Core::Data::FishingSpot > } return nullptr; } -boost::shared_ptr< Core::Data::FishParameter > +Core::Data::ExdDataGenerated::FishParameterPtr Core::Data::ExdDataGenerated::getFishParameter( uint32_t FishParameterId ) { try @@ -6112,7 +6206,7 @@ boost::shared_ptr< Core::Data::FishParameter > } return nullptr; } -boost::shared_ptr< Core::Data::GardeningSeed > +Core::Data::ExdDataGenerated::GardeningSeedPtr Core::Data::ExdDataGenerated::getGardeningSeed( uint32_t GardeningSeedId ) { try @@ -6127,7 +6221,7 @@ boost::shared_ptr< Core::Data::GardeningSeed > } return nullptr; } -boost::shared_ptr< Core::Data::GatheringCondition > +Core::Data::ExdDataGenerated::GatheringConditionPtr Core::Data::ExdDataGenerated::getGatheringCondition( uint32_t GatheringConditionId ) { try @@ -6142,7 +6236,7 @@ boost::shared_ptr< Core::Data::GatheringCondition > } return nullptr; } -boost::shared_ptr< Core::Data::GatheringExp > +Core::Data::ExdDataGenerated::GatheringExpPtr Core::Data::ExdDataGenerated::getGatheringExp( uint32_t GatheringExpId ) { try @@ -6157,7 +6251,7 @@ boost::shared_ptr< Core::Data::GatheringExp > } return nullptr; } -boost::shared_ptr< Core::Data::GatheringItem > +Core::Data::ExdDataGenerated::GatheringItemPtr Core::Data::ExdDataGenerated::getGatheringItem( uint32_t GatheringItemId ) { try @@ -6172,7 +6266,7 @@ boost::shared_ptr< Core::Data::GatheringItem > } return nullptr; } -boost::shared_ptr< Core::Data::GatheringItemLevelConvertTable > +Core::Data::ExdDataGenerated::GatheringItemLevelConvertTablePtr Core::Data::ExdDataGenerated::getGatheringItemLevelConvertTable( uint32_t GatheringItemLevelConvertTableId ) { try @@ -6187,7 +6281,7 @@ boost::shared_ptr< Core::Data::GatheringItemLevelConvertTable > } return nullptr; } -boost::shared_ptr< Core::Data::GatheringItemPoint > +Core::Data::ExdDataGenerated::GatheringItemPointPtr Core::Data::ExdDataGenerated::getGatheringItemPoint( uint32_t GatheringItemPointId ) { try @@ -6202,7 +6296,7 @@ boost::shared_ptr< Core::Data::GatheringItemPoint > } return nullptr; } -boost::shared_ptr< Core::Data::GatheringNotebookList > +Core::Data::ExdDataGenerated::GatheringNotebookListPtr Core::Data::ExdDataGenerated::getGatheringNotebookList( uint32_t GatheringNotebookListId ) { try @@ -6217,7 +6311,7 @@ boost::shared_ptr< Core::Data::GatheringNotebookList > } return nullptr; } -boost::shared_ptr< Core::Data::GatheringPoint > +Core::Data::ExdDataGenerated::GatheringPointPtr Core::Data::ExdDataGenerated::getGatheringPoint( uint32_t GatheringPointId ) { try @@ -6232,7 +6326,7 @@ boost::shared_ptr< Core::Data::GatheringPoint > } return nullptr; } -boost::shared_ptr< Core::Data::GatheringPointBase > +Core::Data::ExdDataGenerated::GatheringPointBasePtr Core::Data::ExdDataGenerated::getGatheringPointBase( uint32_t GatheringPointBaseId ) { try @@ -6247,7 +6341,7 @@ boost::shared_ptr< Core::Data::GatheringPointBase > } return nullptr; } -boost::shared_ptr< Core::Data::GatheringPointBonus > +Core::Data::ExdDataGenerated::GatheringPointBonusPtr Core::Data::ExdDataGenerated::getGatheringPointBonus( uint32_t GatheringPointBonusId ) { try @@ -6262,7 +6356,7 @@ boost::shared_ptr< Core::Data::GatheringPointBonus > } return nullptr; } -boost::shared_ptr< Core::Data::GatheringPointBonusType > +Core::Data::ExdDataGenerated::GatheringPointBonusTypePtr Core::Data::ExdDataGenerated::getGatheringPointBonusType( uint32_t GatheringPointBonusTypeId ) { try @@ -6277,7 +6371,7 @@ boost::shared_ptr< Core::Data::GatheringPointBonusType > } return nullptr; } -boost::shared_ptr< Core::Data::GatheringPointName > +Core::Data::ExdDataGenerated::GatheringPointNamePtr Core::Data::ExdDataGenerated::getGatheringPointName( uint32_t GatheringPointNameId ) { try @@ -6292,7 +6386,7 @@ boost::shared_ptr< Core::Data::GatheringPointName > } return nullptr; } -boost::shared_ptr< Core::Data::GatheringSubCategory > +Core::Data::ExdDataGenerated::GatheringSubCategoryPtr Core::Data::ExdDataGenerated::getGatheringSubCategory( uint32_t GatheringSubCategoryId ) { try @@ -6307,7 +6401,7 @@ boost::shared_ptr< Core::Data::GatheringSubCategory > } return nullptr; } -boost::shared_ptr< Core::Data::GatheringType > +Core::Data::ExdDataGenerated::GatheringTypePtr Core::Data::ExdDataGenerated::getGatheringType( uint32_t GatheringTypeId ) { try @@ -6322,7 +6416,7 @@ boost::shared_ptr< Core::Data::GatheringType > } return nullptr; } -boost::shared_ptr< Core::Data::GcArmyExpedition > +Core::Data::ExdDataGenerated::GcArmyExpeditionPtr Core::Data::ExdDataGenerated::getGcArmyExpedition( uint32_t GcArmyExpeditionId ) { try @@ -6337,7 +6431,7 @@ boost::shared_ptr< Core::Data::GcArmyExpedition > } return nullptr; } -boost::shared_ptr< Core::Data::GcArmyExpeditionMemberBonus > +Core::Data::ExdDataGenerated::GcArmyExpeditionMemberBonusPtr Core::Data::ExdDataGenerated::getGcArmyExpeditionMemberBonus( uint32_t GcArmyExpeditionMemberBonusId ) { try @@ -6352,7 +6446,7 @@ boost::shared_ptr< Core::Data::GcArmyExpeditionMemberBonus > } return nullptr; } -boost::shared_ptr< Core::Data::GcArmyExpeditionType > +Core::Data::ExdDataGenerated::GcArmyExpeditionTypePtr Core::Data::ExdDataGenerated::getGcArmyExpeditionType( uint32_t GcArmyExpeditionTypeId ) { try @@ -6367,7 +6461,7 @@ boost::shared_ptr< Core::Data::GcArmyExpeditionType > } return nullptr; } -boost::shared_ptr< Core::Data::GcArmyMemberGrow > +Core::Data::ExdDataGenerated::GcArmyMemberGrowPtr Core::Data::ExdDataGenerated::getGcArmyMemberGrow( uint32_t GcArmyMemberGrowId ) { try @@ -6382,7 +6476,7 @@ boost::shared_ptr< Core::Data::GcArmyMemberGrow > } return nullptr; } -boost::shared_ptr< Core::Data::GcArmyTraining > +Core::Data::ExdDataGenerated::GcArmyTrainingPtr Core::Data::ExdDataGenerated::getGcArmyTraining( uint32_t GcArmyTrainingId ) { try @@ -6397,7 +6491,97 @@ boost::shared_ptr< Core::Data::GcArmyTraining > } return nullptr; } -boost::shared_ptr< Core::Data::GCScripShopCategory > +Core::Data::ExdDataGenerated::GCRankGridaniaFemaleTextPtr + Core::Data::ExdDataGenerated::getGCRankGridaniaFemaleText( uint32_t GCRankGridaniaFemaleTextId ) +{ + try + { + auto row = m_GCRankGridaniaFemaleTextDat.get_row( GCRankGridaniaFemaleTextId ); + auto info = boost::make_shared< GCRankGridaniaFemaleText >( GCRankGridaniaFemaleTextId, this ); + return info; + } + catch( ... ) + { + return nullptr; + } + return nullptr; +} +Core::Data::ExdDataGenerated::GCRankGridaniaMaleTextPtr + Core::Data::ExdDataGenerated::getGCRankGridaniaMaleText( uint32_t GCRankGridaniaMaleTextId ) +{ + try + { + auto row = m_GCRankGridaniaMaleTextDat.get_row( GCRankGridaniaMaleTextId ); + auto info = boost::make_shared< GCRankGridaniaMaleText >( GCRankGridaniaMaleTextId, this ); + return info; + } + catch( ... ) + { + return nullptr; + } + return nullptr; +} +Core::Data::ExdDataGenerated::GCRankLimsaFemaleTextPtr + Core::Data::ExdDataGenerated::getGCRankLimsaFemaleText( uint32_t GCRankLimsaFemaleTextId ) +{ + try + { + auto row = m_GCRankLimsaFemaleTextDat.get_row( GCRankLimsaFemaleTextId ); + auto info = boost::make_shared< GCRankLimsaFemaleText >( GCRankLimsaFemaleTextId, this ); + return info; + } + catch( ... ) + { + return nullptr; + } + return nullptr; +} +Core::Data::ExdDataGenerated::GCRankLimsaMaleTextPtr + Core::Data::ExdDataGenerated::getGCRankLimsaMaleText( uint32_t GCRankLimsaMaleTextId ) +{ + try + { + auto row = m_GCRankLimsaMaleTextDat.get_row( GCRankLimsaMaleTextId ); + auto info = boost::make_shared< GCRankLimsaMaleText >( GCRankLimsaMaleTextId, this ); + return info; + } + catch( ... ) + { + return nullptr; + } + return nullptr; +} +Core::Data::ExdDataGenerated::GCRankUldahFemaleTextPtr + Core::Data::ExdDataGenerated::getGCRankUldahFemaleText( uint32_t GCRankUldahFemaleTextId ) +{ + try + { + auto row = m_GCRankUldahFemaleTextDat.get_row( GCRankUldahFemaleTextId ); + auto info = boost::make_shared< GCRankUldahFemaleText >( GCRankUldahFemaleTextId, this ); + return info; + } + catch( ... ) + { + return nullptr; + } + return nullptr; +} +Core::Data::ExdDataGenerated::GCRankUldahMaleTextPtr + Core::Data::ExdDataGenerated::getGCRankUldahMaleText( uint32_t GCRankUldahMaleTextId ) +{ + try + { + auto row = m_GCRankUldahMaleTextDat.get_row( GCRankUldahMaleTextId ); + auto info = boost::make_shared< GCRankUldahMaleText >( GCRankUldahMaleTextId, this ); + return info; + } + catch( ... ) + { + return nullptr; + } + return nullptr; +} +Core::Data::ExdDataGenerated::GCScripShopCategoryPtr Core::Data::ExdDataGenerated::getGCScripShopCategory( uint32_t GCScripShopCategoryId ) { try @@ -6412,7 +6596,7 @@ boost::shared_ptr< Core::Data::GCScripShopCategory > } return nullptr; } -boost::shared_ptr< Core::Data::GCScripShopItem > +Core::Data::ExdDataGenerated::GCScripShopItemPtr Core::Data::ExdDataGenerated::getGCScripShopItem( uint32_t GCScripShopItemId ) { try @@ -6427,7 +6611,7 @@ boost::shared_ptr< Core::Data::GCScripShopItem > } return nullptr; } -boost::shared_ptr< Core::Data::GCShop > +Core::Data::ExdDataGenerated::GCShopPtr Core::Data::ExdDataGenerated::getGCShop( uint32_t GCShopId ) { try @@ -6442,7 +6626,7 @@ boost::shared_ptr< Core::Data::GCShop > } return nullptr; } -boost::shared_ptr< Core::Data::GCShopItemCategory > +Core::Data::ExdDataGenerated::GCShopItemCategoryPtr Core::Data::ExdDataGenerated::getGCShopItemCategory( uint32_t GCShopItemCategoryId ) { try @@ -6457,7 +6641,7 @@ boost::shared_ptr< Core::Data::GCShopItemCategory > } return nullptr; } -boost::shared_ptr< Core::Data::GCSupplyDuty > +Core::Data::ExdDataGenerated::GCSupplyDutyPtr Core::Data::ExdDataGenerated::getGCSupplyDuty( uint32_t GCSupplyDutyId ) { try @@ -6472,7 +6656,7 @@ boost::shared_ptr< Core::Data::GCSupplyDuty > } return nullptr; } -boost::shared_ptr< Core::Data::GCSupplyDutyReward > +Core::Data::ExdDataGenerated::GCSupplyDutyRewardPtr Core::Data::ExdDataGenerated::getGCSupplyDutyReward( uint32_t GCSupplyDutyRewardId ) { try @@ -6487,7 +6671,7 @@ boost::shared_ptr< Core::Data::GCSupplyDutyReward > } return nullptr; } -boost::shared_ptr< Core::Data::GeneralAction > +Core::Data::ExdDataGenerated::GeneralActionPtr Core::Data::ExdDataGenerated::getGeneralAction( uint32_t GeneralActionId ) { try @@ -6502,7 +6686,7 @@ boost::shared_ptr< Core::Data::GeneralAction > } return nullptr; } -boost::shared_ptr< Core::Data::GilShop > +Core::Data::ExdDataGenerated::GilShopPtr Core::Data::ExdDataGenerated::getGilShop( uint32_t GilShopId ) { try @@ -6517,7 +6701,7 @@ boost::shared_ptr< Core::Data::GilShop > } return nullptr; } -boost::shared_ptr< Core::Data::GilShopItem > +Core::Data::ExdDataGenerated::GilShopItemPtr Core::Data::ExdDataGenerated::getGilShopItem( uint32_t GilShopItemId ) { try @@ -6532,7 +6716,7 @@ boost::shared_ptr< Core::Data::GilShopItem > } return nullptr; } -boost::shared_ptr< Core::Data::GoldSaucerTextData > +Core::Data::ExdDataGenerated::GoldSaucerTextDataPtr Core::Data::ExdDataGenerated::getGoldSaucerTextData( uint32_t GoldSaucerTextDataId ) { try @@ -6547,7 +6731,7 @@ boost::shared_ptr< Core::Data::GoldSaucerTextData > } return nullptr; } -boost::shared_ptr< Core::Data::GrandCompany > +Core::Data::ExdDataGenerated::GrandCompanyPtr Core::Data::ExdDataGenerated::getGrandCompany( uint32_t GrandCompanyId ) { try @@ -6562,7 +6746,7 @@ boost::shared_ptr< Core::Data::GrandCompany > } return nullptr; } -boost::shared_ptr< Core::Data::GrandCompanyRank > +Core::Data::ExdDataGenerated::GrandCompanyRankPtr Core::Data::ExdDataGenerated::getGrandCompanyRank( uint32_t GrandCompanyRankId ) { try @@ -6577,7 +6761,7 @@ boost::shared_ptr< Core::Data::GrandCompanyRank > } return nullptr; } -boost::shared_ptr< Core::Data::GuardianDeity > +Core::Data::ExdDataGenerated::GuardianDeityPtr Core::Data::ExdDataGenerated::getGuardianDeity( uint32_t GuardianDeityId ) { try @@ -6592,7 +6776,7 @@ boost::shared_ptr< Core::Data::GuardianDeity > } return nullptr; } -boost::shared_ptr< Core::Data::GuildleveAssignment > +Core::Data::ExdDataGenerated::GuildleveAssignmentPtr Core::Data::ExdDataGenerated::getGuildleveAssignment( uint32_t GuildleveAssignmentId ) { try @@ -6607,7 +6791,7 @@ boost::shared_ptr< Core::Data::GuildleveAssignment > } return nullptr; } -boost::shared_ptr< Core::Data::GuildOrderGuide > +Core::Data::ExdDataGenerated::GuildOrderGuidePtr Core::Data::ExdDataGenerated::getGuildOrderGuide( uint32_t GuildOrderGuideId ) { try @@ -6622,7 +6806,7 @@ boost::shared_ptr< Core::Data::GuildOrderGuide > } return nullptr; } -boost::shared_ptr< Core::Data::GuildOrderOfficer > +Core::Data::ExdDataGenerated::GuildOrderOfficerPtr Core::Data::ExdDataGenerated::getGuildOrderOfficer( uint32_t GuildOrderOfficerId ) { try @@ -6637,7 +6821,7 @@ boost::shared_ptr< Core::Data::GuildOrderOfficer > } return nullptr; } -boost::shared_ptr< Core::Data::HouseRetainerPose > +Core::Data::ExdDataGenerated::HouseRetainerPosePtr Core::Data::ExdDataGenerated::getHouseRetainerPose( uint32_t HouseRetainerPoseId ) { try @@ -6652,7 +6836,7 @@ boost::shared_ptr< Core::Data::HouseRetainerPose > } return nullptr; } -boost::shared_ptr< Core::Data::HousingFurniture > +Core::Data::ExdDataGenerated::HousingFurniturePtr Core::Data::ExdDataGenerated::getHousingFurniture( uint32_t HousingFurnitureId ) { try @@ -6667,7 +6851,7 @@ boost::shared_ptr< Core::Data::HousingFurniture > } return nullptr; } -boost::shared_ptr< Core::Data::HousingYardObject > +Core::Data::ExdDataGenerated::HousingYardObjectPtr Core::Data::ExdDataGenerated::getHousingYardObject( uint32_t HousingYardObjectId ) { try @@ -6682,7 +6866,7 @@ boost::shared_ptr< Core::Data::HousingYardObject > } return nullptr; } -boost::shared_ptr< Core::Data::InstanceContent > +Core::Data::ExdDataGenerated::InstanceContentPtr Core::Data::ExdDataGenerated::getInstanceContent( uint32_t InstanceContentId ) { try @@ -6697,7 +6881,7 @@ boost::shared_ptr< Core::Data::InstanceContent > } return nullptr; } -boost::shared_ptr< Core::Data::InstanceContentBuff > +Core::Data::ExdDataGenerated::InstanceContentBuffPtr Core::Data::ExdDataGenerated::getInstanceContentBuff( uint32_t InstanceContentBuffId ) { try @@ -6712,7 +6896,7 @@ boost::shared_ptr< Core::Data::InstanceContentBuff > } return nullptr; } -boost::shared_ptr< Core::Data::InstanceContentTextData > +Core::Data::ExdDataGenerated::InstanceContentTextDataPtr Core::Data::ExdDataGenerated::getInstanceContentTextData( uint32_t InstanceContentTextDataId ) { try @@ -6727,7 +6911,7 @@ boost::shared_ptr< Core::Data::InstanceContentTextData > } return nullptr; } -boost::shared_ptr< Core::Data::InstanceContentType > +Core::Data::ExdDataGenerated::InstanceContentTypePtr Core::Data::ExdDataGenerated::getInstanceContentType( uint32_t InstanceContentTypeId ) { try @@ -6742,7 +6926,7 @@ boost::shared_ptr< Core::Data::InstanceContentType > } return nullptr; } -boost::shared_ptr< Core::Data::Item > +Core::Data::ExdDataGenerated::ItemPtr Core::Data::ExdDataGenerated::getItem( uint32_t ItemId ) { try @@ -6757,7 +6941,7 @@ boost::shared_ptr< Core::Data::Item > } return nullptr; } -boost::shared_ptr< Core::Data::ItemAction > +Core::Data::ExdDataGenerated::ItemActionPtr Core::Data::ExdDataGenerated::getItemAction( uint32_t ItemActionId ) { try @@ -6772,7 +6956,7 @@ boost::shared_ptr< Core::Data::ItemAction > } return nullptr; } -boost::shared_ptr< Core::Data::ItemFood > +Core::Data::ExdDataGenerated::ItemFoodPtr Core::Data::ExdDataGenerated::getItemFood( uint32_t ItemFoodId ) { try @@ -6787,7 +6971,7 @@ boost::shared_ptr< Core::Data::ItemFood > } return nullptr; } -boost::shared_ptr< Core::Data::ItemSearchCategory > +Core::Data::ExdDataGenerated::ItemSearchCategoryPtr Core::Data::ExdDataGenerated::getItemSearchCategory( uint32_t ItemSearchCategoryId ) { try @@ -6802,7 +6986,7 @@ boost::shared_ptr< Core::Data::ItemSearchCategory > } return nullptr; } -boost::shared_ptr< Core::Data::ItemSeries > +Core::Data::ExdDataGenerated::ItemSeriesPtr Core::Data::ExdDataGenerated::getItemSeries( uint32_t ItemSeriesId ) { try @@ -6817,7 +7001,7 @@ boost::shared_ptr< Core::Data::ItemSeries > } return nullptr; } -boost::shared_ptr< Core::Data::ItemSpecialBonus > +Core::Data::ExdDataGenerated::ItemSpecialBonusPtr Core::Data::ExdDataGenerated::getItemSpecialBonus( uint32_t ItemSpecialBonusId ) { try @@ -6832,7 +7016,7 @@ boost::shared_ptr< Core::Data::ItemSpecialBonus > } return nullptr; } -boost::shared_ptr< Core::Data::ItemUICategory > +Core::Data::ExdDataGenerated::ItemUICategoryPtr Core::Data::ExdDataGenerated::getItemUICategory( uint32_t ItemUICategoryId ) { try @@ -6847,7 +7031,7 @@ boost::shared_ptr< Core::Data::ItemUICategory > } return nullptr; } -boost::shared_ptr< Core::Data::JournalCategory > +Core::Data::ExdDataGenerated::JournalCategoryPtr Core::Data::ExdDataGenerated::getJournalCategory( uint32_t JournalCategoryId ) { try @@ -6862,7 +7046,7 @@ boost::shared_ptr< Core::Data::JournalCategory > } return nullptr; } -boost::shared_ptr< Core::Data::JournalGenre > +Core::Data::ExdDataGenerated::JournalGenrePtr Core::Data::ExdDataGenerated::getJournalGenre( uint32_t JournalGenreId ) { try @@ -6877,7 +7061,7 @@ boost::shared_ptr< Core::Data::JournalGenre > } return nullptr; } -boost::shared_ptr< Core::Data::JournalSection > +Core::Data::ExdDataGenerated::JournalSectionPtr Core::Data::ExdDataGenerated::getJournalSection( uint32_t JournalSectionId ) { try @@ -6892,7 +7076,7 @@ boost::shared_ptr< Core::Data::JournalSection > } return nullptr; } -boost::shared_ptr< Core::Data::Leve > +Core::Data::ExdDataGenerated::LevePtr Core::Data::ExdDataGenerated::getLeve( uint32_t LeveId ) { try @@ -6907,7 +7091,7 @@ boost::shared_ptr< Core::Data::Leve > } return nullptr; } -boost::shared_ptr< Core::Data::LeveAssignmentType > +Core::Data::ExdDataGenerated::LeveAssignmentTypePtr Core::Data::ExdDataGenerated::getLeveAssignmentType( uint32_t LeveAssignmentTypeId ) { try @@ -6922,7 +7106,7 @@ boost::shared_ptr< Core::Data::LeveAssignmentType > } return nullptr; } -boost::shared_ptr< Core::Data::LeveClient > +Core::Data::ExdDataGenerated::LeveClientPtr Core::Data::ExdDataGenerated::getLeveClient( uint32_t LeveClientId ) { try @@ -6937,7 +7121,7 @@ boost::shared_ptr< Core::Data::LeveClient > } return nullptr; } -boost::shared_ptr< Core::Data::Level > +Core::Data::ExdDataGenerated::LevelPtr Core::Data::ExdDataGenerated::getLevel( uint32_t LevelId ) { try @@ -6952,7 +7136,7 @@ boost::shared_ptr< Core::Data::Level > } return nullptr; } -boost::shared_ptr< Core::Data::LeveRewardItem > +Core::Data::ExdDataGenerated::LeveRewardItemPtr Core::Data::ExdDataGenerated::getLeveRewardItem( uint32_t LeveRewardItemId ) { try @@ -6967,7 +7151,7 @@ boost::shared_ptr< Core::Data::LeveRewardItem > } return nullptr; } -boost::shared_ptr< Core::Data::LeveRewardItemGroup > +Core::Data::ExdDataGenerated::LeveRewardItemGroupPtr Core::Data::ExdDataGenerated::getLeveRewardItemGroup( uint32_t LeveRewardItemGroupId ) { try @@ -6982,7 +7166,7 @@ boost::shared_ptr< Core::Data::LeveRewardItemGroup > } return nullptr; } -boost::shared_ptr< Core::Data::LeveVfx > +Core::Data::ExdDataGenerated::LeveVfxPtr Core::Data::ExdDataGenerated::getLeveVfx( uint32_t LeveVfxId ) { try @@ -6997,7 +7181,7 @@ boost::shared_ptr< Core::Data::LeveVfx > } return nullptr; } -boost::shared_ptr< Core::Data::LogFilter > +Core::Data::ExdDataGenerated::LogFilterPtr Core::Data::ExdDataGenerated::getLogFilter( uint32_t LogFilterId ) { try @@ -7012,7 +7196,7 @@ boost::shared_ptr< Core::Data::LogFilter > } return nullptr; } -boost::shared_ptr< Core::Data::LogKind > +Core::Data::ExdDataGenerated::LogKindPtr Core::Data::ExdDataGenerated::getLogKind( uint32_t LogKindId ) { try @@ -7027,7 +7211,7 @@ boost::shared_ptr< Core::Data::LogKind > } return nullptr; } -boost::shared_ptr< Core::Data::LogKindCategoryText > +Core::Data::ExdDataGenerated::LogKindCategoryTextPtr Core::Data::ExdDataGenerated::getLogKindCategoryText( uint32_t LogKindCategoryTextId ) { try @@ -7042,7 +7226,7 @@ boost::shared_ptr< Core::Data::LogKindCategoryText > } return nullptr; } -boost::shared_ptr< Core::Data::LogMessage > +Core::Data::ExdDataGenerated::LogMessagePtr Core::Data::ExdDataGenerated::getLogMessage( uint32_t LogMessageId ) { try @@ -7057,7 +7241,7 @@ boost::shared_ptr< Core::Data::LogMessage > } return nullptr; } -boost::shared_ptr< Core::Data::MacroIcon > +Core::Data::ExdDataGenerated::MacroIconPtr Core::Data::ExdDataGenerated::getMacroIcon( uint32_t MacroIconId ) { try @@ -7072,7 +7256,7 @@ boost::shared_ptr< Core::Data::MacroIcon > } return nullptr; } -boost::shared_ptr< Core::Data::MacroIconRedirectOld > +Core::Data::ExdDataGenerated::MacroIconRedirectOldPtr Core::Data::ExdDataGenerated::getMacroIconRedirectOld( uint32_t MacroIconRedirectOldId ) { try @@ -7087,7 +7271,7 @@ boost::shared_ptr< Core::Data::MacroIconRedirectOld > } return nullptr; } -boost::shared_ptr< Core::Data::MainCommand > +Core::Data::ExdDataGenerated::MainCommandPtr Core::Data::ExdDataGenerated::getMainCommand( uint32_t MainCommandId ) { try @@ -7102,7 +7286,7 @@ boost::shared_ptr< Core::Data::MainCommand > } return nullptr; } -boost::shared_ptr< Core::Data::MainCommandCategory > +Core::Data::ExdDataGenerated::MainCommandCategoryPtr Core::Data::ExdDataGenerated::getMainCommandCategory( uint32_t MainCommandCategoryId ) { try @@ -7117,7 +7301,7 @@ boost::shared_ptr< Core::Data::MainCommandCategory > } return nullptr; } -boost::shared_ptr< Core::Data::Map > +Core::Data::ExdDataGenerated::MapPtr Core::Data::ExdDataGenerated::getMap( uint32_t MapId ) { try @@ -7132,7 +7316,7 @@ boost::shared_ptr< Core::Data::Map > } return nullptr; } -boost::shared_ptr< Core::Data::MapMarker > +Core::Data::ExdDataGenerated::MapMarkerPtr Core::Data::ExdDataGenerated::getMapMarker( uint32_t MapMarkerId ) { try @@ -7147,7 +7331,7 @@ boost::shared_ptr< Core::Data::MapMarker > } return nullptr; } -boost::shared_ptr< Core::Data::MapSymbol > +Core::Data::ExdDataGenerated::MapSymbolPtr Core::Data::ExdDataGenerated::getMapSymbol( uint32_t MapSymbolId ) { try @@ -7162,7 +7346,7 @@ boost::shared_ptr< Core::Data::MapSymbol > } return nullptr; } -boost::shared_ptr< Core::Data::MasterpieceSupplyDuty > +Core::Data::ExdDataGenerated::MasterpieceSupplyDutyPtr Core::Data::ExdDataGenerated::getMasterpieceSupplyDuty( uint32_t MasterpieceSupplyDutyId ) { try @@ -7177,7 +7361,7 @@ boost::shared_ptr< Core::Data::MasterpieceSupplyDuty > } return nullptr; } -boost::shared_ptr< Core::Data::MasterpieceSupplyMultiplier > +Core::Data::ExdDataGenerated::MasterpieceSupplyMultiplierPtr Core::Data::ExdDataGenerated::getMasterpieceSupplyMultiplier( uint32_t MasterpieceSupplyMultiplierId ) { try @@ -7192,7 +7376,7 @@ boost::shared_ptr< Core::Data::MasterpieceSupplyMultiplier > } return nullptr; } -boost::shared_ptr< Core::Data::Materia > +Core::Data::ExdDataGenerated::MateriaPtr Core::Data::ExdDataGenerated::getMateria( uint32_t MateriaId ) { try @@ -7207,7 +7391,7 @@ boost::shared_ptr< Core::Data::Materia > } return nullptr; } -boost::shared_ptr< Core::Data::MinionRace > +Core::Data::ExdDataGenerated::MinionRacePtr Core::Data::ExdDataGenerated::getMinionRace( uint32_t MinionRaceId ) { try @@ -7222,7 +7406,7 @@ boost::shared_ptr< Core::Data::MinionRace > } return nullptr; } -boost::shared_ptr< Core::Data::MinionRules > +Core::Data::ExdDataGenerated::MinionRulesPtr Core::Data::ExdDataGenerated::getMinionRules( uint32_t MinionRulesId ) { try @@ -7237,7 +7421,7 @@ boost::shared_ptr< Core::Data::MinionRules > } return nullptr; } -boost::shared_ptr< Core::Data::MinionSkillType > +Core::Data::ExdDataGenerated::MinionSkillTypePtr Core::Data::ExdDataGenerated::getMinionSkillType( uint32_t MinionSkillTypeId ) { try @@ -7252,7 +7436,7 @@ boost::shared_ptr< Core::Data::MinionSkillType > } return nullptr; } -boost::shared_ptr< Core::Data::MobHuntTarget > +Core::Data::ExdDataGenerated::MobHuntTargetPtr Core::Data::ExdDataGenerated::getMobHuntTarget( uint32_t MobHuntTargetId ) { try @@ -7267,7 +7451,7 @@ boost::shared_ptr< Core::Data::MobHuntTarget > } return nullptr; } -boost::shared_ptr< Core::Data::ModelChara > +Core::Data::ExdDataGenerated::ModelCharaPtr Core::Data::ExdDataGenerated::getModelChara( uint32_t ModelCharaId ) { try @@ -7282,7 +7466,7 @@ boost::shared_ptr< Core::Data::ModelChara > } return nullptr; } -boost::shared_ptr< Core::Data::MonsterNote > +Core::Data::ExdDataGenerated::MonsterNotePtr Core::Data::ExdDataGenerated::getMonsterNote( uint32_t MonsterNoteId ) { try @@ -7297,7 +7481,7 @@ boost::shared_ptr< Core::Data::MonsterNote > } return nullptr; } -boost::shared_ptr< Core::Data::MonsterNoteTarget > +Core::Data::ExdDataGenerated::MonsterNoteTargetPtr Core::Data::ExdDataGenerated::getMonsterNoteTarget( uint32_t MonsterNoteTargetId ) { try @@ -7312,7 +7496,7 @@ boost::shared_ptr< Core::Data::MonsterNoteTarget > } return nullptr; } -boost::shared_ptr< Core::Data::Mount > +Core::Data::ExdDataGenerated::MountPtr Core::Data::ExdDataGenerated::getMount( uint32_t MountId ) { try @@ -7327,7 +7511,7 @@ boost::shared_ptr< Core::Data::Mount > } return nullptr; } -boost::shared_ptr< Core::Data::MountAction > +Core::Data::ExdDataGenerated::MountActionPtr Core::Data::ExdDataGenerated::getMountAction( uint32_t MountActionId ) { try @@ -7342,7 +7526,7 @@ boost::shared_ptr< Core::Data::MountAction > } return nullptr; } -boost::shared_ptr< Core::Data::NpcEquip > +Core::Data::ExdDataGenerated::NpcEquipPtr Core::Data::ExdDataGenerated::getNpcEquip( uint32_t NpcEquipId ) { try @@ -7357,7 +7541,7 @@ boost::shared_ptr< Core::Data::NpcEquip > } return nullptr; } -boost::shared_ptr< Core::Data::Omen > +Core::Data::ExdDataGenerated::OmenPtr Core::Data::ExdDataGenerated::getOmen( uint32_t OmenId ) { try @@ -7372,7 +7556,7 @@ boost::shared_ptr< Core::Data::Omen > } return nullptr; } -boost::shared_ptr< Core::Data::OnlineStatus > +Core::Data::ExdDataGenerated::OnlineStatusPtr Core::Data::ExdDataGenerated::getOnlineStatus( uint32_t OnlineStatusId ) { try @@ -7387,7 +7571,22 @@ boost::shared_ptr< Core::Data::OnlineStatus > } return nullptr; } -boost::shared_ptr< Core::Data::Orchestrion > +Core::Data::ExdDataGenerated::OpeningPtr + Core::Data::ExdDataGenerated::getOpening( uint32_t OpeningId ) +{ + try + { + auto row = m_OpeningDat.get_row( OpeningId ); + auto info = boost::make_shared< Opening >( OpeningId, this ); + return info; + } + catch( ... ) + { + return nullptr; + } + return nullptr; +} +Core::Data::ExdDataGenerated::OrchestrionPtr Core::Data::ExdDataGenerated::getOrchestrion( uint32_t OrchestrionId ) { try @@ -7402,7 +7601,7 @@ boost::shared_ptr< Core::Data::Orchestrion > } return nullptr; } -boost::shared_ptr< Core::Data::OrchestrionPath > +Core::Data::ExdDataGenerated::OrchestrionPathPtr Core::Data::ExdDataGenerated::getOrchestrionPath( uint32_t OrchestrionPathId ) { try @@ -7417,7 +7616,7 @@ boost::shared_ptr< Core::Data::OrchestrionPath > } return nullptr; } -boost::shared_ptr< Core::Data::ParamGrow > +Core::Data::ExdDataGenerated::ParamGrowPtr Core::Data::ExdDataGenerated::getParamGrow( uint32_t ParamGrowId ) { try @@ -7432,7 +7631,7 @@ boost::shared_ptr< Core::Data::ParamGrow > } return nullptr; } -boost::shared_ptr< Core::Data::Pet > +Core::Data::ExdDataGenerated::PetPtr Core::Data::ExdDataGenerated::getPet( uint32_t PetId ) { try @@ -7447,7 +7646,7 @@ boost::shared_ptr< Core::Data::Pet > } return nullptr; } -boost::shared_ptr< Core::Data::PetAction > +Core::Data::ExdDataGenerated::PetActionPtr Core::Data::ExdDataGenerated::getPetAction( uint32_t PetActionId ) { try @@ -7462,7 +7661,7 @@ boost::shared_ptr< Core::Data::PetAction > } return nullptr; } -boost::shared_ptr< Core::Data::Picture > +Core::Data::ExdDataGenerated::PicturePtr Core::Data::ExdDataGenerated::getPicture( uint32_t PictureId ) { try @@ -7477,7 +7676,7 @@ boost::shared_ptr< Core::Data::Picture > } return nullptr; } -boost::shared_ptr< Core::Data::PlaceName > +Core::Data::ExdDataGenerated::PlaceNamePtr Core::Data::ExdDataGenerated::getPlaceName( uint32_t PlaceNameId ) { try @@ -7492,7 +7691,7 @@ boost::shared_ptr< Core::Data::PlaceName > } return nullptr; } -boost::shared_ptr< Core::Data::Quest > +Core::Data::ExdDataGenerated::QuestPtr Core::Data::ExdDataGenerated::getQuest( uint32_t QuestId ) { try @@ -7507,7 +7706,7 @@ boost::shared_ptr< Core::Data::Quest > } return nullptr; } -boost::shared_ptr< Core::Data::QuestRewardOther > +Core::Data::ExdDataGenerated::QuestRewardOtherPtr Core::Data::ExdDataGenerated::getQuestRewardOther( uint32_t QuestRewardOtherId ) { try @@ -7522,7 +7721,7 @@ boost::shared_ptr< Core::Data::QuestRewardOther > } return nullptr; } -boost::shared_ptr< Core::Data::Race > +Core::Data::ExdDataGenerated::RacePtr Core::Data::ExdDataGenerated::getRace( uint32_t RaceId ) { try @@ -7537,7 +7736,7 @@ boost::shared_ptr< Core::Data::Race > } return nullptr; } -boost::shared_ptr< Core::Data::RacingChocoboItem > +Core::Data::ExdDataGenerated::RacingChocoboItemPtr Core::Data::ExdDataGenerated::getRacingChocoboItem( uint32_t RacingChocoboItemId ) { try @@ -7552,7 +7751,7 @@ boost::shared_ptr< Core::Data::RacingChocoboItem > } return nullptr; } -boost::shared_ptr< Core::Data::RacingChocoboName > +Core::Data::ExdDataGenerated::RacingChocoboNamePtr Core::Data::ExdDataGenerated::getRacingChocoboName( uint32_t RacingChocoboNameId ) { try @@ -7567,7 +7766,7 @@ boost::shared_ptr< Core::Data::RacingChocoboName > } return nullptr; } -boost::shared_ptr< Core::Data::RacingChocoboNameCategory > +Core::Data::ExdDataGenerated::RacingChocoboNameCategoryPtr Core::Data::ExdDataGenerated::getRacingChocoboNameCategory( uint32_t RacingChocoboNameCategoryId ) { try @@ -7582,7 +7781,7 @@ boost::shared_ptr< Core::Data::RacingChocoboNameCategory > } return nullptr; } -boost::shared_ptr< Core::Data::RacingChocoboNameInfo > +Core::Data::ExdDataGenerated::RacingChocoboNameInfoPtr Core::Data::ExdDataGenerated::getRacingChocoboNameInfo( uint32_t RacingChocoboNameInfoId ) { try @@ -7597,7 +7796,7 @@ boost::shared_ptr< Core::Data::RacingChocoboNameInfo > } return nullptr; } -boost::shared_ptr< Core::Data::RacingChocoboParam > +Core::Data::ExdDataGenerated::RacingChocoboParamPtr Core::Data::ExdDataGenerated::getRacingChocoboParam( uint32_t RacingChocoboParamId ) { try @@ -7612,7 +7811,7 @@ boost::shared_ptr< Core::Data::RacingChocoboParam > } return nullptr; } -boost::shared_ptr< Core::Data::Recipe > +Core::Data::ExdDataGenerated::RecipePtr Core::Data::ExdDataGenerated::getRecipe( uint32_t RecipeId ) { try @@ -7627,7 +7826,7 @@ boost::shared_ptr< Core::Data::Recipe > } return nullptr; } -boost::shared_ptr< Core::Data::RecipeElement > +Core::Data::ExdDataGenerated::RecipeElementPtr Core::Data::ExdDataGenerated::getRecipeElement( uint32_t RecipeElementId ) { try @@ -7642,7 +7841,7 @@ boost::shared_ptr< Core::Data::RecipeElement > } return nullptr; } -boost::shared_ptr< Core::Data::RecipeLevelTable > +Core::Data::ExdDataGenerated::RecipeLevelTablePtr Core::Data::ExdDataGenerated::getRecipeLevelTable( uint32_t RecipeLevelTableId ) { try @@ -7657,7 +7856,7 @@ boost::shared_ptr< Core::Data::RecipeLevelTable > } return nullptr; } -boost::shared_ptr< Core::Data::RecipeNotebookList > +Core::Data::ExdDataGenerated::RecipeNotebookListPtr Core::Data::ExdDataGenerated::getRecipeNotebookList( uint32_t RecipeNotebookListId ) { try @@ -7672,7 +7871,7 @@ boost::shared_ptr< Core::Data::RecipeNotebookList > } return nullptr; } -boost::shared_ptr< Core::Data::Relic > +Core::Data::ExdDataGenerated::RelicPtr Core::Data::ExdDataGenerated::getRelic( uint32_t RelicId ) { try @@ -7687,7 +7886,7 @@ boost::shared_ptr< Core::Data::Relic > } return nullptr; } -boost::shared_ptr< Core::Data::Relic3 > +Core::Data::ExdDataGenerated::Relic3Ptr Core::Data::ExdDataGenerated::getRelic3( uint32_t Relic3Id ) { try @@ -7702,7 +7901,7 @@ boost::shared_ptr< Core::Data::Relic3 > } return nullptr; } -boost::shared_ptr< Core::Data::RelicItem > +Core::Data::ExdDataGenerated::RelicItemPtr Core::Data::ExdDataGenerated::getRelicItem( uint32_t RelicItemId ) { try @@ -7717,7 +7916,7 @@ boost::shared_ptr< Core::Data::RelicItem > } return nullptr; } -boost::shared_ptr< Core::Data::RelicNote > +Core::Data::ExdDataGenerated::RelicNotePtr Core::Data::ExdDataGenerated::getRelicNote( uint32_t RelicNoteId ) { try @@ -7732,7 +7931,7 @@ boost::shared_ptr< Core::Data::RelicNote > } return nullptr; } -boost::shared_ptr< Core::Data::RelicNoteCategory > +Core::Data::ExdDataGenerated::RelicNoteCategoryPtr Core::Data::ExdDataGenerated::getRelicNoteCategory( uint32_t RelicNoteCategoryId ) { try @@ -7747,7 +7946,7 @@ boost::shared_ptr< Core::Data::RelicNoteCategory > } return nullptr; } -boost::shared_ptr< Core::Data::RetainerTask > +Core::Data::ExdDataGenerated::RetainerTaskPtr Core::Data::ExdDataGenerated::getRetainerTask( uint32_t RetainerTaskId ) { try @@ -7762,7 +7961,7 @@ boost::shared_ptr< Core::Data::RetainerTask > } return nullptr; } -boost::shared_ptr< Core::Data::RetainerTaskNormal > +Core::Data::ExdDataGenerated::RetainerTaskNormalPtr Core::Data::ExdDataGenerated::getRetainerTaskNormal( uint32_t RetainerTaskNormalId ) { try @@ -7777,7 +7976,7 @@ boost::shared_ptr< Core::Data::RetainerTaskNormal > } return nullptr; } -boost::shared_ptr< Core::Data::RetainerTaskParameter > +Core::Data::ExdDataGenerated::RetainerTaskParameterPtr Core::Data::ExdDataGenerated::getRetainerTaskParameter( uint32_t RetainerTaskParameterId ) { try @@ -7792,7 +7991,7 @@ boost::shared_ptr< Core::Data::RetainerTaskParameter > } return nullptr; } -boost::shared_ptr< Core::Data::RetainerTaskRandom > +Core::Data::ExdDataGenerated::RetainerTaskRandomPtr Core::Data::ExdDataGenerated::getRetainerTaskRandom( uint32_t RetainerTaskRandomId ) { try @@ -7807,7 +8006,7 @@ boost::shared_ptr< Core::Data::RetainerTaskRandom > } return nullptr; } -boost::shared_ptr< Core::Data::Salvage > +Core::Data::ExdDataGenerated::SalvagePtr Core::Data::ExdDataGenerated::getSalvage( uint32_t SalvageId ) { try @@ -7822,7 +8021,7 @@ boost::shared_ptr< Core::Data::Salvage > } return nullptr; } -boost::shared_ptr< Core::Data::SatisfactionNpc > +Core::Data::ExdDataGenerated::SatisfactionNpcPtr Core::Data::ExdDataGenerated::getSatisfactionNpc( uint32_t SatisfactionNpcId ) { try @@ -7837,7 +8036,7 @@ boost::shared_ptr< Core::Data::SatisfactionNpc > } return nullptr; } -boost::shared_ptr< Core::Data::SatisfactionSupply > +Core::Data::ExdDataGenerated::SatisfactionSupplyPtr Core::Data::ExdDataGenerated::getSatisfactionSupply( uint32_t SatisfactionSupplyId ) { try @@ -7852,7 +8051,7 @@ boost::shared_ptr< Core::Data::SatisfactionSupply > } return nullptr; } -boost::shared_ptr< Core::Data::SatisfactionSupplyReward > +Core::Data::ExdDataGenerated::SatisfactionSupplyRewardPtr Core::Data::ExdDataGenerated::getSatisfactionSupplyReward( uint32_t SatisfactionSupplyRewardId ) { try @@ -7867,7 +8066,7 @@ boost::shared_ptr< Core::Data::SatisfactionSupplyReward > } return nullptr; } -boost::shared_ptr< Core::Data::ScreenImage > +Core::Data::ExdDataGenerated::ScreenImagePtr Core::Data::ExdDataGenerated::getScreenImage( uint32_t ScreenImageId ) { try @@ -7882,7 +8081,7 @@ boost::shared_ptr< Core::Data::ScreenImage > } return nullptr; } -boost::shared_ptr< Core::Data::SecretRecipeBook > +Core::Data::ExdDataGenerated::SecretRecipeBookPtr Core::Data::ExdDataGenerated::getSecretRecipeBook( uint32_t SecretRecipeBookId ) { try @@ -7897,7 +8096,7 @@ boost::shared_ptr< Core::Data::SecretRecipeBook > } return nullptr; } -boost::shared_ptr< Core::Data::SpearfishingItem > +Core::Data::ExdDataGenerated::SpearfishingItemPtr Core::Data::ExdDataGenerated::getSpearfishingItem( uint32_t SpearfishingItemId ) { try @@ -7912,7 +8111,7 @@ boost::shared_ptr< Core::Data::SpearfishingItem > } return nullptr; } -boost::shared_ptr< Core::Data::SpearfishingNotebook > +Core::Data::ExdDataGenerated::SpearfishingNotebookPtr Core::Data::ExdDataGenerated::getSpearfishingNotebook( uint32_t SpearfishingNotebookId ) { try @@ -7927,7 +8126,7 @@ boost::shared_ptr< Core::Data::SpearfishingNotebook > } return nullptr; } -boost::shared_ptr< Core::Data::SpecialShop > +Core::Data::ExdDataGenerated::SpecialShopPtr Core::Data::ExdDataGenerated::getSpecialShop( uint32_t SpecialShopId ) { try @@ -7942,7 +8141,7 @@ boost::shared_ptr< Core::Data::SpecialShop > } return nullptr; } -boost::shared_ptr< Core::Data::SpecialShopItemCategory > +Core::Data::ExdDataGenerated::SpecialShopItemCategoryPtr Core::Data::ExdDataGenerated::getSpecialShopItemCategory( uint32_t SpecialShopItemCategoryId ) { try @@ -7957,7 +8156,7 @@ boost::shared_ptr< Core::Data::SpecialShopItemCategory > } return nullptr; } -boost::shared_ptr< Core::Data::Stain > +Core::Data::ExdDataGenerated::StainPtr Core::Data::ExdDataGenerated::getStain( uint32_t StainId ) { try @@ -7972,7 +8171,7 @@ boost::shared_ptr< Core::Data::Stain > } return nullptr; } -boost::shared_ptr< Core::Data::Status > +Core::Data::ExdDataGenerated::StatusPtr Core::Data::ExdDataGenerated::getStatus( uint32_t StatusId ) { try @@ -7987,7 +8186,7 @@ boost::shared_ptr< Core::Data::Status > } return nullptr; } -boost::shared_ptr< Core::Data::Story > +Core::Data::ExdDataGenerated::StoryPtr Core::Data::ExdDataGenerated::getStory( uint32_t StoryId ) { try @@ -8002,7 +8201,7 @@ boost::shared_ptr< Core::Data::Story > } return nullptr; } -boost::shared_ptr< Core::Data::SwitchTalk > +Core::Data::ExdDataGenerated::SwitchTalkPtr Core::Data::ExdDataGenerated::getSwitchTalk( uint32_t SwitchTalkId ) { try @@ -8017,7 +8216,7 @@ boost::shared_ptr< Core::Data::SwitchTalk > } return nullptr; } -boost::shared_ptr< Core::Data::TerritoryType > +Core::Data::ExdDataGenerated::TerritoryTypePtr Core::Data::ExdDataGenerated::getTerritoryType( uint32_t TerritoryTypeId ) { try @@ -8032,7 +8231,7 @@ boost::shared_ptr< Core::Data::TerritoryType > } return nullptr; } -boost::shared_ptr< Core::Data::TextCommand > +Core::Data::ExdDataGenerated::TextCommandPtr Core::Data::ExdDataGenerated::getTextCommand( uint32_t TextCommandId ) { try @@ -8047,7 +8246,7 @@ boost::shared_ptr< Core::Data::TextCommand > } return nullptr; } -boost::shared_ptr< Core::Data::Title > +Core::Data::ExdDataGenerated::TitlePtr Core::Data::ExdDataGenerated::getTitle( uint32_t TitleId ) { try @@ -8062,7 +8261,7 @@ boost::shared_ptr< Core::Data::Title > } return nullptr; } -boost::shared_ptr< Core::Data::Tomestones > +Core::Data::ExdDataGenerated::TomestonesPtr Core::Data::ExdDataGenerated::getTomestones( uint32_t TomestonesId ) { try @@ -8077,7 +8276,7 @@ boost::shared_ptr< Core::Data::Tomestones > } return nullptr; } -boost::shared_ptr< Core::Data::TomestonesItem > +Core::Data::ExdDataGenerated::TomestonesItemPtr Core::Data::ExdDataGenerated::getTomestonesItem( uint32_t TomestonesItemId ) { try @@ -8092,7 +8291,7 @@ boost::shared_ptr< Core::Data::TomestonesItem > } return nullptr; } -boost::shared_ptr< Core::Data::TopicSelect > +Core::Data::ExdDataGenerated::TopicSelectPtr Core::Data::ExdDataGenerated::getTopicSelect( uint32_t TopicSelectId ) { try @@ -8107,7 +8306,7 @@ boost::shared_ptr< Core::Data::TopicSelect > } return nullptr; } -boost::shared_ptr< Core::Data::Town > +Core::Data::ExdDataGenerated::TownPtr Core::Data::ExdDataGenerated::getTown( uint32_t TownId ) { try @@ -8122,7 +8321,7 @@ boost::shared_ptr< Core::Data::Town > } return nullptr; } -boost::shared_ptr< Core::Data::Trait > +Core::Data::ExdDataGenerated::TraitPtr Core::Data::ExdDataGenerated::getTrait( uint32_t TraitId ) { try @@ -8137,7 +8336,7 @@ boost::shared_ptr< Core::Data::Trait > } return nullptr; } -boost::shared_ptr< Core::Data::TraitRecast > +Core::Data::ExdDataGenerated::TraitRecastPtr Core::Data::ExdDataGenerated::getTraitRecast( uint32_t TraitRecastId ) { try @@ -8152,7 +8351,7 @@ boost::shared_ptr< Core::Data::TraitRecast > } return nullptr; } -boost::shared_ptr< Core::Data::TraitTransient > +Core::Data::ExdDataGenerated::TraitTransientPtr Core::Data::ExdDataGenerated::getTraitTransient( uint32_t TraitTransientId ) { try @@ -8167,7 +8366,7 @@ boost::shared_ptr< Core::Data::TraitTransient > } return nullptr; } -boost::shared_ptr< Core::Data::Tribe > +Core::Data::ExdDataGenerated::TribePtr Core::Data::ExdDataGenerated::getTribe( uint32_t TribeId ) { try @@ -8182,7 +8381,7 @@ boost::shared_ptr< Core::Data::Tribe > } return nullptr; } -boost::shared_ptr< Core::Data::TripleTriad > +Core::Data::ExdDataGenerated::TripleTriadPtr Core::Data::ExdDataGenerated::getTripleTriad( uint32_t TripleTriadId ) { try @@ -8197,7 +8396,7 @@ boost::shared_ptr< Core::Data::TripleTriad > } return nullptr; } -boost::shared_ptr< Core::Data::TripleTriadCard > +Core::Data::ExdDataGenerated::TripleTriadCardPtr Core::Data::ExdDataGenerated::getTripleTriadCard( uint32_t TripleTriadCardId ) { try @@ -8212,7 +8411,7 @@ boost::shared_ptr< Core::Data::TripleTriadCard > } return nullptr; } -boost::shared_ptr< Core::Data::TripleTriadCardRarity > +Core::Data::ExdDataGenerated::TripleTriadCardRarityPtr Core::Data::ExdDataGenerated::getTripleTriadCardRarity( uint32_t TripleTriadCardRarityId ) { try @@ -8227,7 +8426,7 @@ boost::shared_ptr< Core::Data::TripleTriadCardRarity > } return nullptr; } -boost::shared_ptr< Core::Data::TripleTriadCardResident > +Core::Data::ExdDataGenerated::TripleTriadCardResidentPtr Core::Data::ExdDataGenerated::getTripleTriadCardResident( uint32_t TripleTriadCardResidentId ) { try @@ -8242,7 +8441,7 @@ boost::shared_ptr< Core::Data::TripleTriadCardResident > } return nullptr; } -boost::shared_ptr< Core::Data::TripleTriadCardType > +Core::Data::ExdDataGenerated::TripleTriadCardTypePtr Core::Data::ExdDataGenerated::getTripleTriadCardType( uint32_t TripleTriadCardTypeId ) { try @@ -8257,7 +8456,7 @@ boost::shared_ptr< Core::Data::TripleTriadCardType > } return nullptr; } -boost::shared_ptr< Core::Data::TripleTriadCompetition > +Core::Data::ExdDataGenerated::TripleTriadCompetitionPtr Core::Data::ExdDataGenerated::getTripleTriadCompetition( uint32_t TripleTriadCompetitionId ) { try @@ -8272,7 +8471,7 @@ boost::shared_ptr< Core::Data::TripleTriadCompetition > } return nullptr; } -boost::shared_ptr< Core::Data::TripleTriadRule > +Core::Data::ExdDataGenerated::TripleTriadRulePtr Core::Data::ExdDataGenerated::getTripleTriadRule( uint32_t TripleTriadRuleId ) { try @@ -8287,7 +8486,7 @@ boost::shared_ptr< Core::Data::TripleTriadRule > } return nullptr; } -boost::shared_ptr< Core::Data::Tutorial > +Core::Data::ExdDataGenerated::TutorialPtr Core::Data::ExdDataGenerated::getTutorial( uint32_t TutorialId ) { try @@ -8302,7 +8501,7 @@ boost::shared_ptr< Core::Data::Tutorial > } return nullptr; } -boost::shared_ptr< Core::Data::TutorialDPS > +Core::Data::ExdDataGenerated::TutorialDPSPtr Core::Data::ExdDataGenerated::getTutorialDPS( uint32_t TutorialDPSId ) { try @@ -8317,7 +8516,7 @@ boost::shared_ptr< Core::Data::TutorialDPS > } return nullptr; } -boost::shared_ptr< Core::Data::TutorialHealer > +Core::Data::ExdDataGenerated::TutorialHealerPtr Core::Data::ExdDataGenerated::getTutorialHealer( uint32_t TutorialHealerId ) { try @@ -8332,7 +8531,7 @@ boost::shared_ptr< Core::Data::TutorialHealer > } return nullptr; } -boost::shared_ptr< Core::Data::TutorialTank > +Core::Data::ExdDataGenerated::TutorialTankPtr Core::Data::ExdDataGenerated::getTutorialTank( uint32_t TutorialTankId ) { try @@ -8347,7 +8546,7 @@ boost::shared_ptr< Core::Data::TutorialTank > } return nullptr; } -boost::shared_ptr< Core::Data::Warp > +Core::Data::ExdDataGenerated::WarpPtr Core::Data::ExdDataGenerated::getWarp( uint32_t WarpId ) { try @@ -8362,7 +8561,7 @@ boost::shared_ptr< Core::Data::Warp > } return nullptr; } -boost::shared_ptr< Core::Data::Weather > +Core::Data::ExdDataGenerated::WeatherPtr Core::Data::ExdDataGenerated::getWeather( uint32_t WeatherId ) { try @@ -8377,7 +8576,7 @@ boost::shared_ptr< Core::Data::Weather > } return nullptr; } -boost::shared_ptr< Core::Data::WeatherGroup > +Core::Data::ExdDataGenerated::WeatherGroupPtr Core::Data::ExdDataGenerated::getWeatherGroup( uint32_t WeatherGroupId ) { try @@ -8392,7 +8591,7 @@ boost::shared_ptr< Core::Data::WeatherGroup > } return nullptr; } -boost::shared_ptr< Core::Data::WeatherRate > +Core::Data::ExdDataGenerated::WeatherRatePtr Core::Data::ExdDataGenerated::getWeatherRate( uint32_t WeatherRateId ) { try @@ -8407,7 +8606,7 @@ boost::shared_ptr< Core::Data::WeatherRate > } return nullptr; } -boost::shared_ptr< Core::Data::WeeklyBingoOrderData > +Core::Data::ExdDataGenerated::WeeklyBingoOrderDataPtr Core::Data::ExdDataGenerated::getWeeklyBingoOrderData( uint32_t WeeklyBingoOrderDataId ) { try @@ -8422,7 +8621,7 @@ boost::shared_ptr< Core::Data::WeeklyBingoOrderData > } return nullptr; } -boost::shared_ptr< Core::Data::WeeklyBingoRewardData > +Core::Data::ExdDataGenerated::WeeklyBingoRewardDataPtr Core::Data::ExdDataGenerated::getWeeklyBingoRewardData( uint32_t WeeklyBingoRewardDataId ) { try @@ -8437,7 +8636,7 @@ boost::shared_ptr< Core::Data::WeeklyBingoRewardData > } return nullptr; } -boost::shared_ptr< Core::Data::WeeklyBingoText > +Core::Data::ExdDataGenerated::WeeklyBingoTextPtr Core::Data::ExdDataGenerated::getWeeklyBingoText( uint32_t WeeklyBingoTextId ) { try @@ -8452,7 +8651,7 @@ boost::shared_ptr< Core::Data::WeeklyBingoText > } return nullptr; } -boost::shared_ptr< Core::Data::WorldDCGroupType > +Core::Data::ExdDataGenerated::WorldDCGroupTypePtr Core::Data::ExdDataGenerated::getWorldDCGroupType( uint32_t WorldDCGroupTypeId ) { try diff --git a/src/tools/exd_struct_test/ExdDataGenerated.h b/src/common/Exd/ExdDataGenerated.h similarity index 76% rename from src/tools/exd_struct_test/ExdDataGenerated.h rename to src/common/Exd/ExdDataGenerated.h index 24b1149d..c6f7ffd9 100644 --- a/src/tools/exd_struct_test/ExdDataGenerated.h +++ b/src/common/Exd/ExdDataGenerated.h @@ -1,5 +1,5 @@ -#ifndef _EXDDATA_H -#define _EXDDATA_H +#ifndef GENERATED_EXDDATA_H +#define GENERATED_EXDDATA_H /* This file has been automatically generated. Changes will be lost upon regeneration. @@ -71,7 +71,6 @@ struct BuddySkill; struct Cabinet; struct CabinetCategory; struct Calendar; -struct ChainBonus; struct CharaMakeCustomize; struct CharaMakeType; struct ChocoboRace; @@ -141,11 +140,13 @@ struct EventItemHelp; struct ExVersion; struct Fate; struct FCActivity; +struct FCActivityCategory; struct FCAuthority; struct FCAuthorityCategory; struct FCChestName; struct FccShop; struct FCHierarchy; +struct FCProfile; struct FCReputation; struct FCRights; struct FishingSpot; @@ -169,6 +170,12 @@ struct GcArmyExpeditionMemberBonus; struct GcArmyExpeditionType; struct GcArmyMemberGrow; struct GcArmyTraining; +struct GCRankGridaniaFemaleText; +struct GCRankGridaniaMaleText; +struct GCRankLimsaFemaleText; +struct GCRankLimsaMaleText; +struct GCRankUldahFemaleText; +struct GCRankUldahMaleText; struct GCScripShopCategory; struct GCScripShopItem; struct GCShop; @@ -235,6 +242,7 @@ struct MountAction; struct NpcEquip; struct Omen; struct OnlineStatus; +struct Opening; struct Orchestrion; struct OrchestrionPath; struct ParamGrow; @@ -479,6 +487,7 @@ struct Aetheryte uint16_t placeName; uint16_t aethernetName; uint16_t territory; + uint32_t destination; bool isAetheryte; uint8_t aethernetGroup; uint16_t map; @@ -838,14 +847,6 @@ struct Calendar Calendar( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ); }; -struct ChainBonus -{ - uint8_t bonus; - uint8_t timeouts; - - ChainBonus( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ); -}; - struct CharaMakeCustomize { uint32_t icon; @@ -937,7 +938,9 @@ struct ClassJob std::string name; std::string abbreviation; uint8_t classJobCategory; + int8_t expArrayIndex; uint16_t modifierHitPoints; + uint16_t modifierManaPoints; uint16_t modifierStrength; uint16_t modifierVitality; uint16_t modifierDexterity; @@ -1143,8 +1146,10 @@ struct ContentFinderCondition uint8_t contentIndicator; uint16_t instanceContent; uint8_t contentMemberType; - uint8_t classJobLevel; + uint8_t classJobLevelRequired; + uint8_t classJobLevelSync; uint16_t itemLevelRequired; + uint16_t itemLevelSync; uint32_t icon; ContentFinderCondition( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ); @@ -1173,7 +1178,6 @@ struct ContentRoulette std::string description; std::string dutyType; bool isInDutyFinder; - bool requireAllDuties; uint16_t itemLevelRequired; uint32_t icon; uint16_t rewardTomeA; @@ -1181,6 +1185,7 @@ struct ContentRoulette uint16_t rewardTomeC; uint8_t sortKey; uint8_t contentMemberType; + bool requireAllDuties; ContentRoulette( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ); }; @@ -1531,6 +1536,7 @@ struct EventAction { std::string name; uint16_t icon; + uint16_t castTime; EventAction( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ); }; @@ -1562,6 +1568,7 @@ struct EventItem uint16_t icon; uint8_t stackSize; uint32_t quest; + uint8_t castTime; EventItem( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ); }; @@ -1598,10 +1605,18 @@ struct Fate struct FCActivity { std::string text; + uint8_t fCActivityCategory; FCActivity( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ); }; +struct FCActivityCategory +{ + std::string name; + + FCActivityCategory( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ); +}; + struct FCAuthority { std::string name; @@ -1638,6 +1653,13 @@ struct FCHierarchy FCHierarchy( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ); }; +struct FCProfile +{ + std::string name; + + FCProfile( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ); +}; + struct FCReputation { uint32_t pointsToNext; @@ -1851,6 +1873,60 @@ struct GcArmyTraining GcArmyTraining( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ); }; +struct GCRankGridaniaFemaleText +{ + std::string name; + std::string plural; + std::string nameRank; + + GCRankGridaniaFemaleText( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ); +}; + +struct GCRankGridaniaMaleText +{ + std::string name; + std::string plural; + std::string nameRank; + + GCRankGridaniaMaleText( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ); +}; + +struct GCRankLimsaFemaleText +{ + std::string name; + std::string plural; + std::string nameRank; + + GCRankLimsaFemaleText( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ); +}; + +struct GCRankLimsaMaleText +{ + std::string name; + std::string plural; + std::string nameRank; + + GCRankLimsaMaleText( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ); +}; + +struct GCRankUldahFemaleText +{ + std::string name; + std::string plural; + std::string nameRank; + + GCRankUldahFemaleText( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ); +}; + +struct GCRankUldahMaleText +{ + std::string name; + std::string plural; + std::string nameRank; + + GCRankUldahMaleText( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ); +}; + struct GCScripShopCategory { int8_t grandCompany; @@ -2022,12 +2098,9 @@ struct InstanceContent uint8_t instanceContentType; uint8_t weekRestriction; uint16_t timeLimitmin; - uint8_t classJobLevelSync; std::string name; uint16_t bGM; - uint16_t itemLevelSync; uint32_t territoryType; - uint32_t icon; uint32_t instanceContentTextDataBossStart; uint32_t instanceContentTextDataBossEnd; uint32_t bNpcBaseBoss; @@ -2211,7 +2284,6 @@ struct Leve int32_t placeNameStart; int32_t placeNameIssued; uint8_t classJobCategory; - int32_t journalCategory; int32_t placeNameStartZone; int32_t iconCityState; int32_t dataId; @@ -2254,6 +2326,7 @@ struct Level uint8_t type; uint32_t objectKey; uint16_t map; + uint32_t eventId; uint16_t territory; Level( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ); @@ -2356,7 +2429,9 @@ struct Map uint16_t placeNameRegion; uint16_t placeName; uint16_t placeNameSub; + int16_t discoveryIndex; uint16_t territoryType; + bool discoveryArrayByte; Map( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ); }; @@ -2535,6 +2610,13 @@ struct OnlineStatus OnlineStatus( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ); }; +struct Opening +{ + std::string name; + + Opening( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ); +}; + struct Orchestrion { std::string name; @@ -3020,6 +3102,7 @@ struct TerritoryType uint16_t placeNameZone; uint16_t placeName; uint16_t map; + uint8_t territoryIntendedUse; uint8_t weatherRate; int32_t aetheryte; @@ -3134,6 +3217,7 @@ struct TripleTriad uint32_t defaultTalkNPCWin; uint32_t defaultTalkDraw; uint32_t defaultTalkPCWin; + std::vector< uint32_t > itemPossibleReward; TripleTriad( uint32_t row_id, Core::Data::ExdDataGenerated* exdData ); }; @@ -3366,7 +3450,6 @@ struct WorldDCGroupType xiv::exd::Exd m_CabinetDat; xiv::exd::Exd m_CabinetCategoryDat; xiv::exd::Exd m_CalendarDat; - xiv::exd::Exd m_ChainBonusDat; xiv::exd::Exd m_CharaMakeCustomizeDat; xiv::exd::Exd m_CharaMakeTypeDat; xiv::exd::Exd m_ChocoboRaceDat; @@ -3436,11 +3519,13 @@ struct WorldDCGroupType xiv::exd::Exd m_ExVersionDat; xiv::exd::Exd m_FateDat; xiv::exd::Exd m_FCActivityDat; + xiv::exd::Exd m_FCActivityCategoryDat; xiv::exd::Exd m_FCAuthorityDat; xiv::exd::Exd m_FCAuthorityCategoryDat; xiv::exd::Exd m_FCChestNameDat; xiv::exd::Exd m_FccShopDat; xiv::exd::Exd m_FCHierarchyDat; + xiv::exd::Exd m_FCProfileDat; xiv::exd::Exd m_FCReputationDat; xiv::exd::Exd m_FCRightsDat; xiv::exd::Exd m_FishingSpotDat; @@ -3464,6 +3549,12 @@ struct WorldDCGroupType xiv::exd::Exd m_GcArmyExpeditionTypeDat; xiv::exd::Exd m_GcArmyMemberGrowDat; xiv::exd::Exd m_GcArmyTrainingDat; + xiv::exd::Exd m_GCRankGridaniaFemaleTextDat; + xiv::exd::Exd m_GCRankGridaniaMaleTextDat; + xiv::exd::Exd m_GCRankLimsaFemaleTextDat; + xiv::exd::Exd m_GCRankLimsaMaleTextDat; + xiv::exd::Exd m_GCRankUldahFemaleTextDat; + xiv::exd::Exd m_GCRankUldahMaleTextDat; xiv::exd::Exd m_GCScripShopCategoryDat; xiv::exd::Exd m_GCScripShopItemDat; xiv::exd::Exd m_GCShopDat; @@ -3530,6 +3621,7 @@ struct WorldDCGroupType xiv::exd::Exd m_NpcEquipDat; xiv::exd::Exd m_OmenDat; xiv::exd::Exd m_OnlineStatusDat; + xiv::exd::Exd m_OpeningDat; xiv::exd::Exd m_OrchestrionDat; xiv::exd::Exd m_OrchestrionPathDat; xiv::exd::Exd m_ParamGrowDat; @@ -3604,296 +3696,602 @@ struct WorldDCGroupType xiv::exd::Exd m_WorldDCGroupTypeDat; - boost::shared_ptr< Achievement > getAchievement( uint32_t AchievementId ); - boost::shared_ptr< AchievementCategory > getAchievementCategory( uint32_t AchievementCategoryId ); - boost::shared_ptr< AchievementKind > getAchievementKind( uint32_t AchievementKindId ); - boost::shared_ptr< Action > getAction( uint32_t ActionId ); - boost::shared_ptr< ActionCategory > getActionCategory( uint32_t ActionCategoryId ); - boost::shared_ptr< ActionComboRoute > getActionComboRoute( uint32_t ActionComboRouteId ); - boost::shared_ptr< ActionIndirection > getActionIndirection( uint32_t ActionIndirectionId ); - boost::shared_ptr< ActionProcStatus > getActionProcStatus( uint32_t ActionProcStatusId ); - boost::shared_ptr< ActionTimeline > getActionTimeline( uint32_t ActionTimelineId ); - boost::shared_ptr< ActionTransient > getActionTransient( uint32_t ActionTransientId ); - boost::shared_ptr< Addon > getAddon( uint32_t AddonId ); - boost::shared_ptr< Adventure > getAdventure( uint32_t AdventureId ); - boost::shared_ptr< AdventureExPhase > getAdventureExPhase( uint32_t AdventureExPhaseId ); - boost::shared_ptr< AetherCurrent > getAetherCurrent( uint32_t AetherCurrentId ); - boost::shared_ptr< AetherialWheel > getAetherialWheel( uint32_t AetherialWheelId ); - boost::shared_ptr< Aetheryte > getAetheryte( uint32_t AetheryteId ); - boost::shared_ptr< AirshipExplorationLevel > getAirshipExplorationLevel( uint32_t AirshipExplorationLevelId ); - boost::shared_ptr< AirshipExplorationLog > getAirshipExplorationLog( uint32_t AirshipExplorationLogId ); - boost::shared_ptr< AirshipExplorationParamType > getAirshipExplorationParamType( uint32_t AirshipExplorationParamTypeId ); - boost::shared_ptr< AirshipExplorationPart > getAirshipExplorationPart( uint32_t AirshipExplorationPartId ); - boost::shared_ptr< AirshipExplorationPoint > getAirshipExplorationPoint( uint32_t AirshipExplorationPointId ); - boost::shared_ptr< AnimaWeapon5 > getAnimaWeapon5( uint32_t AnimaWeapon5Id ); - boost::shared_ptr< AnimaWeapon5Param > getAnimaWeapon5Param( uint32_t AnimaWeapon5ParamId ); - boost::shared_ptr< AnimaWeapon5PatternGroup > getAnimaWeapon5PatternGroup( uint32_t AnimaWeapon5PatternGroupId ); - boost::shared_ptr< AnimaWeapon5SpiritTalk > getAnimaWeapon5SpiritTalk( uint32_t AnimaWeapon5SpiritTalkId ); - boost::shared_ptr< AnimaWeapon5SpiritTalkParam > getAnimaWeapon5SpiritTalkParam( uint32_t AnimaWeapon5SpiritTalkParamId ); - boost::shared_ptr< AnimaWeapon5TradeItem > getAnimaWeapon5TradeItem( uint32_t AnimaWeapon5TradeItemId ); - boost::shared_ptr< AnimaWeaponFUITalk > getAnimaWeaponFUITalk( uint32_t AnimaWeaponFUITalkId ); - boost::shared_ptr< AnimaWeaponFUITalkParam > getAnimaWeaponFUITalkParam( uint32_t AnimaWeaponFUITalkParamId ); - boost::shared_ptr< AnimaWeaponIcon > getAnimaWeaponIcon( uint32_t AnimaWeaponIconId ); - boost::shared_ptr< AnimaWeaponItem > getAnimaWeaponItem( uint32_t AnimaWeaponItemId ); - boost::shared_ptr< AquariumFish > getAquariumFish( uint32_t AquariumFishId ); - boost::shared_ptr< AquariumWater > getAquariumWater( uint32_t AquariumWaterId ); - boost::shared_ptr< AttackType > getAttackType( uint32_t AttackTypeId ); - boost::shared_ptr< Balloon > getBalloon( uint32_t BalloonId ); - boost::shared_ptr< BaseParam > getBaseParam( uint32_t BaseParamId ); - boost::shared_ptr< BattleLeve > getBattleLeve( uint32_t BattleLeveId ); - boost::shared_ptr< BeastRankBonus > getBeastRankBonus( uint32_t BeastRankBonusId ); - boost::shared_ptr< BeastReputationRank > getBeastReputationRank( uint32_t BeastReputationRankId ); - boost::shared_ptr< BeastTribe > getBeastTribe( uint32_t BeastTribeId ); - boost::shared_ptr< Behavior > getBehavior( uint32_t BehaviorId ); - boost::shared_ptr< BGM > getBGM( uint32_t BGMId ); - boost::shared_ptr< BNpcAnnounceIcon > getBNpcAnnounceIcon( uint32_t BNpcAnnounceIconId ); - boost::shared_ptr< BNpcBase > getBNpcBase( uint32_t BNpcBaseId ); - boost::shared_ptr< BNpcCustomize > getBNpcCustomize( uint32_t BNpcCustomizeId ); - boost::shared_ptr< BNpcName > getBNpcName( uint32_t BNpcNameId ); - boost::shared_ptr< BuddyAction > getBuddyAction( uint32_t BuddyActionId ); - boost::shared_ptr< BuddyEquip > getBuddyEquip( uint32_t BuddyEquipId ); - boost::shared_ptr< BuddyItem > getBuddyItem( uint32_t BuddyItemId ); - boost::shared_ptr< BuddyRank > getBuddyRank( uint32_t BuddyRankId ); - boost::shared_ptr< BuddySkill > getBuddySkill( uint32_t BuddySkillId ); - boost::shared_ptr< Cabinet > getCabinet( uint32_t CabinetId ); - boost::shared_ptr< CabinetCategory > getCabinetCategory( uint32_t CabinetCategoryId ); - boost::shared_ptr< Calendar > getCalendar( uint32_t CalendarId ); - boost::shared_ptr< ChainBonus > getChainBonus( uint32_t ChainBonusId ); - boost::shared_ptr< CharaMakeCustomize > getCharaMakeCustomize( uint32_t CharaMakeCustomizeId ); - boost::shared_ptr< CharaMakeType > getCharaMakeType( uint32_t CharaMakeTypeId ); - boost::shared_ptr< ChocoboRace > getChocoboRace( uint32_t ChocoboRaceId ); - boost::shared_ptr< ChocoboRaceAbility > getChocoboRaceAbility( uint32_t ChocoboRaceAbilityId ); - boost::shared_ptr< ChocoboRaceAbilityType > getChocoboRaceAbilityType( uint32_t ChocoboRaceAbilityTypeId ); - boost::shared_ptr< ChocoboRaceItem > getChocoboRaceItem( uint32_t ChocoboRaceItemId ); - boost::shared_ptr< ChocoboRaceRank > getChocoboRaceRank( uint32_t ChocoboRaceRankId ); - boost::shared_ptr< ChocoboRaceStatus > getChocoboRaceStatus( uint32_t ChocoboRaceStatusId ); - boost::shared_ptr< ChocoboRaceTerritory > getChocoboRaceTerritory( uint32_t ChocoboRaceTerritoryId ); - boost::shared_ptr< ChocoboTaxiStand > getChocoboTaxiStand( uint32_t ChocoboTaxiStandId ); - boost::shared_ptr< ClassJob > getClassJob( uint32_t ClassJobId ); - boost::shared_ptr< ClassJobCategory > getClassJobCategory( uint32_t ClassJobCategoryId ); - boost::shared_ptr< Companion > getCompanion( uint32_t CompanionId ); - boost::shared_ptr< CompanionMove > getCompanionMove( uint32_t CompanionMoveId ); - boost::shared_ptr< CompanionTransient > getCompanionTransient( uint32_t CompanionTransientId ); - boost::shared_ptr< CompanyAction > getCompanyAction( uint32_t CompanyActionId ); - boost::shared_ptr< CompanyCraftDraft > getCompanyCraftDraft( uint32_t CompanyCraftDraftId ); - boost::shared_ptr< CompanyCraftDraftCategory > getCompanyCraftDraftCategory( uint32_t CompanyCraftDraftCategoryId ); - boost::shared_ptr< CompanyCraftManufactoryState > getCompanyCraftManufactoryState( uint32_t CompanyCraftManufactoryStateId ); - boost::shared_ptr< CompanyCraftPart > getCompanyCraftPart( uint32_t CompanyCraftPartId ); - boost::shared_ptr< CompanyCraftProcess > getCompanyCraftProcess( uint32_t CompanyCraftProcessId ); - boost::shared_ptr< CompanyCraftSequence > getCompanyCraftSequence( uint32_t CompanyCraftSequenceId ); - boost::shared_ptr< CompanyCraftSupplyItem > getCompanyCraftSupplyItem( uint32_t CompanyCraftSupplyItemId ); - boost::shared_ptr< CompanyCraftType > getCompanyCraftType( uint32_t CompanyCraftTypeId ); - boost::shared_ptr< CompleteJournal > getCompleteJournal( uint32_t CompleteJournalId ); - boost::shared_ptr< CompleteJournalCategory > getCompleteJournalCategory( uint32_t CompleteJournalCategoryId ); - boost::shared_ptr< ContentExAction > getContentExAction( uint32_t ContentExActionId ); - boost::shared_ptr< ContentFinderCondition > getContentFinderCondition( uint32_t ContentFinderConditionId ); - boost::shared_ptr< ContentFinderConditionTransient > getContentFinderConditionTransient( uint32_t ContentFinderConditionTransientId ); - boost::shared_ptr< ContentMemberType > getContentMemberType( uint32_t ContentMemberTypeId ); - boost::shared_ptr< ContentRoulette > getContentRoulette( uint32_t ContentRouletteId ); - boost::shared_ptr< ContentType > getContentType( uint32_t ContentTypeId ); - boost::shared_ptr< CraftAction > getCraftAction( uint32_t CraftActionId ); - boost::shared_ptr< CraftLeve > getCraftLeve( uint32_t CraftLeveId ); - boost::shared_ptr< CraftType > getCraftType( uint32_t CraftTypeId ); - boost::shared_ptr< Currency > getCurrency( uint32_t CurrencyId ); - boost::shared_ptr< CustomTalk > getCustomTalk( uint32_t CustomTalkId ); - boost::shared_ptr< Cutscene > getCutscene( uint32_t CutsceneId ); - boost::shared_ptr< CutScreenImage > getCutScreenImage( uint32_t CutScreenImageId ); - boost::shared_ptr< DailySupplyItem > getDailySupplyItem( uint32_t DailySupplyItemId ); - boost::shared_ptr< DeepDungeonBan > getDeepDungeonBan( uint32_t DeepDungeonBanId ); - boost::shared_ptr< DeepDungeonDanger > getDeepDungeonDanger( uint32_t DeepDungeonDangerId ); - boost::shared_ptr< DeepDungeonEquipment > getDeepDungeonEquipment( uint32_t DeepDungeonEquipmentId ); - boost::shared_ptr< DeepDungeonFloorEffectUI > getDeepDungeonFloorEffectUI( uint32_t DeepDungeonFloorEffectUIId ); - boost::shared_ptr< DeepDungeonItem > getDeepDungeonItem( uint32_t DeepDungeonItemId ); - boost::shared_ptr< DeepDungeonStatus > getDeepDungeonStatus( uint32_t DeepDungeonStatusId ); - boost::shared_ptr< DefaultTalk > getDefaultTalk( uint32_t DefaultTalkId ); - boost::shared_ptr< DeliveryQuest > getDeliveryQuest( uint32_t DeliveryQuestId ); - boost::shared_ptr< DisposalShop > getDisposalShop( uint32_t DisposalShopId ); - boost::shared_ptr< DisposalShopFilterType > getDisposalShopFilterType( uint32_t DisposalShopFilterTypeId ); - boost::shared_ptr< DisposalShopItem > getDisposalShopItem( uint32_t DisposalShopItemId ); - boost::shared_ptr< DpsChallenge > getDpsChallenge( uint32_t DpsChallengeId ); - boost::shared_ptr< DpsChallengeOfficer > getDpsChallengeOfficer( uint32_t DpsChallengeOfficerId ); - boost::shared_ptr< DpsChallengeTransient > getDpsChallengeTransient( uint32_t DpsChallengeTransientId ); - boost::shared_ptr< Emote > getEmote( uint32_t EmoteId ); - boost::shared_ptr< EmoteCategory > getEmoteCategory( uint32_t EmoteCategoryId ); - boost::shared_ptr< ENpcBase > getENpcBase( uint32_t ENpcBaseId ); - boost::shared_ptr< ENpcResident > getENpcResident( uint32_t ENpcResidentId ); - boost::shared_ptr< EObj > getEObj( uint32_t EObjId ); - boost::shared_ptr< EquipRaceCategory > getEquipRaceCategory( uint32_t EquipRaceCategoryId ); - boost::shared_ptr< EquipSlotCategory > getEquipSlotCategory( uint32_t EquipSlotCategoryId ); - boost::shared_ptr< EventAction > getEventAction( uint32_t EventActionId ); - boost::shared_ptr< EventIconPriority > getEventIconPriority( uint32_t EventIconPriorityId ); - boost::shared_ptr< EventIconType > getEventIconType( uint32_t EventIconTypeId ); - boost::shared_ptr< EventItem > getEventItem( uint32_t EventItemId ); - boost::shared_ptr< EventItemHelp > getEventItemHelp( uint32_t EventItemHelpId ); - boost::shared_ptr< ExVersion > getExVersion( uint32_t ExVersionId ); - boost::shared_ptr< Fate > getFate( uint32_t FateId ); - boost::shared_ptr< FCActivity > getFCActivity( uint32_t FCActivityId ); - boost::shared_ptr< FCAuthority > getFCAuthority( uint32_t FCAuthorityId ); - boost::shared_ptr< FCAuthorityCategory > getFCAuthorityCategory( uint32_t FCAuthorityCategoryId ); - boost::shared_ptr< FCChestName > getFCChestName( uint32_t FCChestNameId ); - boost::shared_ptr< FccShop > getFccShop( uint32_t FccShopId ); - boost::shared_ptr< FCHierarchy > getFCHierarchy( uint32_t FCHierarchyId ); - boost::shared_ptr< FCReputation > getFCReputation( uint32_t FCReputationId ); - boost::shared_ptr< FCRights > getFCRights( uint32_t FCRightsId ); - boost::shared_ptr< FishingSpot > getFishingSpot( uint32_t FishingSpotId ); - boost::shared_ptr< FishParameter > getFishParameter( uint32_t FishParameterId ); - boost::shared_ptr< GardeningSeed > getGardeningSeed( uint32_t GardeningSeedId ); - boost::shared_ptr< GatheringCondition > getGatheringCondition( uint32_t GatheringConditionId ); - boost::shared_ptr< GatheringExp > getGatheringExp( uint32_t GatheringExpId ); - boost::shared_ptr< GatheringItem > getGatheringItem( uint32_t GatheringItemId ); - boost::shared_ptr< GatheringItemLevelConvertTable > getGatheringItemLevelConvertTable( uint32_t GatheringItemLevelConvertTableId ); - boost::shared_ptr< GatheringItemPoint > getGatheringItemPoint( uint32_t GatheringItemPointId ); - boost::shared_ptr< GatheringNotebookList > getGatheringNotebookList( uint32_t GatheringNotebookListId ); - boost::shared_ptr< GatheringPoint > getGatheringPoint( uint32_t GatheringPointId ); - boost::shared_ptr< GatheringPointBase > getGatheringPointBase( uint32_t GatheringPointBaseId ); - boost::shared_ptr< GatheringPointBonus > getGatheringPointBonus( uint32_t GatheringPointBonusId ); - boost::shared_ptr< GatheringPointBonusType > getGatheringPointBonusType( uint32_t GatheringPointBonusTypeId ); - boost::shared_ptr< GatheringPointName > getGatheringPointName( uint32_t GatheringPointNameId ); - boost::shared_ptr< GatheringSubCategory > getGatheringSubCategory( uint32_t GatheringSubCategoryId ); - boost::shared_ptr< GatheringType > getGatheringType( uint32_t GatheringTypeId ); - boost::shared_ptr< GcArmyExpedition > getGcArmyExpedition( uint32_t GcArmyExpeditionId ); - boost::shared_ptr< GcArmyExpeditionMemberBonus > getGcArmyExpeditionMemberBonus( uint32_t GcArmyExpeditionMemberBonusId ); - boost::shared_ptr< GcArmyExpeditionType > getGcArmyExpeditionType( uint32_t GcArmyExpeditionTypeId ); - boost::shared_ptr< GcArmyMemberGrow > getGcArmyMemberGrow( uint32_t GcArmyMemberGrowId ); - boost::shared_ptr< GcArmyTraining > getGcArmyTraining( uint32_t GcArmyTrainingId ); - boost::shared_ptr< GCScripShopCategory > getGCScripShopCategory( uint32_t GCScripShopCategoryId ); - boost::shared_ptr< GCScripShopItem > getGCScripShopItem( uint32_t GCScripShopItemId ); - boost::shared_ptr< GCShop > getGCShop( uint32_t GCShopId ); - boost::shared_ptr< GCShopItemCategory > getGCShopItemCategory( uint32_t GCShopItemCategoryId ); - boost::shared_ptr< GCSupplyDuty > getGCSupplyDuty( uint32_t GCSupplyDutyId ); - boost::shared_ptr< GCSupplyDutyReward > getGCSupplyDutyReward( uint32_t GCSupplyDutyRewardId ); - boost::shared_ptr< GeneralAction > getGeneralAction( uint32_t GeneralActionId ); - boost::shared_ptr< GilShop > getGilShop( uint32_t GilShopId ); - boost::shared_ptr< GilShopItem > getGilShopItem( uint32_t GilShopItemId ); - boost::shared_ptr< GoldSaucerTextData > getGoldSaucerTextData( uint32_t GoldSaucerTextDataId ); - boost::shared_ptr< GrandCompany > getGrandCompany( uint32_t GrandCompanyId ); - boost::shared_ptr< GrandCompanyRank > getGrandCompanyRank( uint32_t GrandCompanyRankId ); - boost::shared_ptr< GuardianDeity > getGuardianDeity( uint32_t GuardianDeityId ); - boost::shared_ptr< GuildleveAssignment > getGuildleveAssignment( uint32_t GuildleveAssignmentId ); - boost::shared_ptr< GuildOrderGuide > getGuildOrderGuide( uint32_t GuildOrderGuideId ); - boost::shared_ptr< GuildOrderOfficer > getGuildOrderOfficer( uint32_t GuildOrderOfficerId ); - boost::shared_ptr< HouseRetainerPose > getHouseRetainerPose( uint32_t HouseRetainerPoseId ); - boost::shared_ptr< HousingFurniture > getHousingFurniture( uint32_t HousingFurnitureId ); - boost::shared_ptr< HousingYardObject > getHousingYardObject( uint32_t HousingYardObjectId ); - boost::shared_ptr< InstanceContent > getInstanceContent( uint32_t InstanceContentId ); - boost::shared_ptr< InstanceContentBuff > getInstanceContentBuff( uint32_t InstanceContentBuffId ); - boost::shared_ptr< InstanceContentTextData > getInstanceContentTextData( uint32_t InstanceContentTextDataId ); - boost::shared_ptr< InstanceContentType > getInstanceContentType( uint32_t InstanceContentTypeId ); - boost::shared_ptr< Item > getItem( uint32_t ItemId ); - boost::shared_ptr< ItemAction > getItemAction( uint32_t ItemActionId ); - boost::shared_ptr< ItemFood > getItemFood( uint32_t ItemFoodId ); - boost::shared_ptr< ItemSearchCategory > getItemSearchCategory( uint32_t ItemSearchCategoryId ); - boost::shared_ptr< ItemSeries > getItemSeries( uint32_t ItemSeriesId ); - boost::shared_ptr< ItemSpecialBonus > getItemSpecialBonus( uint32_t ItemSpecialBonusId ); - boost::shared_ptr< ItemUICategory > getItemUICategory( uint32_t ItemUICategoryId ); - boost::shared_ptr< JournalCategory > getJournalCategory( uint32_t JournalCategoryId ); - boost::shared_ptr< JournalGenre > getJournalGenre( uint32_t JournalGenreId ); - boost::shared_ptr< JournalSection > getJournalSection( uint32_t JournalSectionId ); - boost::shared_ptr< Leve > getLeve( uint32_t LeveId ); - boost::shared_ptr< LeveAssignmentType > getLeveAssignmentType( uint32_t LeveAssignmentTypeId ); - boost::shared_ptr< LeveClient > getLeveClient( uint32_t LeveClientId ); - boost::shared_ptr< Level > getLevel( uint32_t LevelId ); - boost::shared_ptr< LeveRewardItem > getLeveRewardItem( uint32_t LeveRewardItemId ); - boost::shared_ptr< LeveRewardItemGroup > getLeveRewardItemGroup( uint32_t LeveRewardItemGroupId ); - boost::shared_ptr< LeveVfx > getLeveVfx( uint32_t LeveVfxId ); - boost::shared_ptr< LogFilter > getLogFilter( uint32_t LogFilterId ); - boost::shared_ptr< LogKind > getLogKind( uint32_t LogKindId ); - boost::shared_ptr< LogKindCategoryText > getLogKindCategoryText( uint32_t LogKindCategoryTextId ); - boost::shared_ptr< LogMessage > getLogMessage( uint32_t LogMessageId ); - boost::shared_ptr< MacroIcon > getMacroIcon( uint32_t MacroIconId ); - boost::shared_ptr< MacroIconRedirectOld > getMacroIconRedirectOld( uint32_t MacroIconRedirectOldId ); - boost::shared_ptr< MainCommand > getMainCommand( uint32_t MainCommandId ); - boost::shared_ptr< MainCommandCategory > getMainCommandCategory( uint32_t MainCommandCategoryId ); - boost::shared_ptr< Map > getMap( uint32_t MapId ); - boost::shared_ptr< MapMarker > getMapMarker( uint32_t MapMarkerId ); - boost::shared_ptr< MapSymbol > getMapSymbol( uint32_t MapSymbolId ); - boost::shared_ptr< MasterpieceSupplyDuty > getMasterpieceSupplyDuty( uint32_t MasterpieceSupplyDutyId ); - boost::shared_ptr< MasterpieceSupplyMultiplier > getMasterpieceSupplyMultiplier( uint32_t MasterpieceSupplyMultiplierId ); - boost::shared_ptr< Materia > getMateria( uint32_t MateriaId ); - boost::shared_ptr< MinionRace > getMinionRace( uint32_t MinionRaceId ); - boost::shared_ptr< MinionRules > getMinionRules( uint32_t MinionRulesId ); - boost::shared_ptr< MinionSkillType > getMinionSkillType( uint32_t MinionSkillTypeId ); - boost::shared_ptr< MobHuntTarget > getMobHuntTarget( uint32_t MobHuntTargetId ); - boost::shared_ptr< ModelChara > getModelChara( uint32_t ModelCharaId ); - boost::shared_ptr< MonsterNote > getMonsterNote( uint32_t MonsterNoteId ); - boost::shared_ptr< MonsterNoteTarget > getMonsterNoteTarget( uint32_t MonsterNoteTargetId ); - boost::shared_ptr< Mount > getMount( uint32_t MountId ); - boost::shared_ptr< MountAction > getMountAction( uint32_t MountActionId ); - boost::shared_ptr< NpcEquip > getNpcEquip( uint32_t NpcEquipId ); - boost::shared_ptr< Omen > getOmen( uint32_t OmenId ); - boost::shared_ptr< OnlineStatus > getOnlineStatus( uint32_t OnlineStatusId ); - boost::shared_ptr< Orchestrion > getOrchestrion( uint32_t OrchestrionId ); - boost::shared_ptr< OrchestrionPath > getOrchestrionPath( uint32_t OrchestrionPathId ); - boost::shared_ptr< ParamGrow > getParamGrow( uint32_t ParamGrowId ); - boost::shared_ptr< Pet > getPet( uint32_t PetId ); - boost::shared_ptr< PetAction > getPetAction( uint32_t PetActionId ); - boost::shared_ptr< Picture > getPicture( uint32_t PictureId ); - boost::shared_ptr< PlaceName > getPlaceName( uint32_t PlaceNameId ); - boost::shared_ptr< Quest > getQuest( uint32_t QuestId ); - boost::shared_ptr< QuestRewardOther > getQuestRewardOther( uint32_t QuestRewardOtherId ); - boost::shared_ptr< Race > getRace( uint32_t RaceId ); - boost::shared_ptr< RacingChocoboItem > getRacingChocoboItem( uint32_t RacingChocoboItemId ); - boost::shared_ptr< RacingChocoboName > getRacingChocoboName( uint32_t RacingChocoboNameId ); - boost::shared_ptr< RacingChocoboNameCategory > getRacingChocoboNameCategory( uint32_t RacingChocoboNameCategoryId ); - boost::shared_ptr< RacingChocoboNameInfo > getRacingChocoboNameInfo( uint32_t RacingChocoboNameInfoId ); - boost::shared_ptr< RacingChocoboParam > getRacingChocoboParam( uint32_t RacingChocoboParamId ); - boost::shared_ptr< Recipe > getRecipe( uint32_t RecipeId ); - boost::shared_ptr< RecipeElement > getRecipeElement( uint32_t RecipeElementId ); - boost::shared_ptr< RecipeLevelTable > getRecipeLevelTable( uint32_t RecipeLevelTableId ); - boost::shared_ptr< RecipeNotebookList > getRecipeNotebookList( uint32_t RecipeNotebookListId ); - boost::shared_ptr< Relic > getRelic( uint32_t RelicId ); - boost::shared_ptr< Relic3 > getRelic3( uint32_t Relic3Id ); - boost::shared_ptr< RelicItem > getRelicItem( uint32_t RelicItemId ); - boost::shared_ptr< RelicNote > getRelicNote( uint32_t RelicNoteId ); - boost::shared_ptr< RelicNoteCategory > getRelicNoteCategory( uint32_t RelicNoteCategoryId ); - boost::shared_ptr< RetainerTask > getRetainerTask( uint32_t RetainerTaskId ); - boost::shared_ptr< RetainerTaskNormal > getRetainerTaskNormal( uint32_t RetainerTaskNormalId ); - boost::shared_ptr< RetainerTaskParameter > getRetainerTaskParameter( uint32_t RetainerTaskParameterId ); - boost::shared_ptr< RetainerTaskRandom > getRetainerTaskRandom( uint32_t RetainerTaskRandomId ); - boost::shared_ptr< Salvage > getSalvage( uint32_t SalvageId ); - boost::shared_ptr< SatisfactionNpc > getSatisfactionNpc( uint32_t SatisfactionNpcId ); - boost::shared_ptr< SatisfactionSupply > getSatisfactionSupply( uint32_t SatisfactionSupplyId ); - boost::shared_ptr< SatisfactionSupplyReward > getSatisfactionSupplyReward( uint32_t SatisfactionSupplyRewardId ); - boost::shared_ptr< ScreenImage > getScreenImage( uint32_t ScreenImageId ); - boost::shared_ptr< SecretRecipeBook > getSecretRecipeBook( uint32_t SecretRecipeBookId ); - boost::shared_ptr< SpearfishingItem > getSpearfishingItem( uint32_t SpearfishingItemId ); - boost::shared_ptr< SpearfishingNotebook > getSpearfishingNotebook( uint32_t SpearfishingNotebookId ); - boost::shared_ptr< SpecialShop > getSpecialShop( uint32_t SpecialShopId ); - boost::shared_ptr< SpecialShopItemCategory > getSpecialShopItemCategory( uint32_t SpecialShopItemCategoryId ); - boost::shared_ptr< Stain > getStain( uint32_t StainId ); - boost::shared_ptr< Status > getStatus( uint32_t StatusId ); - boost::shared_ptr< Story > getStory( uint32_t StoryId ); - boost::shared_ptr< SwitchTalk > getSwitchTalk( uint32_t SwitchTalkId ); - boost::shared_ptr< TerritoryType > getTerritoryType( uint32_t TerritoryTypeId ); - boost::shared_ptr< TextCommand > getTextCommand( uint32_t TextCommandId ); - boost::shared_ptr< Title > getTitle( uint32_t TitleId ); - boost::shared_ptr< Tomestones > getTomestones( uint32_t TomestonesId ); - boost::shared_ptr< TomestonesItem > getTomestonesItem( uint32_t TomestonesItemId ); - boost::shared_ptr< TopicSelect > getTopicSelect( uint32_t TopicSelectId ); - boost::shared_ptr< Town > getTown( uint32_t TownId ); - boost::shared_ptr< Trait > getTrait( uint32_t TraitId ); - boost::shared_ptr< TraitRecast > getTraitRecast( uint32_t TraitRecastId ); - boost::shared_ptr< TraitTransient > getTraitTransient( uint32_t TraitTransientId ); - boost::shared_ptr< Tribe > getTribe( uint32_t TribeId ); - boost::shared_ptr< TripleTriad > getTripleTriad( uint32_t TripleTriadId ); - boost::shared_ptr< TripleTriadCard > getTripleTriadCard( uint32_t TripleTriadCardId ); - boost::shared_ptr< TripleTriadCardRarity > getTripleTriadCardRarity( uint32_t TripleTriadCardRarityId ); - boost::shared_ptr< TripleTriadCardResident > getTripleTriadCardResident( uint32_t TripleTriadCardResidentId ); - boost::shared_ptr< TripleTriadCardType > getTripleTriadCardType( uint32_t TripleTriadCardTypeId ); - boost::shared_ptr< TripleTriadCompetition > getTripleTriadCompetition( uint32_t TripleTriadCompetitionId ); - boost::shared_ptr< TripleTriadRule > getTripleTriadRule( uint32_t TripleTriadRuleId ); - boost::shared_ptr< Tutorial > getTutorial( uint32_t TutorialId ); - boost::shared_ptr< TutorialDPS > getTutorialDPS( uint32_t TutorialDPSId ); - boost::shared_ptr< TutorialHealer > getTutorialHealer( uint32_t TutorialHealerId ); - boost::shared_ptr< TutorialTank > getTutorialTank( uint32_t TutorialTankId ); - boost::shared_ptr< Warp > getWarp( uint32_t WarpId ); - boost::shared_ptr< Weather > getWeather( uint32_t WeatherId ); - boost::shared_ptr< WeatherGroup > getWeatherGroup( uint32_t WeatherGroupId ); - boost::shared_ptr< WeatherRate > getWeatherRate( uint32_t WeatherRateId ); - boost::shared_ptr< WeeklyBingoOrderData > getWeeklyBingoOrderData( uint32_t WeeklyBingoOrderDataId ); - boost::shared_ptr< WeeklyBingoRewardData > getWeeklyBingoRewardData( uint32_t WeeklyBingoRewardDataId ); - boost::shared_ptr< WeeklyBingoText > getWeeklyBingoText( uint32_t WeeklyBingoTextId ); - boost::shared_ptr< WorldDCGroupType > getWorldDCGroupType( uint32_t WorldDCGroupTypeId ); + using AchievementPtr = boost::shared_ptr< Achievement >; + AchievementPtr getAchievement( uint32_t AchievementId ); + using AchievementCategoryPtr = boost::shared_ptr< AchievementCategory >; + AchievementCategoryPtr getAchievementCategory( uint32_t AchievementCategoryId ); + using AchievementKindPtr = boost::shared_ptr< AchievementKind >; + AchievementKindPtr getAchievementKind( uint32_t AchievementKindId ); + using ActionPtr = boost::shared_ptr< Action >; + ActionPtr getAction( uint32_t ActionId ); + using ActionCategoryPtr = boost::shared_ptr< ActionCategory >; + ActionCategoryPtr getActionCategory( uint32_t ActionCategoryId ); + using ActionComboRoutePtr = boost::shared_ptr< ActionComboRoute >; + ActionComboRoutePtr getActionComboRoute( uint32_t ActionComboRouteId ); + using ActionIndirectionPtr = boost::shared_ptr< ActionIndirection >; + ActionIndirectionPtr getActionIndirection( uint32_t ActionIndirectionId ); + using ActionProcStatusPtr = boost::shared_ptr< ActionProcStatus >; + ActionProcStatusPtr getActionProcStatus( uint32_t ActionProcStatusId ); + using ActionTimelinePtr = boost::shared_ptr< ActionTimeline >; + ActionTimelinePtr getActionTimeline( uint32_t ActionTimelineId ); + using ActionTransientPtr = boost::shared_ptr< ActionTransient >; + ActionTransientPtr getActionTransient( uint32_t ActionTransientId ); + using AddonPtr = boost::shared_ptr< Addon >; + AddonPtr getAddon( uint32_t AddonId ); + using AdventurePtr = boost::shared_ptr< Adventure >; + AdventurePtr getAdventure( uint32_t AdventureId ); + using AdventureExPhasePtr = boost::shared_ptr< AdventureExPhase >; + AdventureExPhasePtr getAdventureExPhase( uint32_t AdventureExPhaseId ); + using AetherCurrentPtr = boost::shared_ptr< AetherCurrent >; + AetherCurrentPtr getAetherCurrent( uint32_t AetherCurrentId ); + using AetherialWheelPtr = boost::shared_ptr< AetherialWheel >; + AetherialWheelPtr getAetherialWheel( uint32_t AetherialWheelId ); + using AetherytePtr = boost::shared_ptr< Aetheryte >; + AetherytePtr getAetheryte( uint32_t AetheryteId ); + using AirshipExplorationLevelPtr = boost::shared_ptr< AirshipExplorationLevel >; + AirshipExplorationLevelPtr getAirshipExplorationLevel( uint32_t AirshipExplorationLevelId ); + using AirshipExplorationLogPtr = boost::shared_ptr< AirshipExplorationLog >; + AirshipExplorationLogPtr getAirshipExplorationLog( uint32_t AirshipExplorationLogId ); + using AirshipExplorationParamTypePtr = boost::shared_ptr< AirshipExplorationParamType >; + AirshipExplorationParamTypePtr getAirshipExplorationParamType( uint32_t AirshipExplorationParamTypeId ); + using AirshipExplorationPartPtr = boost::shared_ptr< AirshipExplorationPart >; + AirshipExplorationPartPtr getAirshipExplorationPart( uint32_t AirshipExplorationPartId ); + using AirshipExplorationPointPtr = boost::shared_ptr< AirshipExplorationPoint >; + AirshipExplorationPointPtr getAirshipExplorationPoint( uint32_t AirshipExplorationPointId ); + using AnimaWeapon5Ptr = boost::shared_ptr< AnimaWeapon5 >; + AnimaWeapon5Ptr getAnimaWeapon5( uint32_t AnimaWeapon5Id ); + using AnimaWeapon5ParamPtr = boost::shared_ptr< AnimaWeapon5Param >; + AnimaWeapon5ParamPtr getAnimaWeapon5Param( uint32_t AnimaWeapon5ParamId ); + using AnimaWeapon5PatternGroupPtr = boost::shared_ptr< AnimaWeapon5PatternGroup >; + AnimaWeapon5PatternGroupPtr getAnimaWeapon5PatternGroup( uint32_t AnimaWeapon5PatternGroupId ); + using AnimaWeapon5SpiritTalkPtr = boost::shared_ptr< AnimaWeapon5SpiritTalk >; + AnimaWeapon5SpiritTalkPtr getAnimaWeapon5SpiritTalk( uint32_t AnimaWeapon5SpiritTalkId ); + using AnimaWeapon5SpiritTalkParamPtr = boost::shared_ptr< AnimaWeapon5SpiritTalkParam >; + AnimaWeapon5SpiritTalkParamPtr getAnimaWeapon5SpiritTalkParam( uint32_t AnimaWeapon5SpiritTalkParamId ); + using AnimaWeapon5TradeItemPtr = boost::shared_ptr< AnimaWeapon5TradeItem >; + AnimaWeapon5TradeItemPtr getAnimaWeapon5TradeItem( uint32_t AnimaWeapon5TradeItemId ); + using AnimaWeaponFUITalkPtr = boost::shared_ptr< AnimaWeaponFUITalk >; + AnimaWeaponFUITalkPtr getAnimaWeaponFUITalk( uint32_t AnimaWeaponFUITalkId ); + using AnimaWeaponFUITalkParamPtr = boost::shared_ptr< AnimaWeaponFUITalkParam >; + AnimaWeaponFUITalkParamPtr getAnimaWeaponFUITalkParam( uint32_t AnimaWeaponFUITalkParamId ); + using AnimaWeaponIconPtr = boost::shared_ptr< AnimaWeaponIcon >; + AnimaWeaponIconPtr getAnimaWeaponIcon( uint32_t AnimaWeaponIconId ); + using AnimaWeaponItemPtr = boost::shared_ptr< AnimaWeaponItem >; + AnimaWeaponItemPtr getAnimaWeaponItem( uint32_t AnimaWeaponItemId ); + using AquariumFishPtr = boost::shared_ptr< AquariumFish >; + AquariumFishPtr getAquariumFish( uint32_t AquariumFishId ); + using AquariumWaterPtr = boost::shared_ptr< AquariumWater >; + AquariumWaterPtr getAquariumWater( uint32_t AquariumWaterId ); + using AttackTypePtr = boost::shared_ptr< AttackType >; + AttackTypePtr getAttackType( uint32_t AttackTypeId ); + using BalloonPtr = boost::shared_ptr< Balloon >; + BalloonPtr getBalloon( uint32_t BalloonId ); + using BaseParamPtr = boost::shared_ptr< BaseParam >; + BaseParamPtr getBaseParam( uint32_t BaseParamId ); + using BattleLevePtr = boost::shared_ptr< BattleLeve >; + BattleLevePtr getBattleLeve( uint32_t BattleLeveId ); + using BeastRankBonusPtr = boost::shared_ptr< BeastRankBonus >; + BeastRankBonusPtr getBeastRankBonus( uint32_t BeastRankBonusId ); + using BeastReputationRankPtr = boost::shared_ptr< BeastReputationRank >; + BeastReputationRankPtr getBeastReputationRank( uint32_t BeastReputationRankId ); + using BeastTribePtr = boost::shared_ptr< BeastTribe >; + BeastTribePtr getBeastTribe( uint32_t BeastTribeId ); + using BehaviorPtr = boost::shared_ptr< Behavior >; + BehaviorPtr getBehavior( uint32_t BehaviorId ); + using BGMPtr = boost::shared_ptr< BGM >; + BGMPtr getBGM( uint32_t BGMId ); + using BNpcAnnounceIconPtr = boost::shared_ptr< BNpcAnnounceIcon >; + BNpcAnnounceIconPtr getBNpcAnnounceIcon( uint32_t BNpcAnnounceIconId ); + using BNpcBasePtr = boost::shared_ptr< BNpcBase >; + BNpcBasePtr getBNpcBase( uint32_t BNpcBaseId ); + using BNpcCustomizePtr = boost::shared_ptr< BNpcCustomize >; + BNpcCustomizePtr getBNpcCustomize( uint32_t BNpcCustomizeId ); + using BNpcNamePtr = boost::shared_ptr< BNpcName >; + BNpcNamePtr getBNpcName( uint32_t BNpcNameId ); + using BuddyActionPtr = boost::shared_ptr< BuddyAction >; + BuddyActionPtr getBuddyAction( uint32_t BuddyActionId ); + using BuddyEquipPtr = boost::shared_ptr< BuddyEquip >; + BuddyEquipPtr getBuddyEquip( uint32_t BuddyEquipId ); + using BuddyItemPtr = boost::shared_ptr< BuddyItem >; + BuddyItemPtr getBuddyItem( uint32_t BuddyItemId ); + using BuddyRankPtr = boost::shared_ptr< BuddyRank >; + BuddyRankPtr getBuddyRank( uint32_t BuddyRankId ); + using BuddySkillPtr = boost::shared_ptr< BuddySkill >; + BuddySkillPtr getBuddySkill( uint32_t BuddySkillId ); + using CabinetPtr = boost::shared_ptr< Cabinet >; + CabinetPtr getCabinet( uint32_t CabinetId ); + using CabinetCategoryPtr = boost::shared_ptr< CabinetCategory >; + CabinetCategoryPtr getCabinetCategory( uint32_t CabinetCategoryId ); + using CalendarPtr = boost::shared_ptr< Calendar >; + CalendarPtr getCalendar( uint32_t CalendarId ); + using CharaMakeCustomizePtr = boost::shared_ptr< CharaMakeCustomize >; + CharaMakeCustomizePtr getCharaMakeCustomize( uint32_t CharaMakeCustomizeId ); + using CharaMakeTypePtr = boost::shared_ptr< CharaMakeType >; + CharaMakeTypePtr getCharaMakeType( uint32_t CharaMakeTypeId ); + using ChocoboRacePtr = boost::shared_ptr< ChocoboRace >; + ChocoboRacePtr getChocoboRace( uint32_t ChocoboRaceId ); + using ChocoboRaceAbilityPtr = boost::shared_ptr< ChocoboRaceAbility >; + ChocoboRaceAbilityPtr getChocoboRaceAbility( uint32_t ChocoboRaceAbilityId ); + using ChocoboRaceAbilityTypePtr = boost::shared_ptr< ChocoboRaceAbilityType >; + ChocoboRaceAbilityTypePtr getChocoboRaceAbilityType( uint32_t ChocoboRaceAbilityTypeId ); + using ChocoboRaceItemPtr = boost::shared_ptr< ChocoboRaceItem >; + ChocoboRaceItemPtr getChocoboRaceItem( uint32_t ChocoboRaceItemId ); + using ChocoboRaceRankPtr = boost::shared_ptr< ChocoboRaceRank >; + ChocoboRaceRankPtr getChocoboRaceRank( uint32_t ChocoboRaceRankId ); + using ChocoboRaceStatusPtr = boost::shared_ptr< ChocoboRaceStatus >; + ChocoboRaceStatusPtr getChocoboRaceStatus( uint32_t ChocoboRaceStatusId ); + using ChocoboRaceTerritoryPtr = boost::shared_ptr< ChocoboRaceTerritory >; + ChocoboRaceTerritoryPtr getChocoboRaceTerritory( uint32_t ChocoboRaceTerritoryId ); + using ChocoboTaxiStandPtr = boost::shared_ptr< ChocoboTaxiStand >; + ChocoboTaxiStandPtr getChocoboTaxiStand( uint32_t ChocoboTaxiStandId ); + using ClassJobPtr = boost::shared_ptr< ClassJob >; + ClassJobPtr getClassJob( uint32_t ClassJobId ); + using ClassJobCategoryPtr = boost::shared_ptr< ClassJobCategory >; + ClassJobCategoryPtr getClassJobCategory( uint32_t ClassJobCategoryId ); + using CompanionPtr = boost::shared_ptr< Companion >; + CompanionPtr getCompanion( uint32_t CompanionId ); + using CompanionMovePtr = boost::shared_ptr< CompanionMove >; + CompanionMovePtr getCompanionMove( uint32_t CompanionMoveId ); + using CompanionTransientPtr = boost::shared_ptr< CompanionTransient >; + CompanionTransientPtr getCompanionTransient( uint32_t CompanionTransientId ); + using CompanyActionPtr = boost::shared_ptr< CompanyAction >; + CompanyActionPtr getCompanyAction( uint32_t CompanyActionId ); + using CompanyCraftDraftPtr = boost::shared_ptr< CompanyCraftDraft >; + CompanyCraftDraftPtr getCompanyCraftDraft( uint32_t CompanyCraftDraftId ); + using CompanyCraftDraftCategoryPtr = boost::shared_ptr< CompanyCraftDraftCategory >; + CompanyCraftDraftCategoryPtr getCompanyCraftDraftCategory( uint32_t CompanyCraftDraftCategoryId ); + using CompanyCraftManufactoryStatePtr = boost::shared_ptr< CompanyCraftManufactoryState >; + CompanyCraftManufactoryStatePtr getCompanyCraftManufactoryState( uint32_t CompanyCraftManufactoryStateId ); + using CompanyCraftPartPtr = boost::shared_ptr< CompanyCraftPart >; + CompanyCraftPartPtr getCompanyCraftPart( uint32_t CompanyCraftPartId ); + using CompanyCraftProcessPtr = boost::shared_ptr< CompanyCraftProcess >; + CompanyCraftProcessPtr getCompanyCraftProcess( uint32_t CompanyCraftProcessId ); + using CompanyCraftSequencePtr = boost::shared_ptr< CompanyCraftSequence >; + CompanyCraftSequencePtr getCompanyCraftSequence( uint32_t CompanyCraftSequenceId ); + using CompanyCraftSupplyItemPtr = boost::shared_ptr< CompanyCraftSupplyItem >; + CompanyCraftSupplyItemPtr getCompanyCraftSupplyItem( uint32_t CompanyCraftSupplyItemId ); + using CompanyCraftTypePtr = boost::shared_ptr< CompanyCraftType >; + CompanyCraftTypePtr getCompanyCraftType( uint32_t CompanyCraftTypeId ); + using CompleteJournalPtr = boost::shared_ptr< CompleteJournal >; + CompleteJournalPtr getCompleteJournal( uint32_t CompleteJournalId ); + using CompleteJournalCategoryPtr = boost::shared_ptr< CompleteJournalCategory >; + CompleteJournalCategoryPtr getCompleteJournalCategory( uint32_t CompleteJournalCategoryId ); + using ContentExActionPtr = boost::shared_ptr< ContentExAction >; + ContentExActionPtr getContentExAction( uint32_t ContentExActionId ); + using ContentFinderConditionPtr = boost::shared_ptr< ContentFinderCondition >; + ContentFinderConditionPtr getContentFinderCondition( uint32_t ContentFinderConditionId ); + using ContentFinderConditionTransientPtr = boost::shared_ptr< ContentFinderConditionTransient >; + ContentFinderConditionTransientPtr getContentFinderConditionTransient( uint32_t ContentFinderConditionTransientId ); + using ContentMemberTypePtr = boost::shared_ptr< ContentMemberType >; + ContentMemberTypePtr getContentMemberType( uint32_t ContentMemberTypeId ); + using ContentRoulettePtr = boost::shared_ptr< ContentRoulette >; + ContentRoulettePtr getContentRoulette( uint32_t ContentRouletteId ); + using ContentTypePtr = boost::shared_ptr< ContentType >; + ContentTypePtr getContentType( uint32_t ContentTypeId ); + using CraftActionPtr = boost::shared_ptr< CraftAction >; + CraftActionPtr getCraftAction( uint32_t CraftActionId ); + using CraftLevePtr = boost::shared_ptr< CraftLeve >; + CraftLevePtr getCraftLeve( uint32_t CraftLeveId ); + using CraftTypePtr = boost::shared_ptr< CraftType >; + CraftTypePtr getCraftType( uint32_t CraftTypeId ); + using CurrencyPtr = boost::shared_ptr< Currency >; + CurrencyPtr getCurrency( uint32_t CurrencyId ); + using CustomTalkPtr = boost::shared_ptr< CustomTalk >; + CustomTalkPtr getCustomTalk( uint32_t CustomTalkId ); + using CutscenePtr = boost::shared_ptr< Cutscene >; + CutscenePtr getCutscene( uint32_t CutsceneId ); + using CutScreenImagePtr = boost::shared_ptr< CutScreenImage >; + CutScreenImagePtr getCutScreenImage( uint32_t CutScreenImageId ); + using DailySupplyItemPtr = boost::shared_ptr< DailySupplyItem >; + DailySupplyItemPtr getDailySupplyItem( uint32_t DailySupplyItemId ); + using DeepDungeonBanPtr = boost::shared_ptr< DeepDungeonBan >; + DeepDungeonBanPtr getDeepDungeonBan( uint32_t DeepDungeonBanId ); + using DeepDungeonDangerPtr = boost::shared_ptr< DeepDungeonDanger >; + DeepDungeonDangerPtr getDeepDungeonDanger( uint32_t DeepDungeonDangerId ); + using DeepDungeonEquipmentPtr = boost::shared_ptr< DeepDungeonEquipment >; + DeepDungeonEquipmentPtr getDeepDungeonEquipment( uint32_t DeepDungeonEquipmentId ); + using DeepDungeonFloorEffectUIPtr = boost::shared_ptr< DeepDungeonFloorEffectUI >; + DeepDungeonFloorEffectUIPtr getDeepDungeonFloorEffectUI( uint32_t DeepDungeonFloorEffectUIId ); + using DeepDungeonItemPtr = boost::shared_ptr< DeepDungeonItem >; + DeepDungeonItemPtr getDeepDungeonItem( uint32_t DeepDungeonItemId ); + using DeepDungeonStatusPtr = boost::shared_ptr< DeepDungeonStatus >; + DeepDungeonStatusPtr getDeepDungeonStatus( uint32_t DeepDungeonStatusId ); + using DefaultTalkPtr = boost::shared_ptr< DefaultTalk >; + DefaultTalkPtr getDefaultTalk( uint32_t DefaultTalkId ); + using DeliveryQuestPtr = boost::shared_ptr< DeliveryQuest >; + DeliveryQuestPtr getDeliveryQuest( uint32_t DeliveryQuestId ); + using DisposalShopPtr = boost::shared_ptr< DisposalShop >; + DisposalShopPtr getDisposalShop( uint32_t DisposalShopId ); + using DisposalShopFilterTypePtr = boost::shared_ptr< DisposalShopFilterType >; + DisposalShopFilterTypePtr getDisposalShopFilterType( uint32_t DisposalShopFilterTypeId ); + using DisposalShopItemPtr = boost::shared_ptr< DisposalShopItem >; + DisposalShopItemPtr getDisposalShopItem( uint32_t DisposalShopItemId ); + using DpsChallengePtr = boost::shared_ptr< DpsChallenge >; + DpsChallengePtr getDpsChallenge( uint32_t DpsChallengeId ); + using DpsChallengeOfficerPtr = boost::shared_ptr< DpsChallengeOfficer >; + DpsChallengeOfficerPtr getDpsChallengeOfficer( uint32_t DpsChallengeOfficerId ); + using DpsChallengeTransientPtr = boost::shared_ptr< DpsChallengeTransient >; + DpsChallengeTransientPtr getDpsChallengeTransient( uint32_t DpsChallengeTransientId ); + using EmotePtr = boost::shared_ptr< Emote >; + EmotePtr getEmote( uint32_t EmoteId ); + using EmoteCategoryPtr = boost::shared_ptr< EmoteCategory >; + EmoteCategoryPtr getEmoteCategory( uint32_t EmoteCategoryId ); + using ENpcBasePtr = boost::shared_ptr< ENpcBase >; + ENpcBasePtr getENpcBase( uint32_t ENpcBaseId ); + using ENpcResidentPtr = boost::shared_ptr< ENpcResident >; + ENpcResidentPtr getENpcResident( uint32_t ENpcResidentId ); + using EObjPtr = boost::shared_ptr< EObj >; + EObjPtr getEObj( uint32_t EObjId ); + using EquipRaceCategoryPtr = boost::shared_ptr< EquipRaceCategory >; + EquipRaceCategoryPtr getEquipRaceCategory( uint32_t EquipRaceCategoryId ); + using EquipSlotCategoryPtr = boost::shared_ptr< EquipSlotCategory >; + EquipSlotCategoryPtr getEquipSlotCategory( uint32_t EquipSlotCategoryId ); + using EventActionPtr = boost::shared_ptr< EventAction >; + EventActionPtr getEventAction( uint32_t EventActionId ); + using EventIconPriorityPtr = boost::shared_ptr< EventIconPriority >; + EventIconPriorityPtr getEventIconPriority( uint32_t EventIconPriorityId ); + using EventIconTypePtr = boost::shared_ptr< EventIconType >; + EventIconTypePtr getEventIconType( uint32_t EventIconTypeId ); + using EventItemPtr = boost::shared_ptr< EventItem >; + EventItemPtr getEventItem( uint32_t EventItemId ); + using EventItemHelpPtr = boost::shared_ptr< EventItemHelp >; + EventItemHelpPtr getEventItemHelp( uint32_t EventItemHelpId ); + using ExVersionPtr = boost::shared_ptr< ExVersion >; + ExVersionPtr getExVersion( uint32_t ExVersionId ); + using FatePtr = boost::shared_ptr< Fate >; + FatePtr getFate( uint32_t FateId ); + using FCActivityPtr = boost::shared_ptr< FCActivity >; + FCActivityPtr getFCActivity( uint32_t FCActivityId ); + using FCActivityCategoryPtr = boost::shared_ptr< FCActivityCategory >; + FCActivityCategoryPtr getFCActivityCategory( uint32_t FCActivityCategoryId ); + using FCAuthorityPtr = boost::shared_ptr< FCAuthority >; + FCAuthorityPtr getFCAuthority( uint32_t FCAuthorityId ); + using FCAuthorityCategoryPtr = boost::shared_ptr< FCAuthorityCategory >; + FCAuthorityCategoryPtr getFCAuthorityCategory( uint32_t FCAuthorityCategoryId ); + using FCChestNamePtr = boost::shared_ptr< FCChestName >; + FCChestNamePtr getFCChestName( uint32_t FCChestNameId ); + using FccShopPtr = boost::shared_ptr< FccShop >; + FccShopPtr getFccShop( uint32_t FccShopId ); + using FCHierarchyPtr = boost::shared_ptr< FCHierarchy >; + FCHierarchyPtr getFCHierarchy( uint32_t FCHierarchyId ); + using FCProfilePtr = boost::shared_ptr< FCProfile >; + FCProfilePtr getFCProfile( uint32_t FCProfileId ); + using FCReputationPtr = boost::shared_ptr< FCReputation >; + FCReputationPtr getFCReputation( uint32_t FCReputationId ); + using FCRightsPtr = boost::shared_ptr< FCRights >; + FCRightsPtr getFCRights( uint32_t FCRightsId ); + using FishingSpotPtr = boost::shared_ptr< FishingSpot >; + FishingSpotPtr getFishingSpot( uint32_t FishingSpotId ); + using FishParameterPtr = boost::shared_ptr< FishParameter >; + FishParameterPtr getFishParameter( uint32_t FishParameterId ); + using GardeningSeedPtr = boost::shared_ptr< GardeningSeed >; + GardeningSeedPtr getGardeningSeed( uint32_t GardeningSeedId ); + using GatheringConditionPtr = boost::shared_ptr< GatheringCondition >; + GatheringConditionPtr getGatheringCondition( uint32_t GatheringConditionId ); + using GatheringExpPtr = boost::shared_ptr< GatheringExp >; + GatheringExpPtr getGatheringExp( uint32_t GatheringExpId ); + using GatheringItemPtr = boost::shared_ptr< GatheringItem >; + GatheringItemPtr getGatheringItem( uint32_t GatheringItemId ); + using GatheringItemLevelConvertTablePtr = boost::shared_ptr< GatheringItemLevelConvertTable >; + GatheringItemLevelConvertTablePtr getGatheringItemLevelConvertTable( uint32_t GatheringItemLevelConvertTableId ); + using GatheringItemPointPtr = boost::shared_ptr< GatheringItemPoint >; + GatheringItemPointPtr getGatheringItemPoint( uint32_t GatheringItemPointId ); + using GatheringNotebookListPtr = boost::shared_ptr< GatheringNotebookList >; + GatheringNotebookListPtr getGatheringNotebookList( uint32_t GatheringNotebookListId ); + using GatheringPointPtr = boost::shared_ptr< GatheringPoint >; + GatheringPointPtr getGatheringPoint( uint32_t GatheringPointId ); + using GatheringPointBasePtr = boost::shared_ptr< GatheringPointBase >; + GatheringPointBasePtr getGatheringPointBase( uint32_t GatheringPointBaseId ); + using GatheringPointBonusPtr = boost::shared_ptr< GatheringPointBonus >; + GatheringPointBonusPtr getGatheringPointBonus( uint32_t GatheringPointBonusId ); + using GatheringPointBonusTypePtr = boost::shared_ptr< GatheringPointBonusType >; + GatheringPointBonusTypePtr getGatheringPointBonusType( uint32_t GatheringPointBonusTypeId ); + using GatheringPointNamePtr = boost::shared_ptr< GatheringPointName >; + GatheringPointNamePtr getGatheringPointName( uint32_t GatheringPointNameId ); + using GatheringSubCategoryPtr = boost::shared_ptr< GatheringSubCategory >; + GatheringSubCategoryPtr getGatheringSubCategory( uint32_t GatheringSubCategoryId ); + using GatheringTypePtr = boost::shared_ptr< GatheringType >; + GatheringTypePtr getGatheringType( uint32_t GatheringTypeId ); + using GcArmyExpeditionPtr = boost::shared_ptr< GcArmyExpedition >; + GcArmyExpeditionPtr getGcArmyExpedition( uint32_t GcArmyExpeditionId ); + using GcArmyExpeditionMemberBonusPtr = boost::shared_ptr< GcArmyExpeditionMemberBonus >; + GcArmyExpeditionMemberBonusPtr getGcArmyExpeditionMemberBonus( uint32_t GcArmyExpeditionMemberBonusId ); + using GcArmyExpeditionTypePtr = boost::shared_ptr< GcArmyExpeditionType >; + GcArmyExpeditionTypePtr getGcArmyExpeditionType( uint32_t GcArmyExpeditionTypeId ); + using GcArmyMemberGrowPtr = boost::shared_ptr< GcArmyMemberGrow >; + GcArmyMemberGrowPtr getGcArmyMemberGrow( uint32_t GcArmyMemberGrowId ); + using GcArmyTrainingPtr = boost::shared_ptr< GcArmyTraining >; + GcArmyTrainingPtr getGcArmyTraining( uint32_t GcArmyTrainingId ); + using GCRankGridaniaFemaleTextPtr = boost::shared_ptr< GCRankGridaniaFemaleText >; + GCRankGridaniaFemaleTextPtr getGCRankGridaniaFemaleText( uint32_t GCRankGridaniaFemaleTextId ); + using GCRankGridaniaMaleTextPtr = boost::shared_ptr< GCRankGridaniaMaleText >; + GCRankGridaniaMaleTextPtr getGCRankGridaniaMaleText( uint32_t GCRankGridaniaMaleTextId ); + using GCRankLimsaFemaleTextPtr = boost::shared_ptr< GCRankLimsaFemaleText >; + GCRankLimsaFemaleTextPtr getGCRankLimsaFemaleText( uint32_t GCRankLimsaFemaleTextId ); + using GCRankLimsaMaleTextPtr = boost::shared_ptr< GCRankLimsaMaleText >; + GCRankLimsaMaleTextPtr getGCRankLimsaMaleText( uint32_t GCRankLimsaMaleTextId ); + using GCRankUldahFemaleTextPtr = boost::shared_ptr< GCRankUldahFemaleText >; + GCRankUldahFemaleTextPtr getGCRankUldahFemaleText( uint32_t GCRankUldahFemaleTextId ); + using GCRankUldahMaleTextPtr = boost::shared_ptr< GCRankUldahMaleText >; + GCRankUldahMaleTextPtr getGCRankUldahMaleText( uint32_t GCRankUldahMaleTextId ); + using GCScripShopCategoryPtr = boost::shared_ptr< GCScripShopCategory >; + GCScripShopCategoryPtr getGCScripShopCategory( uint32_t GCScripShopCategoryId ); + using GCScripShopItemPtr = boost::shared_ptr< GCScripShopItem >; + GCScripShopItemPtr getGCScripShopItem( uint32_t GCScripShopItemId ); + using GCShopPtr = boost::shared_ptr< GCShop >; + GCShopPtr getGCShop( uint32_t GCShopId ); + using GCShopItemCategoryPtr = boost::shared_ptr< GCShopItemCategory >; + GCShopItemCategoryPtr getGCShopItemCategory( uint32_t GCShopItemCategoryId ); + using GCSupplyDutyPtr = boost::shared_ptr< GCSupplyDuty >; + GCSupplyDutyPtr getGCSupplyDuty( uint32_t GCSupplyDutyId ); + using GCSupplyDutyRewardPtr = boost::shared_ptr< GCSupplyDutyReward >; + GCSupplyDutyRewardPtr getGCSupplyDutyReward( uint32_t GCSupplyDutyRewardId ); + using GeneralActionPtr = boost::shared_ptr< GeneralAction >; + GeneralActionPtr getGeneralAction( uint32_t GeneralActionId ); + using GilShopPtr = boost::shared_ptr< GilShop >; + GilShopPtr getGilShop( uint32_t GilShopId ); + using GilShopItemPtr = boost::shared_ptr< GilShopItem >; + GilShopItemPtr getGilShopItem( uint32_t GilShopItemId ); + using GoldSaucerTextDataPtr = boost::shared_ptr< GoldSaucerTextData >; + GoldSaucerTextDataPtr getGoldSaucerTextData( uint32_t GoldSaucerTextDataId ); + using GrandCompanyPtr = boost::shared_ptr< GrandCompany >; + GrandCompanyPtr getGrandCompany( uint32_t GrandCompanyId ); + using GrandCompanyRankPtr = boost::shared_ptr< GrandCompanyRank >; + GrandCompanyRankPtr getGrandCompanyRank( uint32_t GrandCompanyRankId ); + using GuardianDeityPtr = boost::shared_ptr< GuardianDeity >; + GuardianDeityPtr getGuardianDeity( uint32_t GuardianDeityId ); + using GuildleveAssignmentPtr = boost::shared_ptr< GuildleveAssignment >; + GuildleveAssignmentPtr getGuildleveAssignment( uint32_t GuildleveAssignmentId ); + using GuildOrderGuidePtr = boost::shared_ptr< GuildOrderGuide >; + GuildOrderGuidePtr getGuildOrderGuide( uint32_t GuildOrderGuideId ); + using GuildOrderOfficerPtr = boost::shared_ptr< GuildOrderOfficer >; + GuildOrderOfficerPtr getGuildOrderOfficer( uint32_t GuildOrderOfficerId ); + using HouseRetainerPosePtr = boost::shared_ptr< HouseRetainerPose >; + HouseRetainerPosePtr getHouseRetainerPose( uint32_t HouseRetainerPoseId ); + using HousingFurniturePtr = boost::shared_ptr< HousingFurniture >; + HousingFurniturePtr getHousingFurniture( uint32_t HousingFurnitureId ); + using HousingYardObjectPtr = boost::shared_ptr< HousingYardObject >; + HousingYardObjectPtr getHousingYardObject( uint32_t HousingYardObjectId ); + using InstanceContentPtr = boost::shared_ptr< InstanceContent >; + InstanceContentPtr getInstanceContent( uint32_t InstanceContentId ); + using InstanceContentBuffPtr = boost::shared_ptr< InstanceContentBuff >; + InstanceContentBuffPtr getInstanceContentBuff( uint32_t InstanceContentBuffId ); + using InstanceContentTextDataPtr = boost::shared_ptr< InstanceContentTextData >; + InstanceContentTextDataPtr getInstanceContentTextData( uint32_t InstanceContentTextDataId ); + using InstanceContentTypePtr = boost::shared_ptr< InstanceContentType >; + InstanceContentTypePtr getInstanceContentType( uint32_t InstanceContentTypeId ); + using ItemPtr = boost::shared_ptr< Item >; + ItemPtr getItem( uint32_t ItemId ); + using ItemActionPtr = boost::shared_ptr< ItemAction >; + ItemActionPtr getItemAction( uint32_t ItemActionId ); + using ItemFoodPtr = boost::shared_ptr< ItemFood >; + ItemFoodPtr getItemFood( uint32_t ItemFoodId ); + using ItemSearchCategoryPtr = boost::shared_ptr< ItemSearchCategory >; + ItemSearchCategoryPtr getItemSearchCategory( uint32_t ItemSearchCategoryId ); + using ItemSeriesPtr = boost::shared_ptr< ItemSeries >; + ItemSeriesPtr getItemSeries( uint32_t ItemSeriesId ); + using ItemSpecialBonusPtr = boost::shared_ptr< ItemSpecialBonus >; + ItemSpecialBonusPtr getItemSpecialBonus( uint32_t ItemSpecialBonusId ); + using ItemUICategoryPtr = boost::shared_ptr< ItemUICategory >; + ItemUICategoryPtr getItemUICategory( uint32_t ItemUICategoryId ); + using JournalCategoryPtr = boost::shared_ptr< JournalCategory >; + JournalCategoryPtr getJournalCategory( uint32_t JournalCategoryId ); + using JournalGenrePtr = boost::shared_ptr< JournalGenre >; + JournalGenrePtr getJournalGenre( uint32_t JournalGenreId ); + using JournalSectionPtr = boost::shared_ptr< JournalSection >; + JournalSectionPtr getJournalSection( uint32_t JournalSectionId ); + using LevePtr = boost::shared_ptr< Leve >; + LevePtr getLeve( uint32_t LeveId ); + using LeveAssignmentTypePtr = boost::shared_ptr< LeveAssignmentType >; + LeveAssignmentTypePtr getLeveAssignmentType( uint32_t LeveAssignmentTypeId ); + using LeveClientPtr = boost::shared_ptr< LeveClient >; + LeveClientPtr getLeveClient( uint32_t LeveClientId ); + using LevelPtr = boost::shared_ptr< Level >; + LevelPtr getLevel( uint32_t LevelId ); + using LeveRewardItemPtr = boost::shared_ptr< LeveRewardItem >; + LeveRewardItemPtr getLeveRewardItem( uint32_t LeveRewardItemId ); + using LeveRewardItemGroupPtr = boost::shared_ptr< LeveRewardItemGroup >; + LeveRewardItemGroupPtr getLeveRewardItemGroup( uint32_t LeveRewardItemGroupId ); + using LeveVfxPtr = boost::shared_ptr< LeveVfx >; + LeveVfxPtr getLeveVfx( uint32_t LeveVfxId ); + using LogFilterPtr = boost::shared_ptr< LogFilter >; + LogFilterPtr getLogFilter( uint32_t LogFilterId ); + using LogKindPtr = boost::shared_ptr< LogKind >; + LogKindPtr getLogKind( uint32_t LogKindId ); + using LogKindCategoryTextPtr = boost::shared_ptr< LogKindCategoryText >; + LogKindCategoryTextPtr getLogKindCategoryText( uint32_t LogKindCategoryTextId ); + using LogMessagePtr = boost::shared_ptr< LogMessage >; + LogMessagePtr getLogMessage( uint32_t LogMessageId ); + using MacroIconPtr = boost::shared_ptr< MacroIcon >; + MacroIconPtr getMacroIcon( uint32_t MacroIconId ); + using MacroIconRedirectOldPtr = boost::shared_ptr< MacroIconRedirectOld >; + MacroIconRedirectOldPtr getMacroIconRedirectOld( uint32_t MacroIconRedirectOldId ); + using MainCommandPtr = boost::shared_ptr< MainCommand >; + MainCommandPtr getMainCommand( uint32_t MainCommandId ); + using MainCommandCategoryPtr = boost::shared_ptr< MainCommandCategory >; + MainCommandCategoryPtr getMainCommandCategory( uint32_t MainCommandCategoryId ); + using MapPtr = boost::shared_ptr< Map >; + MapPtr getMap( uint32_t MapId ); + using MapMarkerPtr = boost::shared_ptr< MapMarker >; + MapMarkerPtr getMapMarker( uint32_t MapMarkerId ); + using MapSymbolPtr = boost::shared_ptr< MapSymbol >; + MapSymbolPtr getMapSymbol( uint32_t MapSymbolId ); + using MasterpieceSupplyDutyPtr = boost::shared_ptr< MasterpieceSupplyDuty >; + MasterpieceSupplyDutyPtr getMasterpieceSupplyDuty( uint32_t MasterpieceSupplyDutyId ); + using MasterpieceSupplyMultiplierPtr = boost::shared_ptr< MasterpieceSupplyMultiplier >; + MasterpieceSupplyMultiplierPtr getMasterpieceSupplyMultiplier( uint32_t MasterpieceSupplyMultiplierId ); + using MateriaPtr = boost::shared_ptr< Materia >; + MateriaPtr getMateria( uint32_t MateriaId ); + using MinionRacePtr = boost::shared_ptr< MinionRace >; + MinionRacePtr getMinionRace( uint32_t MinionRaceId ); + using MinionRulesPtr = boost::shared_ptr< MinionRules >; + MinionRulesPtr getMinionRules( uint32_t MinionRulesId ); + using MinionSkillTypePtr = boost::shared_ptr< MinionSkillType >; + MinionSkillTypePtr getMinionSkillType( uint32_t MinionSkillTypeId ); + using MobHuntTargetPtr = boost::shared_ptr< MobHuntTarget >; + MobHuntTargetPtr getMobHuntTarget( uint32_t MobHuntTargetId ); + using ModelCharaPtr = boost::shared_ptr< ModelChara >; + ModelCharaPtr getModelChara( uint32_t ModelCharaId ); + using MonsterNotePtr = boost::shared_ptr< MonsterNote >; + MonsterNotePtr getMonsterNote( uint32_t MonsterNoteId ); + using MonsterNoteTargetPtr = boost::shared_ptr< MonsterNoteTarget >; + MonsterNoteTargetPtr getMonsterNoteTarget( uint32_t MonsterNoteTargetId ); + using MountPtr = boost::shared_ptr< Mount >; + MountPtr getMount( uint32_t MountId ); + using MountActionPtr = boost::shared_ptr< MountAction >; + MountActionPtr getMountAction( uint32_t MountActionId ); + using NpcEquipPtr = boost::shared_ptr< NpcEquip >; + NpcEquipPtr getNpcEquip( uint32_t NpcEquipId ); + using OmenPtr = boost::shared_ptr< Omen >; + OmenPtr getOmen( uint32_t OmenId ); + using OnlineStatusPtr = boost::shared_ptr< OnlineStatus >; + OnlineStatusPtr getOnlineStatus( uint32_t OnlineStatusId ); + using OpeningPtr = boost::shared_ptr< Opening >; + OpeningPtr getOpening( uint32_t OpeningId ); + using OrchestrionPtr = boost::shared_ptr< Orchestrion >; + OrchestrionPtr getOrchestrion( uint32_t OrchestrionId ); + using OrchestrionPathPtr = boost::shared_ptr< OrchestrionPath >; + OrchestrionPathPtr getOrchestrionPath( uint32_t OrchestrionPathId ); + using ParamGrowPtr = boost::shared_ptr< ParamGrow >; + ParamGrowPtr getParamGrow( uint32_t ParamGrowId ); + using PetPtr = boost::shared_ptr< Pet >; + PetPtr getPet( uint32_t PetId ); + using PetActionPtr = boost::shared_ptr< PetAction >; + PetActionPtr getPetAction( uint32_t PetActionId ); + using PicturePtr = boost::shared_ptr< Picture >; + PicturePtr getPicture( uint32_t PictureId ); + using PlaceNamePtr = boost::shared_ptr< PlaceName >; + PlaceNamePtr getPlaceName( uint32_t PlaceNameId ); + using QuestPtr = boost::shared_ptr< Quest >; + QuestPtr getQuest( uint32_t QuestId ); + using QuestRewardOtherPtr = boost::shared_ptr< QuestRewardOther >; + QuestRewardOtherPtr getQuestRewardOther( uint32_t QuestRewardOtherId ); + using RacePtr = boost::shared_ptr< Race >; + RacePtr getRace( uint32_t RaceId ); + using RacingChocoboItemPtr = boost::shared_ptr< RacingChocoboItem >; + RacingChocoboItemPtr getRacingChocoboItem( uint32_t RacingChocoboItemId ); + using RacingChocoboNamePtr = boost::shared_ptr< RacingChocoboName >; + RacingChocoboNamePtr getRacingChocoboName( uint32_t RacingChocoboNameId ); + using RacingChocoboNameCategoryPtr = boost::shared_ptr< RacingChocoboNameCategory >; + RacingChocoboNameCategoryPtr getRacingChocoboNameCategory( uint32_t RacingChocoboNameCategoryId ); + using RacingChocoboNameInfoPtr = boost::shared_ptr< RacingChocoboNameInfo >; + RacingChocoboNameInfoPtr getRacingChocoboNameInfo( uint32_t RacingChocoboNameInfoId ); + using RacingChocoboParamPtr = boost::shared_ptr< RacingChocoboParam >; + RacingChocoboParamPtr getRacingChocoboParam( uint32_t RacingChocoboParamId ); + using RecipePtr = boost::shared_ptr< Recipe >; + RecipePtr getRecipe( uint32_t RecipeId ); + using RecipeElementPtr = boost::shared_ptr< RecipeElement >; + RecipeElementPtr getRecipeElement( uint32_t RecipeElementId ); + using RecipeLevelTablePtr = boost::shared_ptr< RecipeLevelTable >; + RecipeLevelTablePtr getRecipeLevelTable( uint32_t RecipeLevelTableId ); + using RecipeNotebookListPtr = boost::shared_ptr< RecipeNotebookList >; + RecipeNotebookListPtr getRecipeNotebookList( uint32_t RecipeNotebookListId ); + using RelicPtr = boost::shared_ptr< Relic >; + RelicPtr getRelic( uint32_t RelicId ); + using Relic3Ptr = boost::shared_ptr< Relic3 >; + Relic3Ptr getRelic3( uint32_t Relic3Id ); + using RelicItemPtr = boost::shared_ptr< RelicItem >; + RelicItemPtr getRelicItem( uint32_t RelicItemId ); + using RelicNotePtr = boost::shared_ptr< RelicNote >; + RelicNotePtr getRelicNote( uint32_t RelicNoteId ); + using RelicNoteCategoryPtr = boost::shared_ptr< RelicNoteCategory >; + RelicNoteCategoryPtr getRelicNoteCategory( uint32_t RelicNoteCategoryId ); + using RetainerTaskPtr = boost::shared_ptr< RetainerTask >; + RetainerTaskPtr getRetainerTask( uint32_t RetainerTaskId ); + using RetainerTaskNormalPtr = boost::shared_ptr< RetainerTaskNormal >; + RetainerTaskNormalPtr getRetainerTaskNormal( uint32_t RetainerTaskNormalId ); + using RetainerTaskParameterPtr = boost::shared_ptr< RetainerTaskParameter >; + RetainerTaskParameterPtr getRetainerTaskParameter( uint32_t RetainerTaskParameterId ); + using RetainerTaskRandomPtr = boost::shared_ptr< RetainerTaskRandom >; + RetainerTaskRandomPtr getRetainerTaskRandom( uint32_t RetainerTaskRandomId ); + using SalvagePtr = boost::shared_ptr< Salvage >; + SalvagePtr getSalvage( uint32_t SalvageId ); + using SatisfactionNpcPtr = boost::shared_ptr< SatisfactionNpc >; + SatisfactionNpcPtr getSatisfactionNpc( uint32_t SatisfactionNpcId ); + using SatisfactionSupplyPtr = boost::shared_ptr< SatisfactionSupply >; + SatisfactionSupplyPtr getSatisfactionSupply( uint32_t SatisfactionSupplyId ); + using SatisfactionSupplyRewardPtr = boost::shared_ptr< SatisfactionSupplyReward >; + SatisfactionSupplyRewardPtr getSatisfactionSupplyReward( uint32_t SatisfactionSupplyRewardId ); + using ScreenImagePtr = boost::shared_ptr< ScreenImage >; + ScreenImagePtr getScreenImage( uint32_t ScreenImageId ); + using SecretRecipeBookPtr = boost::shared_ptr< SecretRecipeBook >; + SecretRecipeBookPtr getSecretRecipeBook( uint32_t SecretRecipeBookId ); + using SpearfishingItemPtr = boost::shared_ptr< SpearfishingItem >; + SpearfishingItemPtr getSpearfishingItem( uint32_t SpearfishingItemId ); + using SpearfishingNotebookPtr = boost::shared_ptr< SpearfishingNotebook >; + SpearfishingNotebookPtr getSpearfishingNotebook( uint32_t SpearfishingNotebookId ); + using SpecialShopPtr = boost::shared_ptr< SpecialShop >; + SpecialShopPtr getSpecialShop( uint32_t SpecialShopId ); + using SpecialShopItemCategoryPtr = boost::shared_ptr< SpecialShopItemCategory >; + SpecialShopItemCategoryPtr getSpecialShopItemCategory( uint32_t SpecialShopItemCategoryId ); + using StainPtr = boost::shared_ptr< Stain >; + StainPtr getStain( uint32_t StainId ); + using StatusPtr = boost::shared_ptr< Status >; + StatusPtr getStatus( uint32_t StatusId ); + using StoryPtr = boost::shared_ptr< Story >; + StoryPtr getStory( uint32_t StoryId ); + using SwitchTalkPtr = boost::shared_ptr< SwitchTalk >; + SwitchTalkPtr getSwitchTalk( uint32_t SwitchTalkId ); + using TerritoryTypePtr = boost::shared_ptr< TerritoryType >; + TerritoryTypePtr getTerritoryType( uint32_t TerritoryTypeId ); + using TextCommandPtr = boost::shared_ptr< TextCommand >; + TextCommandPtr getTextCommand( uint32_t TextCommandId ); + using TitlePtr = boost::shared_ptr< Title >; + TitlePtr getTitle( uint32_t TitleId ); + using TomestonesPtr = boost::shared_ptr< Tomestones >; + TomestonesPtr getTomestones( uint32_t TomestonesId ); + using TomestonesItemPtr = boost::shared_ptr< TomestonesItem >; + TomestonesItemPtr getTomestonesItem( uint32_t TomestonesItemId ); + using TopicSelectPtr = boost::shared_ptr< TopicSelect >; + TopicSelectPtr getTopicSelect( uint32_t TopicSelectId ); + using TownPtr = boost::shared_ptr< Town >; + TownPtr getTown( uint32_t TownId ); + using TraitPtr = boost::shared_ptr< Trait >; + TraitPtr getTrait( uint32_t TraitId ); + using TraitRecastPtr = boost::shared_ptr< TraitRecast >; + TraitRecastPtr getTraitRecast( uint32_t TraitRecastId ); + using TraitTransientPtr = boost::shared_ptr< TraitTransient >; + TraitTransientPtr getTraitTransient( uint32_t TraitTransientId ); + using TribePtr = boost::shared_ptr< Tribe >; + TribePtr getTribe( uint32_t TribeId ); + using TripleTriadPtr = boost::shared_ptr< TripleTriad >; + TripleTriadPtr getTripleTriad( uint32_t TripleTriadId ); + using TripleTriadCardPtr = boost::shared_ptr< TripleTriadCard >; + TripleTriadCardPtr getTripleTriadCard( uint32_t TripleTriadCardId ); + using TripleTriadCardRarityPtr = boost::shared_ptr< TripleTriadCardRarity >; + TripleTriadCardRarityPtr getTripleTriadCardRarity( uint32_t TripleTriadCardRarityId ); + using TripleTriadCardResidentPtr = boost::shared_ptr< TripleTriadCardResident >; + TripleTriadCardResidentPtr getTripleTriadCardResident( uint32_t TripleTriadCardResidentId ); + using TripleTriadCardTypePtr = boost::shared_ptr< TripleTriadCardType >; + TripleTriadCardTypePtr getTripleTriadCardType( uint32_t TripleTriadCardTypeId ); + using TripleTriadCompetitionPtr = boost::shared_ptr< TripleTriadCompetition >; + TripleTriadCompetitionPtr getTripleTriadCompetition( uint32_t TripleTriadCompetitionId ); + using TripleTriadRulePtr = boost::shared_ptr< TripleTriadRule >; + TripleTriadRulePtr getTripleTriadRule( uint32_t TripleTriadRuleId ); + using TutorialPtr = boost::shared_ptr< Tutorial >; + TutorialPtr getTutorial( uint32_t TutorialId ); + using TutorialDPSPtr = boost::shared_ptr< TutorialDPS >; + TutorialDPSPtr getTutorialDPS( uint32_t TutorialDPSId ); + using TutorialHealerPtr = boost::shared_ptr< TutorialHealer >; + TutorialHealerPtr getTutorialHealer( uint32_t TutorialHealerId ); + using TutorialTankPtr = boost::shared_ptr< TutorialTank >; + TutorialTankPtr getTutorialTank( uint32_t TutorialTankId ); + using WarpPtr = boost::shared_ptr< Warp >; + WarpPtr getWarp( uint32_t WarpId ); + using WeatherPtr = boost::shared_ptr< Weather >; + WeatherPtr getWeather( uint32_t WeatherId ); + using WeatherGroupPtr = boost::shared_ptr< WeatherGroup >; + WeatherGroupPtr getWeatherGroup( uint32_t WeatherGroupId ); + using WeatherRatePtr = boost::shared_ptr< WeatherRate >; + WeatherRatePtr getWeatherRate( uint32_t WeatherRateId ); + using WeeklyBingoOrderDataPtr = boost::shared_ptr< WeeklyBingoOrderData >; + WeeklyBingoOrderDataPtr getWeeklyBingoOrderData( uint32_t WeeklyBingoOrderDataId ); + using WeeklyBingoRewardDataPtr = boost::shared_ptr< WeeklyBingoRewardData >; + WeeklyBingoRewardDataPtr getWeeklyBingoRewardData( uint32_t WeeklyBingoRewardDataId ); + using WeeklyBingoTextPtr = boost::shared_ptr< WeeklyBingoText >; + WeeklyBingoTextPtr getWeeklyBingoText( uint32_t WeeklyBingoTextId ); + using WorldDCGroupTypePtr = boost::shared_ptr< WorldDCGroupType >; + WorldDCGroupTypePtr getWorldDCGroupType( uint32_t WorldDCGroupTypeId ); std::set< uint32_t > m_AchievementIdList; @@ -3950,7 +4348,6 @@ struct WorldDCGroupType std::set< uint32_t > m_CabinetIdList; std::set< uint32_t > m_CabinetCategoryIdList; std::set< uint32_t > m_CalendarIdList; - std::set< uint32_t > m_ChainBonusIdList; std::set< uint32_t > m_CharaMakeCustomizeIdList; std::set< uint32_t > m_CharaMakeTypeIdList; std::set< uint32_t > m_ChocoboRaceIdList; @@ -4020,11 +4417,13 @@ struct WorldDCGroupType std::set< uint32_t > m_ExVersionIdList; std::set< uint32_t > m_FateIdList; std::set< uint32_t > m_FCActivityIdList; + std::set< uint32_t > m_FCActivityCategoryIdList; std::set< uint32_t > m_FCAuthorityIdList; std::set< uint32_t > m_FCAuthorityCategoryIdList; std::set< uint32_t > m_FCChestNameIdList; std::set< uint32_t > m_FccShopIdList; std::set< uint32_t > m_FCHierarchyIdList; + std::set< uint32_t > m_FCProfileIdList; std::set< uint32_t > m_FCReputationIdList; std::set< uint32_t > m_FCRightsIdList; std::set< uint32_t > m_FishingSpotIdList; @@ -4048,6 +4447,12 @@ struct WorldDCGroupType std::set< uint32_t > m_GcArmyExpeditionTypeIdList; std::set< uint32_t > m_GcArmyMemberGrowIdList; std::set< uint32_t > m_GcArmyTrainingIdList; + std::set< uint32_t > m_GCRankGridaniaFemaleTextIdList; + std::set< uint32_t > m_GCRankGridaniaMaleTextIdList; + std::set< uint32_t > m_GCRankLimsaFemaleTextIdList; + std::set< uint32_t > m_GCRankLimsaMaleTextIdList; + std::set< uint32_t > m_GCRankUldahFemaleTextIdList; + std::set< uint32_t > m_GCRankUldahMaleTextIdList; std::set< uint32_t > m_GCScripShopCategoryIdList; std::set< uint32_t > m_GCScripShopItemIdList; std::set< uint32_t > m_GCShopIdList; @@ -4114,6 +4519,7 @@ struct WorldDCGroupType std::set< uint32_t > m_NpcEquipIdList; std::set< uint32_t > m_OmenIdList; std::set< uint32_t > m_OnlineStatusIdList; + std::set< uint32_t > m_OpeningIdList; std::set< uint32_t > m_OrchestrionIdList; std::set< uint32_t > m_OrchestrionPathIdList; std::set< uint32_t > m_ParamGrowIdList; @@ -4512,12 +4918,6 @@ const std::set< uint32_t >& getCalendarIdList() loadIdList( m_CalendarDat, m_CalendarIdList ); return m_CalendarIdList; } -const std::set< uint32_t >& getChainBonusIdList() -{ - if( m_ChainBonusIdList.size() == 0 ) - loadIdList( m_ChainBonusDat, m_ChainBonusIdList ); - return m_ChainBonusIdList; -} const std::set< uint32_t >& getCharaMakeCustomizeIdList() { if( m_CharaMakeCustomizeIdList.size() == 0 ) @@ -4932,6 +5332,12 @@ const std::set< uint32_t >& getFCActivityIdList() loadIdList( m_FCActivityDat, m_FCActivityIdList ); return m_FCActivityIdList; } +const std::set< uint32_t >& getFCActivityCategoryIdList() +{ + if( m_FCActivityCategoryIdList.size() == 0 ) + loadIdList( m_FCActivityCategoryDat, m_FCActivityCategoryIdList ); + return m_FCActivityCategoryIdList; +} const std::set< uint32_t >& getFCAuthorityIdList() { if( m_FCAuthorityIdList.size() == 0 ) @@ -4962,6 +5368,12 @@ const std::set< uint32_t >& getFCHierarchyIdList() loadIdList( m_FCHierarchyDat, m_FCHierarchyIdList ); return m_FCHierarchyIdList; } +const std::set< uint32_t >& getFCProfileIdList() +{ + if( m_FCProfileIdList.size() == 0 ) + loadIdList( m_FCProfileDat, m_FCProfileIdList ); + return m_FCProfileIdList; +} const std::set< uint32_t >& getFCReputationIdList() { if( m_FCReputationIdList.size() == 0 ) @@ -5100,6 +5512,42 @@ const std::set< uint32_t >& getGcArmyTrainingIdList() loadIdList( m_GcArmyTrainingDat, m_GcArmyTrainingIdList ); return m_GcArmyTrainingIdList; } +const std::set< uint32_t >& getGCRankGridaniaFemaleTextIdList() +{ + if( m_GCRankGridaniaFemaleTextIdList.size() == 0 ) + loadIdList( m_GCRankGridaniaFemaleTextDat, m_GCRankGridaniaFemaleTextIdList ); + return m_GCRankGridaniaFemaleTextIdList; +} +const std::set< uint32_t >& getGCRankGridaniaMaleTextIdList() +{ + if( m_GCRankGridaniaMaleTextIdList.size() == 0 ) + loadIdList( m_GCRankGridaniaMaleTextDat, m_GCRankGridaniaMaleTextIdList ); + return m_GCRankGridaniaMaleTextIdList; +} +const std::set< uint32_t >& getGCRankLimsaFemaleTextIdList() +{ + if( m_GCRankLimsaFemaleTextIdList.size() == 0 ) + loadIdList( m_GCRankLimsaFemaleTextDat, m_GCRankLimsaFemaleTextIdList ); + return m_GCRankLimsaFemaleTextIdList; +} +const std::set< uint32_t >& getGCRankLimsaMaleTextIdList() +{ + if( m_GCRankLimsaMaleTextIdList.size() == 0 ) + loadIdList( m_GCRankLimsaMaleTextDat, m_GCRankLimsaMaleTextIdList ); + return m_GCRankLimsaMaleTextIdList; +} +const std::set< uint32_t >& getGCRankUldahFemaleTextIdList() +{ + if( m_GCRankUldahFemaleTextIdList.size() == 0 ) + loadIdList( m_GCRankUldahFemaleTextDat, m_GCRankUldahFemaleTextIdList ); + return m_GCRankUldahFemaleTextIdList; +} +const std::set< uint32_t >& getGCRankUldahMaleTextIdList() +{ + if( m_GCRankUldahMaleTextIdList.size() == 0 ) + loadIdList( m_GCRankUldahMaleTextDat, m_GCRankUldahMaleTextIdList ); + return m_GCRankUldahMaleTextIdList; +} const std::set< uint32_t >& getGCScripShopCategoryIdList() { if( m_GCScripShopCategoryIdList.size() == 0 ) @@ -5496,6 +5944,12 @@ const std::set< uint32_t >& getOnlineStatusIdList() loadIdList( m_OnlineStatusDat, m_OnlineStatusIdList ); return m_OnlineStatusIdList; } +const std::set< uint32_t >& getOpeningIdList() +{ + if( m_OpeningIdList.size() == 0 ) + loadIdList( m_OpeningDat, m_OpeningIdList ); + return m_OpeningIdList; +} const std::set< uint32_t >& getOrchestrionIdList() { if( m_OrchestrionIdList.size() == 0 ) diff --git a/src/common/Network/PacketDef/Ipcs.h b/src/common/Network/PacketDef/Ipcs.h index 5f75e546..c505904a 100644 --- a/src/common/Network/PacketDef/Ipcs.h +++ b/src/common/Network/PacketDef/Ipcs.h @@ -44,9 +44,23 @@ namespace Packets { */ enum ServerZoneIpcType : uint16_t { + + // static opcode ( the ones that rarely if ever change ) Ping = 0x0065, Init = 0x0066, - Chat = 0x00B9, + + ActorSpawn = 0x0190, // DEPRECATED + ActorFreeSpawn = 0x0191, + InitZone = 0x019A, + + AddStatusEffect = 0x0141, + ActorControl142 = 0x0142, + ActorControl143 = 0x0143, + ActorControl144 = 0x0144, + UpdateHpMpTp = 0x0145, + + /////////////////////////////////////////////////// + ChatBanned = 0x006B, Logout = 0x0077, CFNotify = 0x0078, @@ -54,92 +68,100 @@ namespace Packets { CFDutyInfo = 0x007A, CFPlayerInNeed = 0x007F, - SocialRequestError = 0x00AD, - Playtime = 0x00B7, // updated 4.1 + + Playtime = 0x00DF, // updated 4.2 CFRegistered = 0x00B8, // updated 4.1 - SocialRequestResponse = 0x00BC, // updated 4.1 - SocialRequestReceive = 0x00BD, - SocialList = 0x00BE, // updated 4.1 - UpdateSearchInfo = 0x10BB, - InitSearchInfo = 0x00C1, // updated 4.1 - ServerNotice = 0x00C6, // updated 4.1 - SetOnlineStatus = 0x00C7, // updated 4.1 + SocialRequestResponse = 0x00BB, // updated 4.1 + Chat = 0x00E1, // updated 4.2 + SocialList = 0x00E7, // updated 4.2 + + UpdateSearchInfo = 0x00EA, // updated 4.2 + InitSearchInfo = 0x00EB, // updated 4.2 + + ServerNotice = 0x00F0, // updated 4.2 + SetOnlineStatus = 0x00F1, // updated 4.2 + + CountdownInitiate = 0x00FB, // updated 4.2 + CountdownCancel = 0x00FC, // updated 4.2 + + BlackList = 0x00FF, // updated 4.2 LogMessage = 0x00D0, - BlackList = 0x00D4, // updated 4.1 - LinkshellList = 0x00DC, // updated 4.1 - StatusEffectList = 0x00FA, // updated 4.1 - Effect = 0x00FB, // updated 4.1 - GCAffiliation = 0x00FC, + LinkshellList = 0x0106, // updated 4.2 + SetCharacterFCInfo = 0x0114, // updated 4.2 + StatusEffectList = 0x0125, // updated 4.2 + Effect = 0x0128, // updated 4.2 - PlayerSpawn = 0x011C, // updated 4.1 - NpcSpawn = 0x011D, // updated 4.1 - ActorMove = 0x011E, // updated 4.1 - ActorSetPos = 0x0120, // updated 4.1 - ActorCast = 0x0123, // updated 4.1 - HateList = 0x0126, // updated 4.1 - UpdateClassInfo = 0x012A, // updated 4.1 - InitUI = 0x012B, // updated 4.1 - ActorOwner = 0x012D, // updated 4.1 - PlayerStats = 0x0138, // updated 4.1 - PlayerStateFlags = 0x013A, // updated 4.1 - PlayerClassInfo = 0x013B, // updated 4.1 - ModelEquip = 0x013C, // updated 4.1 + GCAffiliation = 0xCCFC, // OUTDATED - AddStatusEffect = 0x0141, - ActorControl142 = 0x0142, // updated 4.1 - ActorControl143 = 0x0143, // updated 4.1 - ActorControl144 = 0x0144, // updated 4.1 - UpdateHpMpTp = 0x0145, // updated 4.1 + PlayerSpawn = 0x015C, // updated 4.2 + NpcSpawn = 0x015D, // updated 4.2 + ActorMove = 0x015E, // updated 4.2 + ActorSetPos = 0x0160, // updated 4.2 + ActorCast = 0x0162, // updated 4.2 + HateList = 0x0165, // updated 4.2 + UpdateClassInfo = 0x0169, // updated 4.2 + InitUI = 0x016B, // updated 4.2 - ItemInfo = 0x014C, // updated 4.1 - ContainerInfo = 0x014D, // updated 4.1 - InventoryTransactionFinish = 0x014E, // updated 4.1 - InventoryTransaction = 0x014F, // updated 4.1 - CurrencyCrystalInfo = 0x0150, // updated 4.1 - InventoryActionAck = 0x1139, - UpdateInventorySlot = 0x0153, // updated 4.1 + ActorOwner = 0x016D, // updated 4.2 ? - EventPlay = 0x0160, // updated 4.1 - EventStart = 0x0169, // updated 4.1 - EventFinish = 0x016A, // updated 4.1 + PlayerStats = 0x016C, // updated 4.2 + PlayerStateFlags = 0x016E, // updated 4.2 + PlayerClassInfo = 0x016F, // updated 4.2 + ModelEquip = 0x0170, // updated 4.2 + + ItemInfo = 0x017A, // updated 4.2 + ContainerInfo = 0x017B, // updated 4.2 + InventoryTransactionFinish = 0x017C, // updated 4.2 + InventoryTransaction = 0x017D, // updated 4.2 + CurrencyCrystalInfo = 0x017E, // updated 4.2 + + InventoryActionAck = 0x0180, // updated 4.2 ? + UpdateInventorySlot = 0x0181, // updated 4.2 + + EventPlay = 0x018E, // updated 4.2 + + EventStart = 0x0198, // updated 4.2 + EventFinish = 0x0199, // updated 4.2 EventLinkshell = 0x1169, - QuestMessage = 0x0188, // updated 4.1 - QuestActiveList = 0x017D, // updated 4.1 - QuestUpdate = 0x017E, // updated 4.1 - QuestCompleteList = 0x017F, // updated 4.1 + QuestMessage = 0x01B8, // updated 4.2 + QuestTracker = 0x01BD, // updated 4.2 - QuestFinish = 0x0180, // updated 4.1 + QuestFinish = 0x01B0, // updated 4.2 + MSQTrackerComplete = 0x01B1, // updated 4.2 + MSQTrackerProgress = 0x01B2, // updated 4.2 - QuestTracker = 0x018D, // updated 4.1 - ActorSpawn = 0x0190, // todo: split into playerspawn/actorspawn and use opcode 0x110/0x111 - ActorFreeSpawn = 0x0191, // unchanged for sb - InitZone = 0x019A, // unchanged for sb - Mount = 0x019F, - WeatherChange = 0x01AF, // updated for sb - PlayerTitleList = 0x01BD, // updated for 4.1 - Discovery = 0x01BE, // updated for 4.1 + QuestActiveList = 0x01AD, // updated 4.2 - EorzeaTimeOffset = 0x01C0, // updated 4.1 + QuestUpdate = 0x01AE, // updated 4.2 + QuestCompleteList = 0x01AF, // updated 4.2 - EquipDisplayFlags = 0x01CC, // updated 4.1 + Mount = 0x01CD, // updated 4.2 + + WeatherChange = 0x01EA, // updated 4.2 + PlayerTitleList = 0x01EB, // updated 4.2 + Discovery = 0x01EC, // updated 4.2 + + EorzeaTimeOffset = 0x01EE, // updated 4.2 + + EquipDisplayFlags = 0x01FA, // updated 4.2 CFAvailableContents = 0x01CF, - PrepareZoning = 0x0248, // updated 4.1 + PrepareZoning = 0x027C, // updated 4.2 + ActorGauge = 0x027D, // updated 4.2 + + PerformNote = 0x0286, // updated 4.2 // Unknown IPC types that still need to be sent // TODO: figure all these out properly - IPCTYPE_UNK_320 = 0x0207, // updated 4.1 - IPCTYPE_UNK_322 = 0x0209, // updated 4.1 + IPCTYPE_UNK_320 = 0x0235, // updated 4.2 + IPCTYPE_UNK_322 = 0x0237, // updated 4.2 - ActorGauge = 0x0249, - - PerformNote = 0x0252, }; // TODO: Include structures for the individual packet segment types @@ -150,59 +172,69 @@ namespace Packets { enum ClientZoneIpcType : uint16_t { - PingHandler = 0x0065, // updated for sb - InitHandler = 0x0066, // updated 4.1 - ChatHandler = 0x00AD, // updated 4.1 + PingHandler = 0x0065, // unchanged 4.2 + InitHandler = 0x0066, // unchanged 4.2 - FinishLoadingHandler = 0x0069, // updated 4.1 + FinishLoadingHandler = 0x0069, // unchanged 4.2 CFCommenceHandler = 0x006F, + + + CFRegisterDuty = 0x0071, CFRegisterRoulette = 0x0072, - PlayTimeHandler = 0x0073, // updated 4.1 - LogoutHandler = 0x0074, // updated 4.1 + PlayTimeHandler = 0x0073, // unchanged 4.2 + LogoutHandler = 0x0074, // unchanged 4.2 - CFDutyInfoHandler = 0x0078, // updated 4.1 ?? + CFDutyInfoHandler = 0x0078, // updated 4.2 - SocialReqSendHandler = 0x00AF, // updated 4.1 - SocialListHandler = 0x00B3, // updated 4.1 - SetSearchInfoHandler = 0x00B5, // updated 4.1 + SocialReqSendHandler = 0x00AE, // updated 4.1 - ReqSearchInfoHandler = 0x00B6, // updated 4.1 + ChatHandler = 0x00C7, // updated 4.2 - BlackListHandler = 0x00C0, // updated 4.1 + SocialListHandler = 0x00CF, // updated 4.2 + ReqSearchInfoHandler = 0x00D4, // updated 4.2 + SetSearchInfoHandler = 0x00D2, // updated 4.2 - LinkshellListHandler = 0x00C8, // updated 4.1 + BlackListHandler = 0x00E0, // updated 4.2 - FcInfoReqHandler = 0x0109, // updated 4.1 + LinkshellListHandler = 0x00E8, // updated 4.2 - ZoneLineHandler = 0x0110, // updated 4.1 - ActionHandler = 0x0111, // updated 4.1 - DiscoveryHandler = 0x0112, // updated 4.1 + FcInfoReqHandler = 0x011A, // updated 4.2 - SkillHandler = 0x0114, // updated 4.1 - GMCommand1 = 0x0115, // updated 4.1 ?? - GMCommand2 = 0x0116, // updated 4.1 ?? - UpdatePositionHandler = 0x0118, // updated 4.1 + ReqCountdownInitiate = 0x012C, // updated 4.2 + ReqCountdownCancel = 0x012D, // updated 4.2 - InventoryModifyHandler = 0x011F, // updated 4.1 + ZoneLineHandler = 0x0130, // updated 4.2 + ActionHandler = 0x0131, // updated 4.2 + DiscoveryHandler = 0x0132, // updated 4.2 - TalkEventHandler = 0x0128, // updated 4.1 - EmoteEventHandler = 0x0129, // updated 4.1 - WithinRangeEventHandler = 0x012A, // updated 4.1 - OutOfRangeEventHandler = 0x012B, // updated 4.1 - EnterTeriEventHandler = 0x012C, // updated 4.1 + SkillHandler = 0x0134, // updated 4.2 + GMCommand1 = 0x0135, // updated 4.2 + GMCommand2 = 0x0136, // updated 4.2 + UpdatePositionHandler = 0x0138, // updated 4.2 + UpdatePositionInstance = 0x0177, // updated 4.2 - ReturnEventHandler = 0x0131, // updated 4.1 - TradeReturnEventHandler = 0x0132, // updated 4.1 + InventoryModifyHandler = 0x013F, // updated 4.2 + + TalkEventHandler = 0x0148, // updated 4.2 + EmoteEventHandler = 0x0149, // updated 4.2 + WithinRangeEventHandler = 0x014A, // updated 4.2 + OutOfRangeEventHandler = 0x014B, // updated 4.2 + EnterTeriEventHandler = 0x014C, // updated 4.2 + + ReturnEventHandler = 0x0151, // updated 4.2 ? + TradeReturnEventHandler = 0x0152, // updated 4.2 ? LinkshellEventHandler = 0x0144, // updated 4.1 ?? LinkshellEventHandler1 = 0x0145, // updated 4.1 ?? - ReqEquipDisplayFlagsChange = 0x014C, // updated 4.1 ?? - PerformNoteHandler = 0x0160, + + ReqEquipDisplayFlagsChange = 0x016C, // updated 4.2 + + }; //////////////////////////////////////////////////////////////////////////////// diff --git a/src/common/Network/PacketDef/Zone/ServerZoneDef.h b/src/common/Network/PacketDef/Zone/ServerZoneDef.h index 31486f74..7a3ebeb9 100644 --- a/src/common/Network/PacketDef/Zone/ServerZoneDef.h +++ b/src/common/Network/PacketDef/Zone/ServerZoneDef.h @@ -388,10 +388,10 @@ struct FFXIVIpcPlayerSpawn : FFXIVIpcBasePacket uint8_t u2b; uint8_t u2ab; uint8_t gmRank; - uint8_t onlineStatus; + uint8_t u3b; uint8_t u3a; - uint8_t u3b; + uint8_t onlineStatus; uint8_t u3c; uint8_t pose; @@ -410,7 +410,7 @@ struct FFXIVIpcPlayerSpawn : FFXIVIpcBasePacket uint32_t bNPCName; uint32_t u18; uint32_t u19; - uint32_t u20; + uint32_t directorId; uint32_t ownerId; uint32_t u22; uint32_t hPMax; @@ -443,6 +443,7 @@ struct FFXIVIpcPlayerSpawn : FFXIVIpcBasePacket uint8_t mountColor; uint8_t scale; uint32_t u29b; + uint32_t u30b; Common::StatusEffect effect[30]; Common::FFXIVARR_POSITION3 pos; uint32_t models[10]; @@ -644,7 +645,7 @@ struct FFXIVIpcInitZone : FFXIVIpcBasePacket uint8_t weatherId; uint8_t bitmask; uint16_t unknown5; - uint16_t unknown6; + uint16_t festivalId; uint16_t unknown7; uint32_t unknown8; Common::FFXIVARR_POSITION3 pos; @@ -665,6 +666,7 @@ struct FFXIVIpcInitUI : FFXIVIpcBasePacket uint16_t unknown18; uint8_t maxLevel; uint8_t expansion; + uint8_t unknown1A; uint8_t race; uint8_t tribe; uint8_t gender; @@ -680,24 +682,23 @@ struct FFXIVIpcInitUI : FFXIVIpcBasePacket uint8_t companionRank; uint8_t companionStars; uint8_t companionSp; - uint8_t companionUnk1; + uint8_t companionUnk2B; uint8_t companionColor; uint8_t companionFavoFeed; - uint16_t companionUnk2; + uint8_t companionUnk2E; float companionTimePassed; uint32_t companionCurrentExp; uint32_t unknown38; uint32_t unknown3C; uint32_t fishCaught; uint32_t useBaitCatalogId; - uint16_t pvpWolfFoldMatches; - uint16_t pvpWolfFoldVictories; + uint32_t pvpWolfFoldMatches; uint16_t pvpWolfFoldWeeklyMatches; uint16_t pvpWolfFoldWeeklyVictories; uint16_t pvpStats[6]; uint16_t playerCommendations; uint16_t pvpStats1; - uint32_t frontlineCampaigns; + uint8_t frontlineCampaigns[4]; uint16_t frontlineCampaignsWeekly; uint8_t currentRelic; uint8_t currentBook; @@ -705,7 +706,7 @@ struct FFXIVIpcInitUI : FFXIVIpcBasePacket uint8_t unknown69; uint8_t unknown6A; uint8_t unknown6B; - uint32_t unknown6C; + uint8_t unknown6C[4]; uint8_t unknown70[61]; uint8_t preNamePadding; char name[32]; @@ -716,30 +717,31 @@ struct FFXIVIpcInitUI : FFXIVIpcBasePacket uint32_t exp[25]; uint8_t unlockBitmask[64]; uint8_t aetheryte[16]; - uint8_t discovery[420]; + uint8_t discovery[421]; uint8_t howto[33]; - uint8_t minions[35]; + uint8_t minions[37]; uint8_t chocoboTaxiMask[8]; - uint8_t contentClearMask[105]; + uint8_t contentClearMask[108]; uint8_t contentClearPadding; - uint16_t unknown422[8]; + uint16_t unknown428[8]; uint8_t companionBardingMask[8]; uint8_t companionEquippedHead; uint8_t companionEquippedBody; uint8_t companionEquippedFeet; - uint8_t companion_fields[15]; + uint8_t companionUnk4[4]; + uint8_t companion_fields[11]; uint8_t companion_name[21]; uint8_t companionDefRank; uint8_t companionAttRank; uint8_t companionHealRank; - uint8_t mountGuideMask[14]; + uint8_t mountGuideMask[15]; uint8_t fishingGuideMask[89]; uint8_t fishingSpotVisited[25]; uint16_t fishingRecordsFish[26]; uint16_t fishingRecordsFishWeight[26]; - uint8_t unknownMask4[15]; + uint8_t unknownMask554[15]; uint8_t unknownMask4Padding; - uint8_t unknown55C[19]; + uint8_t unknown564[19]; uint8_t rankAmalJaa; uint8_t rankSylph; uint8_t rankKobold; @@ -749,6 +751,7 @@ struct FFXIVIpcInitUI : FFXIVIpcBasePacket uint8_t rankVath; uint8_t rankMoogle; uint8_t rankKojin; + uint8_t rankAnata; uint16_t expAmalJaa; uint16_t expSylph; uint16_t expKobold; @@ -758,13 +761,14 @@ struct FFXIVIpcInitUI : FFXIVIpcBasePacket uint16_t expVath; uint16_t expMoogle; uint16_t expKojin; - uint8_t unknown58A[10]; - uint16_t unknown594[5]; + uint16_t expAnata; + uint8_t unknown596[10]; + uint16_t unknown5A0[5]; uint8_t unknownMask59E[5]; - uint8_t unknown5A3[16]; - uint8_t unknownMask5B3[28]; + uint8_t unknown5A3[18]; + uint8_t unknownMask5C1[28]; uint8_t unknown_03411; - uint32_t unknownDword5D0; + uint32_t unknownDword5E0; uint8_t relicBookCompletion[12]; uint8_t sightseeingMask[26]; uint16_t unknown_XXX; @@ -774,25 +778,25 @@ struct FFXIVIpcInitUI : FFXIVIpcBasePacket uint16_t pvpFrontlineWeekly1st; uint16_t pvpFrontlineWeekly2nd; uint16_t pvpFrontlineWeekly3rd; - uint8_t unknown60E; - uint8_t unknown60F[32]; - uint8_t unknown62F[22]; - uint8_t tripleTriadCards[27]; - uint8_t unknown660[11]; - uint8_t unknownMask66B[22]; - uint8_t unknown681[3]; + uint8_t unknown61E; + uint8_t unknown61F[32]; + uint8_t unknown63F[22]; + uint8_t tripleTriadCards[28]; + uint8_t unknown671[11]; + uint8_t unknownMask67C[22]; + uint8_t unknown692[3]; uint8_t orchestrionMask[40]; uint8_t hallOfNoviceCompleteMask[3]; - uint8_t unknownMask6AF[11]; - uint8_t unknownMask6BA[16]; - uint8_t unknown6CA[13]; + uint8_t unknownMask6C0[11]; + uint8_t unknownMask6CB[16]; + uint8_t unknown6DB[14]; uint8_t unlockedRaids[28]; uint8_t unlockedDungeons[18]; uint8_t unlockedGuildhests[10]; uint8_t unlockedTrails[7]; uint8_t unlockedPvp[5]; - uint8_t unknownMask71B[28]; - uint8_t unknownMask737[18]; + uint8_t unknownMask72D[28]; + uint8_t unknownMask749[18]; uint8_t unknown749[23]; }; @@ -870,11 +874,10 @@ struct FFXIVIpcActorOwner : FFXIVIpcBasePacket */ struct FFXIVIpcPlayerStateFlags : FFXIVIpcBasePacket { - /* 0000 */ uint16_t padding; - /* 0002 */ uint8_t flags[7]; - /* 0009 */ uint8_t padding1[3]; - /* 000C */ uint32_t padding2; - + uint8_t flags[7]; + uint8_t padding1[3]; + uint32_t padding2; + uint16_t padding; }; /** @@ -1127,7 +1130,8 @@ struct FFXIVIpcQuestUpdate : FFXIVIpcBasePacket */ struct FFXIVIpcQuestCompleteList : FFXIVIpcBasePacket { - /* 0000 */ uint8_t questCompleteMask[200]; + uint8_t questCompleteMask[396]; + uint8_t unknownCompleteMask[32]; }; /** @@ -1200,7 +1204,7 @@ struct FFXIVARR_IPC_UNK322 : FFXIVIpcBasePacket */ struct FFXIVARR_IPC_UNK320 : FFXIVIpcBasePacket { - /* 0000 */ uint8_t unk[32]; + /* 0000 */ uint8_t unk[0x38]; }; /** @@ -1317,7 +1321,6 @@ struct FFXIVIpcMount : FFXIVIpcBasePacket uint32_t id; }; - struct FFXIVIpcActorGauge : FFXIVIpcBasePacket { uint8_t classJobId; @@ -1329,6 +1332,21 @@ struct FFXIVIpcPerformNote : FFXIVIpcBasePacket uint8_t data[32]; }; +struct FFXIVIpcMSQTrackerProgress : FFXIVIpcBasePacket +{ + uint32_t id; + uint32_t padding; +}; + +struct FFXIVIpcMSQTrackerComplete : FFXIVIpcBasePacket +{ + uint32_t id; + uint32_t padding1; + uint64_t padding2; + uint64_t padding3; + uint64_t padding4; // last 4 bytes is uint32_t but who cares +}; + } /* Server */ } /* Packets */ diff --git a/src/common/Util/Util.cpp b/src/common/Util/Util.cpp index b92d61a9..48c565ae 100644 --- a/src/common/Util/Util.cpp +++ b/src/common/Util/Util.cpp @@ -62,7 +62,7 @@ std::string Core::Util::binaryToHexDump( uint8_t* pBinData, uint16_t size ) uint8_t by = pBinData[i + j]; line[hexColumn] = hexChars[( by >> 4 ) & 0xF]; line[hexColumn + 1] = hexChars[by & 0xF]; - line[charColumn] = by < 32 ? '.' : static_cast( by ); + line[charColumn] = by < 32 ? '.' : static_cast< char >( by ); } hexColumn += 3; @@ -78,13 +78,14 @@ std::string Core::Util::binaryToHexDump( uint8_t* pBinData, uint16_t size ) uint64_t Core::Util::getTimeMs() { - std::chrono::milliseconds epoch = std::chrono::duration_cast< std::chrono::milliseconds >(std::chrono::system_clock::now().time_since_epoch()); + std::chrono::milliseconds epoch = std::chrono::duration_cast< std::chrono::milliseconds > + ( std::chrono::system_clock::now().time_since_epoch() ); return epoch.count(); } -uint64_t Core::Util::getTimeSeconds() +int64_t Core::Util::getTimeSeconds() { - std::chrono::seconds epoch = std::chrono::duration_cast< std::chrono::seconds >(std::chrono::system_clock::now().time_since_epoch()); + std::chrono::seconds epoch = std::chrono::seconds( std::time( nullptr ) ); return epoch.count(); } diff --git a/src/common/Util/Util.h b/src/common/Util/Util.h index 2c38f55f..b03dd987 100644 --- a/src/common/Util/Util.h +++ b/src/common/Util/Util.h @@ -13,7 +13,7 @@ std::string binaryToHexDump( uint8_t* pBinData, uint16_t size ); uint64_t getTimeMs(); -uint64_t getTimeSeconds(); +int64_t getTimeSeconds(); uint64_t getEorzeanTimeStamp(); diff --git a/src/libraries b/src/libraries deleted file mode 160000 index 8a26ae78..00000000 --- a/src/libraries +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 8a26ae78e37701a9b66e7200f1e0ad3387da17c3 diff --git a/src/servers/sapphire_api/Forwards.h b/src/servers/sapphire_api/Forwards.h index 56d3b92d..bdffff9f 100644 --- a/src/servers/sapphire_api/Forwards.h +++ b/src/servers/sapphire_api/Forwards.h @@ -45,9 +45,9 @@ namespace Core namespace Event { - class Event; + class EventHandler; - typedef boost::shared_ptr EventPtr; + typedef boost::shared_ptr EventPtr; } namespace Action diff --git a/src/servers/sapphire_api/PlayerMinimal.cpp b/src/servers/sapphire_api/PlayerMinimal.cpp index 3cf47acb..6033b0b5 100644 --- a/src/servers/sapphire_api/PlayerMinimal.cpp +++ b/src/servers/sapphire_api/PlayerMinimal.cpp @@ -2,11 +2,11 @@ #include #include -#include +#include #include -extern Core::Data::ExdData g_exdData; +extern Core::Data::ExdDataGenerated g_exdDataGen; namespace Core { @@ -151,7 +151,7 @@ namespace Core { std::vector< uint8_t > howTo( 32 ); std::vector< uint8_t > aetherytes( 12 ); std::vector< uint8_t > discovery( 411 ); - std::vector< uint8_t > questComplete( 200 ); + std::vector< uint8_t > questComplete( 396 ); std::vector< uint8_t > unlocks( 64 ); std::vector< uint8_t > mountGuide( 13 ); std::vector< uint8_t > orchestrion( 38 ); @@ -220,7 +220,7 @@ namespace Core { // CharacterId, ClassIdx, Exp, Lvl auto stmtClass = g_charaDb.getPreparedStatement( Db::CharaDbStatements::CHARA_CLASS_INS ); stmtClass->setInt( 1, m_id ); - stmtClass->setInt( 2, g_exdData.m_classJobInfoMap[m_class].exp_idx ); + stmtClass->setInt( 2, g_exdDataGen.getClassJob( m_class )->expArrayIndex ); stmtClass->setInt( 3, 0 ); stmtClass->setInt( 4, 1 ); g_charaDb.directExecute( stmtClass ); @@ -292,14 +292,14 @@ namespace Core { /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /// SETUP EQUIPMENT / STARTING GEAR - auto classJobInfo = g_exdData.m_classJobInfoMap[m_class]; - uint32_t weaponId = classJobInfo.start_weapon_id; + auto classJobInfo = g_exdDataGen.getClassJob( m_class ); + uint32_t weaponId = classJobInfo->itemStartingWeapon; uint64_t uniqueId = getNextUId64(); uint8_t race = customize[CharaLook::Race]; uint8_t gender = customize[CharaLook::Gender]; - auto raceInfo = g_exdData.getRaceInfo( race ); + auto raceInfo = g_exdDataGen.getRace( race ); uint32_t body; uint32_t hands; @@ -312,17 +312,17 @@ namespace Core { if( gender == 0 ) { - body = raceInfo->male_body; - hands = raceInfo->male_hands; - legs = raceInfo->male_legs; - feet = raceInfo->male_feet; + body = raceInfo->rSEMBody; + hands = raceInfo->rSEMHands; + legs = raceInfo->rSEMLegs; + feet = raceInfo->rSEMFeet; } else { - body = raceInfo->female_body; - hands = raceInfo->female_hands; - legs = raceInfo->female_legs; - feet = raceInfo->female_feet; + body = raceInfo->rSEFBody; + hands = raceInfo->rSEFHands; + legs = raceInfo->rSEFLegs; + feet = raceInfo->rSEFFeet; } insertDbGlobalItem( weaponId, uniqueId ); diff --git a/src/servers/sapphire_api/main.cpp b/src/servers/sapphire_api/main.cpp index 9093ee8d..1a6fe25f 100644 --- a/src/servers/sapphire_api/main.cpp +++ b/src/servers/sapphire_api/main.cpp @@ -13,7 +13,7 @@ #include #include -#include +#include #include #include @@ -35,7 +35,7 @@ Core::Logger g_log; Core::Db::DbWorkerPool< Core::Db::CharaDbConnection > g_charaDb; -Core::Data::ExdData g_exdData; +Core::Data::ExdDataGenerated g_exdDataGen; Core::Network::SapphireAPI g_sapphireAPI; using namespace std; @@ -139,10 +139,10 @@ bool loadSettings( int32_t argc, char* argv[] ) } } - g_log.info( "Setting up EXD data" ); - if( !g_exdData.init( m_pConfig->getValue< std::string >( "Settings.General.DataPath", "" ) ) ) + g_log.info( "Setting up generated EXD data" ); + if( !g_exdDataGen.init( m_pConfig->getValue< std::string >( "Settings.General.DataPath", "" ) ) ) { - g_log.fatal( "Error setting up EXD data " ); + g_log.fatal( "Error setting up generated EXD data " ); return false; } @@ -241,10 +241,10 @@ std::string buildHttpResponse( uint16_t rCode, const std::string& content = "", void getZoneName( shared_ptr response, shared_ptr request ) { string number = request->path_match[1]; - auto it = g_exdData.m_zoneInfoMap.find( atoi( number.c_str() ) ); + auto info = g_exdDataGen.getTerritoryType( atoi( number.c_str() ) ); std::string responseStr = "Not found!"; - if( it != g_exdData.m_zoneInfoMap.end() ) - responseStr = it->second.zone_name + ", " + it->second.zone_str; + if( info ) + responseStr = info->name + ", " + info->bg; *response << buildHttpResponse( 200, responseStr ); } @@ -751,9 +751,6 @@ int main( int argc, char* argv[] ) if( !loadSettings( argc, argv ) ) throw std::exception(); - g_exdData.loadZoneInfo(); - g_exdData.loadClassJobInfo(); - server.config.port = stoi( m_pConfig->getValue< std::string >( "Settings.General.HttpPort", "80" ) ); g_log.info( "Starting API server at port " + m_pConfig->getValue< std::string >( "Settings.General.HttpPort", "80" ) + "..." ); diff --git a/src/servers/sapphire_zone/Action/ActionCast.cpp b/src/servers/sapphire_zone/Action/ActionCast.cpp index 002504fd..8e275898 100644 --- a/src/servers/sapphire_zone/Action/ActionCast.cpp +++ b/src/servers/sapphire_zone/Action/ActionCast.cpp @@ -3,8 +3,8 @@ #include #include #include -#include #include +#include #include "Network/PacketWrappers/ActorControlPacket142.h" #include "Network/PacketWrappers/ActorControlPacket143.h" @@ -17,7 +17,7 @@ using namespace Core::Network; using namespace Core::Network::Packets; using namespace Core::Network::Packets::Server; -extern Core::Data::ExdData g_exdData; +extern Core::Data::ExdDataGenerated g_exdDataGen; extern Core::Logger g_log; extern Core::Scripting::ScriptManager g_scriptMgr; @@ -31,7 +31,7 @@ Core::Action::ActionCast::ActionCast( Entity::ActorPtr pActor, Entity::ActorPtr m_startTime = 0; m_id = actionId; m_handleActionType = HandleActionType::Spell; - m_castTime = g_exdData.getActionInfo( actionId )->cast_time; // TODO: Add security checks. + m_castTime = g_exdDataGen.getAction( actionId )->cast100ms * 100; // TODO: Add security checks. m_pSource = pActor; m_pTarget = pTarget; m_bInterrupt = false; @@ -58,7 +58,6 @@ void Core::Action::ActionCast::onStart() m_pSource->sendToInRangeSet( castPacket, true ); m_pSource->getAsPlayer()->setStateFlag( PlayerStateFlag::Casting ); - m_pSource->getAsPlayer()->sendStateFlags(); } @@ -71,7 +70,6 @@ void Core::Action::ActionCast::onFinish() pPlayer->sendDebug( "onFinish()" ); pPlayer->unsetStateFlag( PlayerStateFlag::Casting ); - pPlayer->sendStateFlags(); /*auto control = ActorControlPacket143( m_pTarget->getId(), ActorControlType::Unk7, 0x219, m_id, m_id, m_id, m_id ); @@ -87,7 +85,6 @@ void Core::Action::ActionCast::onInterrupt() m_pSource->getAsPlayer()->unsetStateFlag( PlayerStateFlag::Occupied1 ); m_pSource->getAsPlayer()->unsetStateFlag( PlayerStateFlag::Casting ); - m_pSource->getAsPlayer()->sendStateFlags(); auto control = ActorControlPacket142( m_pSource->getId(), ActorControlType::CastInterrupt, 0x219, 1, m_id, 0 ); diff --git a/src/servers/sapphire_zone/Action/ActionCollision.cpp b/src/servers/sapphire_zone/Action/ActionCollision.cpp index 8a42d3c1..f2d0b68f 100644 --- a/src/servers/sapphire_zone/Action/ActionCollision.cpp +++ b/src/servers/sapphire_zone/Action/ActionCollision.cpp @@ -53,12 +53,12 @@ bool ActionCollision::isActorApplicable( ActorPtr actorPtr, TargetFilter targetF std::set< Core::Entity::ActorPtr > ActionCollision::getActorsHitFromAction( FFXIVARR_POSITION3 aoePosition, std::set< ActorPtr > actorsInRange, - boost::shared_ptr< Core::Data::ActionInfo > actionInfo, + boost::shared_ptr< Core::Data::Action > actionInfo, TargetFilter targetFilter ) { std::set< ActorPtr > actorsCollided; - switch( static_cast< ActionCollisionType >( actionInfo->aoe_type ) ) + switch( static_cast< ActionCollisionType >( actionInfo->castType ) ) { case ActionCollisionType::None: case ActionCollisionType::SingleTarget: @@ -75,7 +75,7 @@ std::set< Core::Entity::ActorPtr > ActionCollision::getActorsHitFromAction( FFXI continue; // Test our collision from actor with the area generated by the action from the AoE data - if ( radiusCollision( pActor->getPos(), aoePosition, actionInfo->aoe_width ) ) + if ( radiusCollision( pActor->getPos(), aoePosition, actionInfo->effectRange ) ) { // Add it to the actors collided with the area actorsCollided.insert( pActor ); @@ -92,7 +92,7 @@ std::set< Core::Entity::ActorPtr > ActionCollision::getActorsHitFromAction( FFXI if ( !isActorApplicable( pActor, targetFilter ) ) continue; - if ( radiusCollision( pActor->getPos(), aoePosition, actionInfo->aoe_range ) ) + if ( radiusCollision( pActor->getPos(), aoePosition, actionInfo->effectRange ) ) actorsCollided.insert( pActor ); } break; @@ -106,7 +106,7 @@ std::set< Core::Entity::ActorPtr > ActionCollision::getActorsHitFromAction( FFXI if ( !isActorApplicable( pActor, targetFilter ) ) continue; - if ( boxCollision( pActor->getPos(), aoePosition, actionInfo->aoe_width, actionInfo->aoe_range ) ) + if ( boxCollision( pActor->getPos(), aoePosition, actionInfo->xAxisModifier, actionInfo->effectRange ) ) { // todo: does this actually work? diff --git a/src/servers/sapphire_zone/Action/ActionCollision.h b/src/servers/sapphire_zone/Action/ActionCollision.h index f70f6f7a..ba2deb1e 100644 --- a/src/servers/sapphire_zone/Action/ActionCollision.h +++ b/src/servers/sapphire_zone/Action/ActionCollision.h @@ -2,6 +2,7 @@ #define _ACTIONCOLLISION_H #include +#include #include "Actor/Actor.h" #include "Action.h" @@ -25,7 +26,7 @@ namespace Entity { static bool isActorApplicable( ActorPtr actorPtr, TargetFilter targetFilter ); static std::set< ActorPtr > getActorsHitFromAction( Common::FFXIVARR_POSITION3 aoePosition, std::set< ActorPtr > actorsInRange, - boost::shared_ptr< Data::ActionInfo > actionInfo, + boost::shared_ptr< Data::Action > actionInfo, TargetFilter targetFilter ); private: diff --git a/src/servers/sapphire_zone/Action/ActionMount.cpp b/src/servers/sapphire_zone/Action/ActionMount.cpp index 6ff6c8b9..5e5a4846 100644 --- a/src/servers/sapphire_zone/Action/ActionMount.cpp +++ b/src/servers/sapphire_zone/Action/ActionMount.cpp @@ -60,7 +60,6 @@ void Core::Action::ActionMount::onStart() m_pSource->sendToInRangeSet( castPacket, true ); m_pSource->getAsPlayer()->setStateFlag( PlayerStateFlag::Casting ); - m_pSource->getAsPlayer()->sendStateFlags(); } @@ -73,7 +72,6 @@ void Core::Action::ActionMount::onFinish() pPlayer->sendDebug( "ActionMount::onFinish()" ); pPlayer->unsetStateFlag( PlayerStateFlag::Casting ); - pPlayer->sendStateFlags(); ZoneChannelPacket< FFXIVIpcEffect > effectPacket( pPlayer->getId() ); effectPacket.data().targetId = pPlayer->getId(); @@ -100,7 +98,6 @@ void Core::Action::ActionMount::onInterrupt() m_pSource->getAsPlayer()->unsetStateFlag( PlayerStateFlag::Occupied1 ); m_pSource->getAsPlayer()->unsetStateFlag( PlayerStateFlag::Casting ); - m_pSource->getAsPlayer()->sendStateFlags(); auto control = ActorControlPacket142( m_pSource->getId(), ActorControlType::CastInterrupt, 0x219, 1, m_id, 0 ); diff --git a/src/servers/sapphire_zone/Action/ActionTeleport.cpp b/src/servers/sapphire_zone/Action/ActionTeleport.cpp index 7e8cec18..7ba3d7b7 100644 --- a/src/servers/sapphire_zone/Action/ActionTeleport.cpp +++ b/src/servers/sapphire_zone/Action/ActionTeleport.cpp @@ -1,7 +1,7 @@ #include "ActionTeleport.h" #include -#include +#include #include #include "Network/PacketWrappers/ActorControlPacket142.h" @@ -13,7 +13,7 @@ using namespace Core::Network; using namespace Core::Network::Packets; using namespace Core::Network::Packets::Server; -extern Core::Data::ExdData g_exdData; +extern Core::Data::ExdDataGenerated g_exdDataGen; extern Core::Logger g_log; Core::Action::ActionTeleport::ActionTeleport() @@ -26,7 +26,7 @@ Core::Action::ActionTeleport::ActionTeleport( Entity::ActorPtr pActor, uint16_t m_startTime = 0; m_id = 5; m_handleActionType = HandleActionType::Teleport; - m_castTime = g_exdData.getActionInfo(5)->cast_time; // TODO: Add security checks. + m_castTime = g_exdDataGen.getAction( 5 )->cast100ms * 100; // TODO: Add security checks. m_pSource = pActor; m_bInterrupt = false; m_targetAetheryte = targetZone; @@ -54,7 +54,6 @@ void Core::Action::ActionTeleport::onStart() m_pSource->sendToInRangeSet( castPacket, true ); m_pSource->getAsPlayer()->setStateFlag( PlayerStateFlag::Casting ); - m_pSource->getAsPlayer()->sendStateFlags(); } @@ -75,7 +74,6 @@ void Core::Action::ActionTeleport::onFinish() pPlayer->removeCurrency( Inventory::CurrencyType::Gil, m_cost ); pPlayer->unsetStateFlag( PlayerStateFlag::Casting ); - pPlayer->sendStateFlags(); // TODO: not sure if this ever gets sent //auto control = Network::Packets::Server::ActorControlPacket142( m_pSource->getId(), Common::ActorControlType::TeleportDone ); @@ -105,7 +103,6 @@ void Core::Action::ActionTeleport::onInterrupt() return; m_pSource->getAsPlayer()->unsetStateFlag( PlayerStateFlag::Casting ); - m_pSource->getAsPlayer()->sendStateFlags(); auto control = ActorControlPacket142( m_pSource->getId(), ActorControlType::CastInterrupt, 0x219, 0x04, m_id, 0 ); diff --git a/src/servers/sapphire_zone/Action/EventAction.cpp b/src/servers/sapphire_zone/Action/EventAction.cpp index b174bdad..9fa93a45 100644 --- a/src/servers/sapphire_zone/Action/EventAction.cpp +++ b/src/servers/sapphire_zone/Action/EventAction.cpp @@ -1,15 +1,15 @@ #include #include -#include +#include #include "EventAction.h" #include "Network/PacketWrappers/ActorControlPacket142.h" #include "Network/PacketWrappers/ActorControlPacket143.h" #include "Actor/Player.h" -#include "Event/Event.h" +#include "Event/EventHandler.h" extern Core::Logger g_log; -extern Core::Data::ExdData g_exdData; +extern Core::Data::ExdDataGenerated g_exdDataGen; using namespace Core::Common; using namespace Core::Network; @@ -28,7 +28,7 @@ Core::Action::EventAction::EventAction( Entity::ActorPtr pActor, uint32_t eventI m_handleActionType = HandleActionType::Event; m_eventId = eventId; m_id = action; - m_castTime = g_exdData.m_EventActionInfoMap[action].castTime; // TODO: Add security checks. + m_castTime = g_exdDataGen.getEventAction( action )->castTime * 1000; // TODO: Add security checks. m_onActionFinishClb = finishRef; m_onActionInterruptClb = interruptRef; m_pSource = pActor; @@ -53,8 +53,7 @@ void Core::Action::EventAction::onStart() if( m_pSource->isPlayer() ) { m_pSource->sendToInRangeSet( control, true ); - m_pSource->getAsPlayer()->setStateFlag( PlayerStateFlag::SomeFlag ); - m_pSource->getAsPlayer()->sendStateFlags(); + m_pSource->getAsPlayer()->setStateFlag( PlayerStateFlag::Occupied2 ); } else m_pSource->sendToInRangeSet( control ); @@ -83,8 +82,7 @@ void Core::Action::EventAction::onFinish() if( m_pSource->isPlayer() ) { - m_pSource->getAsPlayer()->unsetStateFlag( PlayerStateFlag::SomeFlag ); - m_pSource->getAsPlayer()->sendStateFlags(); + m_pSource->getAsPlayer()->unsetStateFlag( PlayerStateFlag::Occupied2 ); m_pSource->sendToInRangeSet( control, true ); } else @@ -114,7 +112,6 @@ void Core::Action::EventAction::onInterrupt() m_pSource->getAsPlayer()->unsetStateFlag( PlayerStateFlag::NoCombat ); m_pSource->getAsPlayer()->unsetStateFlag( PlayerStateFlag::Occupied1 ); - m_pSource->getAsPlayer()->sendStateFlags(); m_pSource->sendToInRangeSet( control ); m_pSource->sendToInRangeSet( control1 ); diff --git a/src/servers/sapphire_zone/Action/EventItemAction.cpp b/src/servers/sapphire_zone/Action/EventItemAction.cpp index 3a8c3f78..28ddd8fb 100644 --- a/src/servers/sapphire_zone/Action/EventItemAction.cpp +++ b/src/servers/sapphire_zone/Action/EventItemAction.cpp @@ -56,7 +56,6 @@ void Core::Action::EventItemAction::onStart() m_pSource->sendToInRangeSet( castPacket, true ); m_pSource->getAsPlayer()->setStateFlag( PlayerStateFlag::Casting ); - m_pSource->getAsPlayer()->sendStateFlags(); } @@ -78,7 +77,6 @@ void Core::Action::EventItemAction::onFinish() effectPacket.data().effectTarget = static_cast< uint32_t >( m_additional ); m_pSource->getAsPlayer()->unsetStateFlag( Common::PlayerStateFlag::Casting ); - m_pSource->getAsPlayer()->sendStateFlags(); m_pSource->sendToInRangeSet( effectPacket, true ); if( m_onActionFinishClb ) @@ -104,7 +102,6 @@ void Core::Action::EventItemAction::onInterrupt() if( m_pSource->isPlayer() ) { m_pSource->getAsPlayer()->unsetStateFlag( PlayerStateFlag::Casting ); - m_pSource->getAsPlayer()->sendStateFlags(); m_pSource->sendToInRangeSet( control, true ); } else diff --git a/src/servers/sapphire_zone/Actor/Actor.cpp b/src/servers/sapphire_zone/Actor/Actor.cpp index 88aa1c04..3342a6e0 100644 --- a/src/servers/sapphire_zone/Actor/Actor.cpp +++ b/src/servers/sapphire_zone/Actor/Actor.cpp @@ -2,6 +2,7 @@ #include #include #include +#include #include #include "Forwards.h" @@ -24,7 +25,7 @@ #include "Player.h" extern Core::ServerZone g_serverZone; -extern Core::Data::ExdData g_exdData; +extern Core::Data::ExdDataGenerated g_exdDataGen; using namespace Core::Common; using namespace Core::Network::Packets; @@ -682,7 +683,7 @@ void Core::Entity::Actor::handleScriptSkill( uint32_t type, uint16_t actionId, u getAsPlayer()->sendDebug( "Handle script skill type: " + std::to_string( type ) ); } - auto actionInfoPtr = g_exdData.getActionInfo( actionId ); + auto actionInfoPtr = g_exdDataGen.getAction( actionId ); // Todo: Effect packet generator. 90% of this is basically setting params and it's basically unreadable. // Prepare packet. This is seemingly common for all packets in the action handler. @@ -708,7 +709,7 @@ void Core::Entity::Actor::handleScriptSkill( uint32_t type, uint16_t actionId, u effectPacket.data().effects[0].hitSeverity = ActionHitSeverityType::NormalDamage; effectPacket.data().effects[0].unknown_3 = 7; - if( !actionInfoPtr->is_aoe ) + if( actionInfoPtr->castType == 1 && actionInfoPtr->effectRange != 0 || actionInfoPtr->castType != 1 ) { // If action on this specific target is valid... if ( isPlayer() && !ActionCollision::isActorApplicable( pTarget.shared_from_this(), TargetFilter::Enemies ) ) @@ -764,7 +765,7 @@ void Core::Entity::Actor::handleScriptSkill( uint32_t type, uint16_t actionId, u effectPacket.data().effects[0].effectType = ActionEffectType::Heal; effectPacket.data().effects[0].hitSeverity = ActionHitSeverityType::NormalHeal; - if( !actionInfoPtr->is_aoe ) + if( actionInfoPtr->castType == 1 && actionInfoPtr->effectRange != 0 || actionInfoPtr->castType != 1 ) { if( isPlayer() && !ActionCollision::isActorApplicable( pTarget.shared_from_this(), TargetFilter::Allies ) ) break; diff --git a/src/servers/sapphire_zone/Actor/Actor.h b/src/servers/sapphire_zone/Actor/Actor.h index 9ceffb55..08ff963b 100644 --- a/src/servers/sapphire_zone/Actor/Actor.h +++ b/src/servers/sapphire_zone/Actor/Actor.h @@ -16,7 +16,6 @@ namespace Entity { \class Actor \brief Base class for all actors -\author Mordred */ class Actor : public boost::enable_shared_from_this< Actor > { diff --git a/src/servers/sapphire_zone/Actor/BattleNpc.cpp b/src/servers/sapphire_zone/Actor/BattleNpc.cpp index 46ab6a8b..81732922 100644 --- a/src/servers/sapphire_zone/Actor/BattleNpc.cpp +++ b/src/servers/sapphire_zone/Actor/BattleNpc.cpp @@ -5,7 +5,7 @@ #include #include -#include +#include #include #include @@ -21,7 +21,7 @@ using namespace Core::Network::Packets; using namespace Core::Network::Packets::Server; extern Core::Logger g_log; -extern Core::Data::ExdData g_exdData; +extern Core::Data::ExdDataGenerated g_exdDataGen; uint32_t Core::Entity::BattleNpc::m_nextID = 1149241694; @@ -422,7 +422,7 @@ void Core::Entity::BattleNpc::onDeath() auto levelDiff = static_cast< int32_t >( this->m_level ) - level; auto cappedLevelDiff = Math::Util::clamp( levelDiff, 1, 6 ); - auto expNeeded = g_exdData.m_paramGrowthInfoMap[m_level + cappedLevelDiff - 1].needed_exp; + auto expNeeded = g_exdDataGen.getParamGrow( m_level + cappedLevelDiff - 1 )->expToNext; int32_t exp = 0; // todo: arbitrary numbers pulled out of my ass diff --git a/src/servers/sapphire_zone/Actor/Player.cpp b/src/servers/sapphire_zone/Actor/Player.cpp index 177f05be..cfa11ab0 100644 --- a/src/servers/sapphire_zone/Actor/Player.cpp +++ b/src/servers/sapphire_zone/Actor/Player.cpp @@ -4,14 +4,14 @@ #include #include #include -#include +#include #include #include "Session.h" #include "Player.h" #include "BattleNpc.h" -#include "Zone/ZoneMgr.h" +#include "Zone/TerritoryMgr.h" #include "Zone/Zone.h" #include "ServerZone.h" @@ -35,7 +35,7 @@ #include "Inventory/Item.h" #include "Inventory/Inventory.h" -#include "Event/Event.h" +#include "Event/EventHandler.h" #include "Action/Action.h" #include "Action/EventAction.h" #include "Action/EventItemAction.h" @@ -46,8 +46,8 @@ extern Core::Logger g_log; extern Core::ServerZone g_serverZone; -extern Core::ZoneMgr g_zoneMgr; -extern Core::Data::ExdData g_exdData; +extern Core::TerritoryMgr g_territoryMgr; +extern Core::Data::ExdDataGenerated g_exdDataGen; extern Core::Scripting::ScriptManager g_scriptMgr; extern Core::Social::SocialMgr< Core::Social::FriendList > g_friendListMgr; @@ -215,36 +215,27 @@ void Core::Entity::Player::calculateStats() uint8_t level = getLevel(); uint8_t job = static_cast< uint8_t >( getClass() ); - auto classInfoIt = g_exdData.m_classJobInfoMap.find( job ); - auto tribeInfoIt = g_exdData.m_tribeInfoMap.find( tribe ); - auto paramGrowthInfoIt = g_exdData.m_paramGrowthInfoMap.find( level ); - - if( tribeInfoIt == g_exdData.m_tribeInfoMap.end() || - classInfoIt == g_exdData.m_classJobInfoMap.end() || - paramGrowthInfoIt == g_exdData.m_paramGrowthInfoMap.end() ) - return; - - auto tribeInfo = tribeInfoIt->second; - auto classInfo = classInfoIt->second; - auto paramGrowthInfo = paramGrowthInfoIt->second; + auto classInfo = g_exdDataGen.getClassJob( job ); + auto tribeInfo = g_exdDataGen.getTribe( tribe ); + auto paramGrowthInfo = g_exdDataGen.getParamGrow( level ); // TODO: put formula somewhere else... float base = Math::CalcStats::calculateBaseStat( getAsPlayer() ); - m_baseStats.str = static_cast< uint32_t >( base * ( static_cast< float >( classInfo.mod_str ) / 100 ) + tribeInfo.mod_str ); - m_baseStats.dex = static_cast< uint32_t >( base * ( static_cast< float >( classInfo.mod_dex ) / 100 ) + tribeInfo.mod_dex ); - m_baseStats.vit = static_cast< uint32_t >( base * ( static_cast< float >( classInfo.mod_vit ) / 100 ) + tribeInfo.mod_vit ); - m_baseStats.inte = static_cast< uint32_t >( base * ( static_cast< float >( classInfo.mod_int ) / 100 ) + tribeInfo.mod_int ); - m_baseStats.mnd = static_cast< uint32_t >( base * ( static_cast< float >( classInfo.mod_mnd ) / 100 ) + tribeInfo.mod_mnd ); - m_baseStats.pie = static_cast< uint32_t >( base * ( static_cast< float >( classInfo.mod_pie ) / 100 ) + tribeInfo.mod_pie ); + m_baseStats.str = static_cast< uint32_t >( base * ( static_cast< float >( classInfo->modifierStrength ) / 100 ) + tribeInfo->sTR ); + m_baseStats.dex = static_cast< uint32_t >( base * ( static_cast< float >( classInfo->modifierDexterity ) / 100 ) + tribeInfo->dEX ); + m_baseStats.vit = static_cast< uint32_t >( base * ( static_cast< float >( classInfo->modifierVitality ) / 100 ) + tribeInfo->vIT ); + m_baseStats.inte = static_cast< uint32_t >( base * ( static_cast< float >( classInfo->modifierIntelligence ) / 100 ) + tribeInfo->iNT ); + m_baseStats.mnd = static_cast< uint32_t >( base * ( static_cast< float >( classInfo->modifierMind ) / 100 ) + tribeInfo->mND ); + m_baseStats.pie = static_cast< uint32_t >( base * ( static_cast< float >( classInfo->modifierPiety ) / 100 ) + tribeInfo->pIE ); - m_baseStats.skillSpeed = paramGrowthInfo.base_secondary; - m_baseStats.spellSpeed = paramGrowthInfo.base_secondary; - m_baseStats.accuracy = paramGrowthInfo.base_secondary; - m_baseStats.critHitRate = paramGrowthInfo.base_secondary; - m_baseStats.attackPotMagic = paramGrowthInfo.base_secondary; - m_baseStats.healingPotMagic = paramGrowthInfo.base_secondary; - m_baseStats.tenacity = paramGrowthInfo.base_secondary; + m_baseStats.skillSpeed = paramGrowthInfo->baseSpeed; + m_baseStats.spellSpeed = paramGrowthInfo->baseSpeed; + m_baseStats.accuracy = paramGrowthInfo->baseSpeed; + m_baseStats.critHitRate = paramGrowthInfo->baseSpeed; + m_baseStats.attackPotMagic = paramGrowthInfo->baseSpeed; + m_baseStats.healingPotMagic = paramGrowthInfo->baseSpeed; + m_baseStats.tenacity = paramGrowthInfo->baseSpeed; m_baseStats.max_mp = Math::CalcStats::calculateMaxMp( getAsPlayer() ); @@ -309,7 +300,7 @@ uint64_t Core::Entity::Player::getFriendsListId() const void Core::Entity::Player::teleport( uint16_t aetheryteId, uint8_t type ) { - auto data = g_exdData.getAetheryteInfo( aetheryteId ); + auto data = g_exdDataGen.getAetheryte( aetheryteId ); if( data == nullptr ) { @@ -317,9 +308,8 @@ void Core::Entity::Player::teleport( uint16_t aetheryteId, uint8_t type ) } setStateFlag( PlayerStateFlag::BetweenAreas ); - sendStateFlags(); - auto z_pos = g_zoneMgr.getZonePosition( data->levelId ); + auto z_pos = g_territoryMgr.getTerritoryPosition( data->destination ); Common::FFXIVARR_POSITION3 pos; pos.x = 0; @@ -333,30 +323,30 @@ void Core::Entity::Player::teleport( uint16_t aetheryteId, uint8_t type ) rot = z_pos->getTargetRotation(); } - sendDebug( "Teleport: " + data->placename + " " + data->placename_aethernet + - "(" + std::to_string( data->levelId ) + ")" ); + sendDebug( "Teleport: " + g_exdDataGen.getPlaceName( data->placeName )->name + " " + g_exdDataGen.getPlaceName( data->aethernetName )->name + + "(" + std::to_string( data->territory ) + ")" ); // TODO: this should be simplified and a type created in server_common/common.h. if( type == 1 ) // teleport { - prepareZoning( data->target_zone, true, 1, 112 ); + prepareZoning( data->territory, true, 1, 112 ); // TODO: Really? sendToInRangeSet( ActorControlPacket142( getId(), ActorDespawnEffect, 0x04 ) ); setZoningType( Common::ZoneingType::Teleport ); } else if( type == 2 ) // aethernet { - prepareZoning( data->target_zone, true, 1, 112 ); + prepareZoning( data->territory, true, 1, 112 ); sendToInRangeSet( ActorControlPacket142( getId(), ActorDespawnEffect, 0x04 ) ); setZoningType( Common::ZoneingType::Teleport ); } else if( type == 3 ) // return { - prepareZoning( data->target_zone, true, 1, 111 ); + prepareZoning( data->territory, true, 1, 111 ); sendToInRangeSet( ActorControlPacket142( getId(), ActorDespawnEffect, 0x03 ) ); setZoningType( Common::ZoneingType::Return ); } - m_queuedZoneing = boost::make_shared< QueuedZoning >( data->target_zone, pos, Util::getTimeMs(), rot ); + m_queuedZoneing = boost::make_shared< QueuedZoning >( data->territory, pos, Util::getTimeMs(), rot ); } @@ -375,105 +365,62 @@ void Core::Entity::Player::returnToHomepoint() void Core::Entity::Player::setZone( uint32_t zoneId ) { - auto pPlayer = getAsPlayer(); - - auto pZone = g_zoneMgr.getZone( zoneId ); - - - if( !pZone /*|| ( ( pZone == m_pCurrentZone ) && m_lastPing )*/ ) + if( !g_territoryMgr.movePlayer( zoneId, getAsPlayer() ) ) { - g_log.error( "Zone " + std::to_string( zoneId ) + " not found on this server." ); - return; + // todo: this will require proper handling, for now just return the player to their previous area + m_pos = m_prevPos; + m_rot = m_prevRot; + m_zoneId = m_prevZoneId; + + if( !g_territoryMgr.movePlayer( m_zoneId, getAsPlayer() ) ) + return; } - m_zoneId = zoneId; + sendZonePackets(); +} - // mark character as zoning in progress - setLoadingComplete( false ); +bool Core::Entity::Player::setInstance( uint32_t instanceContentId ) +{ + auto instance = g_territoryMgr.getInstanceZonePtr( instanceContentId ); + if( !instance ) + return false; - if( m_lastPing != 0 ) - m_pCurrentZone->removeActor( shared_from_this() ); + return setInstance( instance ); +} - m_pCurrentZone = pZone; - m_pCurrentZone->pushActor( shared_from_this() ); +bool Core::Entity::Player::setInstance( ZonePtr instance ) +{ + if( !instance ) + return false; - ZoneChannelPacket< FFXIVIpcInit > initPacket( getId() ); - initPacket.data().charId = getId(); - queuePacket( initPacket ); - - sendInventory(); - - if( isLogin() ) + // zoning within the same zone won't cause the prev data to be overwritten + if( instance->getTerritoryId() != m_zoneId ) { - queuePacket(ActorControlPacket143( getId(), SetCharaGearParamUI, m_equipDisplayFlags, 1 ) ); + m_prevPos = m_pos; + m_prevRot = m_rot; + m_prevZoneId = m_zoneId; } - // set flags, will be reset automatically by zoning ( only on client side though ) - pPlayer->setStateFlag( PlayerStateFlag::BetweenAreas ); - pPlayer->setStateFlag( PlayerStateFlag::BetweenAreas1 ); - pPlayer->sendStateFlags(); + if( !g_territoryMgr.movePlayer( instance, getAsPlayer() ) ) + return false; - pPlayer->sendStats(); + sendZonePackets(); - // only initialize the UI if the player in fact just logged in. - if( isLogin() ) - { - ZoneChannelPacket< FFXIVIpcCFAvailableContents > contentFinderList( getId() ); - for( auto i = 0; i < sizeof( contentFinderList.data().contents ); i++ ) - { - // unlock all contents for now - contentFinderList.data().contents[i] = 0xFF; - } - queuePacket( contentFinderList ); + return true; +} - Server::InitUIPacket initUIPacket( *pPlayer ); - queuePacket( initUIPacket ); +bool Core::Entity::Player::exitInstance() +{ + if( !g_territoryMgr.movePlayer( m_prevZoneId, getAsPlayer() ) ) + return false; - ZoneChannelPacket< FFXIVIpcPlayerClassInfo > classInfoPacket( getId() ); - classInfoPacket.data().classId = static_cast< uint8_t >( getClass() ); - classInfoPacket.data().unknown = 1; - classInfoPacket.data().level = getLevel(); - classInfoPacket.data().level1 = getLevel(); - queuePacket( classInfoPacket ); + m_pos = m_prevPos; + m_rot = m_prevRot; + m_zoneId = m_prevZoneId; - ZoneChannelPacket< FFXIVGCAffiliation > gcAffPacket( getId() ); - gcAffPacket.data().gcId = m_gc; - gcAffPacket.data().gcRank[0] = m_gcRank[0]; - gcAffPacket.data().gcRank[1] = m_gcRank[1]; - gcAffPacket.data().gcRank[2] = m_gcRank[2]; - queuePacket( gcAffPacket ); + sendZonePackets(); - //todo: change this to extern, global obj - - m_friendsListId = g_friendListMgr.fetchPlayerFriendsList( getId() ); - - m_itemLevel = getInventory()->calculateEquippedGearItemLevel(); - sendItemLevel(); - } - - ZoneChannelPacket< FFXIVIpcInitZone > initZonePacket( getId() ); - initZonePacket.data().zoneId = getCurrentZone()->getLayoutId(); - initZonePacket.data().weatherId = static_cast< uint8_t >( getCurrentZone()->getCurrentWeather() ); - initZonePacket.data().bitmask = 0x1; - initZonePacket.data().unknown5 = 0x2A; - initZonePacket.data().pos.x = getPos().x; - initZonePacket.data().pos.y = getPos().y; - initZonePacket.data().pos.z = getPos().z; - queuePacket( initZonePacket ); - - if( isLogin() ) - { - ZoneChannelPacket< FFXIVARR_IPC_UNK322 > unk322( getId() ); - queuePacket( unk322 ); - - ZoneChannelPacket< FFXIVARR_IPC_UNK320 > unk320( getId() ); - queuePacket( unk320 ); - } - - if( getLastPing() == 0 ) - sendQuestInfo(); - - m_bMarkedForZoning = false; + return true; } uint32_t Core::Entity::Player::getPlayTime() const @@ -555,11 +502,11 @@ void Core::Entity::Player::discover( int16_t map_id, int16_t sub_id ) int32_t offset = 4; - auto info = g_exdData.m_zoneInfoMap[getCurrentZone()->getId()]; - if( info.is_two_byte ) - offset = 4 + 2 * info.discovery_index; + auto info = g_exdDataGen.getMap( g_exdDataGen.getTerritoryType( getCurrentZone()->getTerritoryId() )->map ); + if( info->discoveryArrayByte ) + offset = 4 + 2 * info->discoveryIndex; else - offset = 324 + 4 * info.discovery_index; + offset = 324 + 4 * info->discoveryIndex; int32_t index = offset + sub_id / 8; uint8_t bitIndex = sub_id % 8; @@ -570,7 +517,7 @@ void Core::Entity::Player::discover( int16_t map_id, int16_t sub_id ) uint16_t level = getLevel(); - uint32_t exp = ( g_exdData.m_paramGrowthInfoMap[level].needed_exp * 5 / 100 ); + uint32_t exp = ( g_exdDataGen.getParamGrow( level )->expToNext * 5 / 100 ); gainExp( exp ); @@ -593,7 +540,6 @@ void Core::Entity::Player::setNewAdventurer( bool state ) //{ // setStateFlag( PlayerStateFlag::NewAdventurer ); //} - sendStateFlags(); m_bNewAdventurer = state; } @@ -648,9 +594,9 @@ void Core::Entity::Player::gainExp( uint32_t amount ) uint16_t level = getLevel(); - uint32_t neededExpToLevel = g_exdData.m_paramGrowthInfoMap[level].needed_exp; + uint32_t neededExpToLevel = g_exdDataGen.getParamGrow( level )->expToNext; - uint32_t neededExpToLevelplus1 = g_exdData.m_paramGrowthInfoMap[level + 1].needed_exp; + uint32_t neededExpToLevelplus1 = g_exdDataGen.getParamGrow( level + 1 )->expToNext; queuePacket( ActorControlPacket143( getId(), GainExpMsg, static_cast< uint8_t >( getClass() ), amount ) ); @@ -750,25 +696,25 @@ void Core::Entity::Player::sendStatusUpdate( bool toSelf ) uint8_t Core::Entity::Player::getLevel() const { - uint8_t classJobIndex = g_exdData.m_classJobInfoMap[static_cast< uint8_t >( getClass() )].exp_idx; + uint8_t classJobIndex = g_exdDataGen.getClassJob( static_cast< uint8_t >( getClass() ) )->expArrayIndex; return static_cast< uint8_t >( m_classArray[classJobIndex] ); } uint8_t Core::Entity::Player::getLevelForClass( Common::ClassJob pClass ) const { - uint8_t classJobIndex = g_exdData.m_classJobInfoMap[static_cast< uint8_t >( pClass )].exp_idx; + uint8_t classJobIndex = g_exdDataGen.getClassJob( static_cast< uint8_t >( pClass ) )->expArrayIndex; return static_cast< uint8_t >( m_classArray[classJobIndex] ); } uint32_t Core::Entity::Player::getExp() const { - uint8_t classJobIndex = g_exdData.m_classJobInfoMap[static_cast< uint8_t >( getClass() )].exp_idx; + uint8_t classJobIndex = g_exdDataGen.getClassJob( static_cast< uint8_t >( getClass() ) )->expArrayIndex; return m_expArray[classJobIndex]; } void Core::Entity::Player::setExp( uint32_t amount ) { - uint8_t classJobIndex = g_exdData.m_classJobInfoMap[static_cast< uint8_t >( getClass() )].exp_idx; + uint8_t classJobIndex = g_exdDataGen.getClassJob( static_cast< uint8_t >( getClass() ) )->expArrayIndex; m_expArray[classJobIndex] = amount; } @@ -808,13 +754,13 @@ void Core::Entity::Player::setClassJob( Common::ClassJob classJob ) void Core::Entity::Player::setLevel( uint8_t level ) { - uint8_t classJobIndex = g_exdData.m_classJobInfoMap[static_cast< uint8_t >( static_cast< uint8_t >( getClass() ) )].exp_idx; + uint8_t classJobIndex = g_exdDataGen.getClassJob( static_cast< uint8_t >( getClass() ) )->expArrayIndex; m_classArray[classJobIndex] = level; } void Core::Entity::Player::setLevelForClass( uint8_t level, Common::ClassJob classjob ) { - uint8_t classJobIndex = g_exdData.m_classJobInfoMap[static_cast< uint8_t >( classjob )].exp_idx; + uint8_t classJobIndex = g_exdDataGen.getClassJob( static_cast< uint8_t >( classjob ) )->expArrayIndex; if( m_classArray[classJobIndex] == 0 ) insertDbClass( classJobIndex ); @@ -964,11 +910,11 @@ const uint8_t* Core::Entity::Player::getStateFlags() const bool Core::Entity::Player::actionHasCastTime( uint32_t actionId ) //TODO: Add logic for special cases { - auto actionInfoPtr = g_exdData.getActionInfo( actionId ); - if( actionInfoPtr->is_instant ) + auto actionInfoPtr = g_exdDataGen.getAction( actionId ); + if( actionInfoPtr->preservesCombo ) return false; - return actionInfoPtr->cast_time != 0; + return actionInfoPtr->cast100ms != 0; } @@ -985,6 +931,7 @@ bool Core::Entity::Player::hasStateFlag( Common::PlayerStateFlag flag ) const void Core::Entity::Player::setStateFlag( Common::PlayerStateFlag flag ) { + auto prevOnlineStatus = getOnlineStatus(); int32_t iFlag = static_cast< uint32_t >( flag ); uint16_t index; @@ -992,6 +939,13 @@ void Core::Entity::Player::setStateFlag( Common::PlayerStateFlag flag ) Util::valueToFlagByteIndexValue( iFlag, value, index ); m_stateFlags[index] |= value; + sendStateFlags(); + + auto newOnlineStatus = getOnlineStatus(); + + if( prevOnlineStatus != newOnlineStatus ) + sendToInRangeSet( ActorControlPacket142( getId(), SetStatusIcon, + static_cast< uint8_t >( getOnlineStatus() ) ), true ); } @@ -999,13 +953,7 @@ void Core::Entity::Player::setStateFlags( std::vector< Common::PlayerStateFlag > { for( const auto& flag : flags ) { - int iFlag = static_cast< uint32_t >( flag ); - - uint16_t index; - uint8_t value; - Util::valueToFlagByteIndexValue( iFlag, value, index ); - - m_stateFlags[index] |= value; + setStateFlag( flag ); } } @@ -1019,6 +967,8 @@ void Core::Entity::Player::unsetStateFlag( Common::PlayerStateFlag flag ) if( !hasStateFlag( flag ) ) return; + auto prevOnlineStatus = getOnlineStatus(); + int32_t iFlag = static_cast< uint32_t >( flag ); uint16_t index; @@ -1026,7 +976,13 @@ void Core::Entity::Player::unsetStateFlag( Common::PlayerStateFlag flag ) Util::valueToFlagByteIndexValue( iFlag, value, index ); m_stateFlags[index] ^= value; + sendStateFlags(); + auto newOnlineStatus = getOnlineStatus(); + + if( prevOnlineStatus != newOnlineStatus ) + sendToInRangeSet( ActorControlPacket142( getId(), SetStatusIcon, + static_cast< uint8_t >( getOnlineStatus() ) ), true ); } void Core::Entity::Player::update( int64_t currTime ) @@ -1036,7 +992,7 @@ void Core::Entity::Player::update( int64_t currTime ) if( m_queuedZoneing && ( currTime - m_queuedZoneing->m_queueTime ) > 800 ) { Common::FFXIVARR_POSITION3 targetPos = m_queuedZoneing->m_targetPosition; - if( getCurrentZone()->getId() != m_queuedZoneing->m_targetZone ) + if( getCurrentZone()->getTerritoryId() != m_queuedZoneing->m_targetZone ) { performZoning( m_queuedZoneing->m_targetZone, targetPos, m_queuedZoneing->m_targetRotation); } @@ -1609,3 +1565,83 @@ void Core::Entity::Player::setEorzeaTimeOffset( uint64_t timestamp ) // Send to single player queuePacket( packet ); } + +void Player::setTerritoryId( uint32_t territoryId ) +{ + m_zoneId = territoryId; +} + +uint32_t Player::getTerritoryId() const +{ + return m_zoneId; +} + +void Player::sendZonePackets() +{ + ZoneChannelPacket< FFXIVIpcInit > initPacket( getId() ); + initPacket.data().charId = getId(); + queuePacket( initPacket ); + + sendInventory(); + + if( isLogin() ) + { + queuePacket(ActorControlPacket143( getId(), SetCharaGearParamUI, m_equipDisplayFlags, 1 ) ); + } + + // set flags, will be reset automatically by zoning ( only on client side though ) + setStateFlag( PlayerStateFlag::BetweenAreas ); + setStateFlag( PlayerStateFlag::BetweenAreas1 ); + + sendStats(); + + // only initialize the UI if the player in fact just logged in. + if( isLogin() ) + { + ZoneChannelPacket< FFXIVIpcCFAvailableContents > contentFinderList( getId() ); + for( auto i = 0; i < sizeof( contentFinderList.data().contents ); i++ ) + { + // unlock all contents for now + contentFinderList.data().contents[i] = 0xFF; + } + queuePacket( contentFinderList ); + + Server::InitUIPacket initUIPacket( *this ); + queuePacket( initUIPacket ); + + ZoneChannelPacket< FFXIVIpcPlayerClassInfo > classInfoPacket( getId() ); + classInfoPacket.data().classId = static_cast< uint8_t >( getClass() ); + classInfoPacket.data().unknown = 1; + classInfoPacket.data().level = getLevel(); + classInfoPacket.data().level1 = getLevel(); + queuePacket( classInfoPacket ); + + m_itemLevel = getInventory()->calculateEquippedGearItemLevel(); + sendItemLevel(); + } + + ZoneChannelPacket< FFXIVIpcInitZone > initZonePacket( getId() ); + initZonePacket.data().zoneId = getCurrentZone()->getTerritoryId(); + initZonePacket.data().weatherId = static_cast< uint8_t >( getCurrentZone()->getCurrentWeather() ); + initZonePacket.data().bitmask = 0x1; + initZonePacket.data().unknown5 = 0x2A; + initZonePacket.data().festivalId = getCurrentZone()->getCurrentFestival(); + initZonePacket.data().pos.x = getPos().x; + initZonePacket.data().pos.y = getPos().y; + initZonePacket.data().pos.z = getPos().z; + queuePacket( initZonePacket ); + + if( isLogin() ) + { + ZoneChannelPacket< FFXIVARR_IPC_UNK322 > unk322( getId() ); + queuePacket( unk322 ); + + ZoneChannelPacket< FFXIVARR_IPC_UNK320 > unk320( getId() ); + queuePacket( unk320 ); + } + + if( getLastPing() == 0 ) + sendQuestInfo(); + + m_bMarkedForZoning = false; +} diff --git a/src/servers/sapphire_zone/Actor/Player.h b/src/servers/sapphire_zone/Actor/Player.h index da41e917..ce4cfb6b 100644 --- a/src/servers/sapphire_zone/Actor/Player.h +++ b/src/servers/sapphire_zone/Actor/Player.h @@ -11,7 +11,7 @@ #include "Actor.h" #include "Inventory/Inventory.h" - +#include "Event/EventHandler.h" #include #include @@ -55,31 +55,33 @@ public: /*! start an event item action */ void eventItemActionStart( uint32_t eventId, uint32_t action, ActionCallback finishCallback, ActionCallback interruptCallback, uint64_t additional ); /*! start/register a normal event */ - void eventStart( uint64_t actorId, uint32_t eventId, uint8_t eventParam, uint8_t eventParam1, uint32_t eventParam2 ); + void eventStart( uint64_t actorId, uint32_t eventId, Event::EventHandler::EventType eventParam, uint8_t eventParam1, uint32_t eventParam2 ); /*! play a subevent */ void eventPlay( uint32_t eventId, uint32_t scene, uint32_t flags, uint32_t eventParam2, uint32_t eventParam3 ); /*! play a subevent */ void eventPlay( uint32_t eventId, uint32_t scene, uint32_t flags, - uint32_t eventParam2, uint32_t eventParam3, Scripting::EventReturnCallback eventReturnCallback ); + uint32_t eventParam2, uint32_t eventParam3, Event::EventHandler::SceneReturnCallback eventReturnCallback ); /*! play a subevent */ void eventPlay( uint32_t eventId, uint32_t scene, uint32_t flags, - uint32_t eventParam2, uint32_t eventParam3, uint32_t eventParam4, Scripting::EventReturnCallback eventReturnCallback ); + uint32_t eventParam2, uint32_t eventParam3, uint32_t eventParam4, + Event::EventHandler::SceneReturnCallback eventReturnCallback ); /*! play a subevent */ - void eventPlay( uint32_t eventId, uint32_t scene, uint32_t flags, Scripting::EventReturnCallback eventReturnCallback ); + void eventPlay( uint32_t eventId, uint32_t scene, uint32_t flags, + Event::EventHandler::SceneReturnCallback eventReturnCallback ); /*! play a subevent */ void eventPlay( uint32_t eventId, uint32_t scene, uint32_t flags ); /*! finish / unregister an event */ void eventFinish( uint32_t eventId, uint32_t freePlayer ); /*! add an event to the event array */ - void addEvent( Event::EventPtr pEvent ); + void addEvent( Event::EventHandlerPtr pEvent ); /*! retrieve an event from the event array */ - Event::EventPtr getEvent( uint32_t eventId ); + Event::EventHandlerPtr getEvent( uint32_t eventId ); /*! get number of active events */ size_t getEventCount(); /*! remove an event from the event array */ void removeEvent( uint32_t eventId ); /*! return the eventlist */ - std::map< uint32_t, Event::EventPtr >& eventList(); + std::map< uint32_t, Event::EventHandlerPtr >& eventList(); void checkEvent( uint32_t eventId ); @@ -311,6 +313,16 @@ public: Common::OnlineStatus getOnlineStatus(); /*! sets the players zone, initiating a zoning process */ void setZone( uint32_t zoneId ); + /*! sets the players instance & initiates zoning process */ + bool setInstance( uint32_t instanceContentId ); + /*! sets the players instance & initiates zoning process */ + bool setInstance( ZonePtr instance ); + /*! returns the player to their position before zoning into an instance */ + bool exitInstance(); + /*! sets the players territoryId */ + void setTerritoryId( uint32_t territoryId ); + /*! gets the players territoryId */ + uint32_t getTerritoryId() const; void forceZoneing( uint32_t zoneId ); /*! return player to preset homepoint */ @@ -478,10 +490,12 @@ public: /*! set the loading complete bool */ void setLoadingComplete( bool bComplete ); /*! mark this player for zoning, notify worldserver */ - void performZoning(uint16_t zoneId, const Common::FFXIVARR_POSITION3& pos, float rotation); + void performZoning( uint16_t zoneId, const Common::FFXIVARR_POSITION3& pos, float rotation ); /*! return true if the player is marked for zoning */ bool isMarkedForZoning() const; + void sendZonePackets(); + Common::ZoneingType getZoningType() const; void setZoningType( Common::ZoneingType zoneingType ); @@ -563,6 +577,11 @@ private: private: + Common::FFXIVARR_POSITION3 m_prevPos; + uint32_t m_prevZoneType; + uint32_t m_prevZoneId; + float m_prevRot; + uint8_t m_voice; uint64_t m_modelMainWeapon; @@ -590,13 +609,13 @@ private: uint16_t m_activeTitle; uint8_t m_titleList[48]; uint8_t m_howTo[33]; - uint8_t m_minions[35]; - uint8_t m_mountGuide[14]; + uint8_t m_minions[37]; + uint8_t m_mountGuide[15]; uint8_t m_homePoint; uint8_t m_startTown; uint16_t m_townWarpFstFlags; - uint8_t m_questCompleteFlags[200]; - uint8_t m_discovery[420]; + uint8_t m_questCompleteFlags[396]; + uint8_t m_discovery[421]; uint32_t m_playTime; uint16_t m_classArray[25]; @@ -610,7 +629,8 @@ private: uint16_t m_itemLevel; InventoryPtr m_pInventory; - std::map< uint32_t, Event::EventPtr > m_eventMap; + std::map< uint32_t, Event::EventHandlerPtr > m_eventHandlerMap; + std::map< uint32_t, uint8_t > m_playerIdToSpawnIdMap; // maps player to spawn id std::queue< uint8_t > m_freeSpawnIdQueue; // queue with spawn ids free to be assigned std::queue< uint8_t > m_freeHateSlotQueue; // queue with "hate slots" free to be assigned diff --git a/src/servers/sapphire_zone/Actor/PlayerEvent.cpp b/src/servers/sapphire_zone/Actor/PlayerEvent.cpp index a48aea17..2e08bdb4 100644 --- a/src/servers/sapphire_zone/Actor/PlayerEvent.cpp +++ b/src/servers/sapphire_zone/Actor/PlayerEvent.cpp @@ -21,8 +21,8 @@ #include "Action/EventAction.h" #include "Action/EventItemAction.h" -#include "Event/Event.h" -#include "Event/Event.h" +#include "Event/EventHandler.h" +#include "Event/EventHandler.h" #include "ServerZone.h" extern Core::Logger g_log; @@ -32,37 +32,37 @@ using namespace Core::Common; using namespace Core::Network::Packets; using namespace Core::Network::Packets::Server; -void Core::Entity::Player::addEvent( Event::EventPtr pEvent ) +void Core::Entity::Player::addEvent( Event::EventHandlerPtr pEvent ) { - m_eventMap[pEvent->getId()] = pEvent; + m_eventHandlerMap[pEvent->getId()] = pEvent; } -std::map< uint32_t, Core::Event::EventPtr >& Core::Entity::Player::eventList() +std::map< uint32_t, Core::Event::EventHandlerPtr >& Core::Entity::Player::eventList() { - return m_eventMap; + return m_eventHandlerMap; } -Core::Event::EventPtr Core::Entity::Player::getEvent( uint32_t eventId ) +Core::Event::EventHandlerPtr Core::Entity::Player::getEvent( uint32_t eventId ) { - auto it = m_eventMap.find( eventId ); - if( it != m_eventMap.end() ) + auto it = m_eventHandlerMap.find( eventId ); + if( it != m_eventHandlerMap.end() ) return it->second; - return Event::EventPtr( nullptr ); + return Event::EventHandlerPtr( nullptr ); } size_t Core::Entity::Player::getEventCount() { - return m_eventMap.size(); + return m_eventHandlerMap.size(); } void Core::Entity::Player::removeEvent( uint32_t eventId ) { - auto it = m_eventMap.find( eventId ); - if( it != m_eventMap.end() ) + auto it = m_eventHandlerMap.find( eventId ); + if( it != m_eventHandlerMap.end() ) { auto tmpEvent = it->second; - m_eventMap.erase( it ); + m_eventHandlerMap.erase( it ); } } @@ -76,14 +76,15 @@ void Core::Entity::Player::checkEvent( uint32_t eventId ) void Core::Entity::Player::eventStart( uint64_t actorId, uint32_t eventId, - uint8_t eventType, uint8_t eventParam1, + Event::EventHandler::EventType eventType, uint8_t eventParam1, uint32_t eventParam2 ) { - Event::EventPtr newEvent( new Event::Event( actorId, eventId, eventType, eventParam1, eventParam2 ) ); + + Event::EventHandlerPtr newEvent( new Event::EventHandler( this, actorId, eventId, eventType, eventParam2 ) ); + addEvent( newEvent ); setStateFlag( PlayerStateFlag::Occupied2 ); - sendStateFlags(); EventStartPacket eventStart( getId(), actorId, eventId, eventType, eventParam1, eventParam2 ); @@ -99,7 +100,7 @@ void Core::Entity::Player::eventPlay( uint32_t eventId, uint32_t scene, } void Core::Entity::Player::eventPlay( uint32_t eventId, uint32_t scene, - uint32_t flags, Scripting::EventReturnCallback eventCallback ) + uint32_t flags, Event::EventHandler::SceneReturnCallback eventCallback ) { eventPlay( eventId, scene, flags, 0, 0, eventCallback ); } @@ -111,20 +112,16 @@ void Core::Entity::Player::eventPlay( uint32_t eventId, uint32_t scene, uint32_t void Core::Entity::Player::eventPlay( uint32_t eventId, uint32_t scene, uint32_t flags, uint32_t eventParam2, - uint32_t eventParam3, Scripting::EventReturnCallback eventCallback ) + uint32_t eventParam3, Event::EventHandler::SceneReturnCallback eventCallback ) { if( flags & 0x02 ) - { setStateFlag( PlayerStateFlag::WatchingCutscene ); - sendToInRangeSet( ActorControlPacket142( getId(), SetStatusIcon, - static_cast< uint8_t >( getOnlineStatus() ) ), true ); - } auto pEvent = getEvent( eventId ); if( !pEvent && getEventCount() ) { // We're trying to play a nested event, need to start it first. - eventStart( getId(), eventId, Event::Event::Nest, 0, 0 ); + eventStart( getId(), eventId, Event::EventHandler::Nest, 0, 0 ); pEvent = getEvent( eventId ); } else if( !pEvent ) @@ -143,20 +140,16 @@ void Core::Entity::Player::eventPlay( uint32_t eventId, uint32_t scene, void Core::Entity::Player::eventPlay( uint32_t eventId, uint32_t scene, uint32_t flags, uint32_t eventParam2, - uint32_t eventParam3, uint32_t eventParam4, Scripting::EventReturnCallback eventCallback ) + uint32_t eventParam3, uint32_t eventParam4, Event::EventHandler::SceneReturnCallback eventCallback ) { if( flags & 0x02 ) - { setStateFlag( PlayerStateFlag::WatchingCutscene ); - sendToInRangeSet( ActorControlPacket142( getId(), SetStatusIcon, - static_cast< uint8_t >( getOnlineStatus() ) ), true ); - } auto pEvent = getEvent( eventId ); if( !pEvent && getEventCount() ) { // We're trying to play a nested event, need to start it first. - eventStart( getId(), eventId, Event::Event::Nest, 0, 0 ); + eventStart( getId(), eventId, Event::EventHandler::Nest, 0, 0 ); pEvent = getEvent( eventId ); } else if( !pEvent ) @@ -183,7 +176,7 @@ void Core::Entity::Player::eventFinish( uint32_t eventId, uint32_t freePlayer ) return; } - if( getEventCount() > 1 && pEvent->getEventType() != Event::Event::Nest ) + if( getEventCount() > 1 && pEvent->getEventType() != Event::EventHandler::Nest ) { // this is the parent of a nested event, we can't finish it until the parent finishes return; @@ -191,9 +184,9 @@ void Core::Entity::Player::eventFinish( uint32_t eventId, uint32_t freePlayer ) switch( pEvent->getEventType() ) { - case Event::Event::Nest: + case Event::EventHandler::Nest: { - queuePacket( EventFinishPacket( getId(), pEvent->getId(), pEvent->getEventType(), pEvent->getEventParam3() ) ); + queuePacket( EventFinishPacket( getId(), pEvent->getId(), pEvent->getEventType(), pEvent->getEventParam() ) ); removeEvent( pEvent->getId() ); auto events = eventList(); @@ -204,7 +197,8 @@ void Core::Entity::Player::eventFinish( uint32_t eventId, uint32_t freePlayer ) if( it.second->hasPlayedScene() == false ) { // TODO: not happy with this, this is also prone to break wit more than one remaining event in there - queuePacket( EventFinishPacket( getId(), it.second->getId(), it.second->getEventType(), it.second->getEventParam3() ) ); + queuePacket( EventFinishPacket( getId(), it.second->getId(), it.second->getEventType(), + it.second->getEventParam() ) ); removeEvent( it.second->getId() ); } } @@ -213,25 +207,18 @@ void Core::Entity::Player::eventFinish( uint32_t eventId, uint32_t freePlayer ) } default: { - queuePacket( EventFinishPacket( getId(), pEvent->getId(), pEvent->getEventType(), pEvent->getEventParam3() ) ); + queuePacket( EventFinishPacket( getId(), pEvent->getId(), pEvent->getEventType(), pEvent->getEventParam() ) ); break; } } if( hasStateFlag( PlayerStateFlag::WatchingCutscene ) ) - { unsetStateFlag( PlayerStateFlag::WatchingCutscene ); - sendToInRangeSet( ActorControlPacket142( getId(), SetStatusIcon, - static_cast< uint8_t >( getOnlineStatus() ) ), true ); - } removeEvent( pEvent->getId() ); if( freePlayer == 1 ) - { unsetStateFlag( PlayerStateFlag::Occupied2 ); - sendStateFlags(); - } } void Core::Entity::Player::eventActionStart( uint32_t eventId, @@ -249,7 +236,7 @@ void Core::Entity::Player::eventActionStart( uint32_t eventId, if( !pEvent && getEventCount() ) { // We're trying to play a nested event, need to start it first. - eventStart( getId(), eventId, Event::Event::Nest, 0, 0 ); + eventStart( getId(), eventId, Event::EventHandler::Nest, 0, 0 ); pEvent = getEvent( eventId ); } else if( !pEvent ) diff --git a/src/servers/sapphire_zone/Actor/PlayerInventory.cpp b/src/servers/sapphire_zone/Actor/PlayerInventory.cpp index 6e201984..e20dfa88 100644 --- a/src/servers/sapphire_zone/Actor/PlayerInventory.cpp +++ b/src/servers/sapphire_zone/Actor/PlayerInventory.cpp @@ -5,7 +5,6 @@ #include "Player.h" -#include "Zone/ZoneMgr.h" #include "Zone/Zone.h" #include "Network/PacketWrappers/ActorControlPacket142.h" diff --git a/src/servers/sapphire_zone/Actor/PlayerQuest.cpp b/src/servers/sapphire_zone/Actor/PlayerQuest.cpp index 3a4c144d..2b1c642d 100644 --- a/src/servers/sapphire_zone/Actor/PlayerQuest.cpp +++ b/src/servers/sapphire_zone/Actor/PlayerQuest.cpp @@ -1,7 +1,7 @@ #include #include #include -#include +#include #include #include "Network/GameConnection.h" @@ -12,7 +12,7 @@ #include "Inventory/Inventory.h" #include "Player.h" -extern Core::Data::ExdData g_exdData; +extern Core::Data::ExdDataGenerated g_exdDataGen; using namespace Core::Common; using namespace Core::Network::Packets; @@ -979,7 +979,7 @@ void Core::Entity::Player::sendQuestInfo() queuePacket( pe_qa ); ZoneChannelPacket< FFXIVIpcQuestCompleteList > pe_qc( getId() ); - memcpy( pe_qc.data().questCompleteMask, m_questCompleteFlags, 200 ); + memcpy( pe_qc.data().questCompleteMask, m_questCompleteFlags, sizeof( m_questCompleteFlags ) ); queuePacket( pe_qc ); sendQuestTracker(); @@ -1015,24 +1015,24 @@ void Core::Entity::Player::removeQuestsCompleted( uint32_t questId ) bool Core::Entity::Player::giveQuestRewards( uint32_t questId, uint32_t optionalChoice ) { uint32_t playerLevel = getLevel(); - auto questInfo = g_exdData.getQuestInfo( questId ); + auto questInfo = g_exdDataGen.getQuest( questId ); if( !questInfo ) return false; - auto paramGrowth = g_exdData.m_paramGrowthInfoMap[questInfo->quest_level]; + auto paramGrowth = g_exdDataGen.getParamGrow( questInfo->classJobLevel0 ); // TODO: use the correct formula, this one is wrong - uint32_t exp = ( questInfo->reward_exp_factor * paramGrowth.quest_exp_mod * ( 45 + 5 * questInfo->quest_level) ) / 100; - exp = exp + ( questInfo->reward_exp_factor / 100 ) * 10000; + uint32_t exp = ( questInfo->expFactor * paramGrowth->questExpModifier * ( 45 + 5 * questInfo->classJobLevel0 ) ) / 100; + exp = exp + ( questInfo->expFactor / 100 ) * 10000; - exp = questInfo->reward_exp_factor; + exp = questInfo->expFactor; - auto rewardItemCount = questInfo->reward_item.size(); - uint16_t optionalItemCount = questInfo->reward_item_optional.size() > 0 ? 1 : 0; + auto rewardItemCount = questInfo->itemReward0.size(); + uint16_t optionalItemCount = questInfo->itemReward1.size(); - uint32_t gilReward = questInfo->reward_gil; + uint32_t gilReward = questInfo->gilReward; // TODO: check if there is room in inventory, else return false; if( exp > 0 ) @@ -1040,18 +1040,16 @@ bool Core::Entity::Player::giveQuestRewards( uint32_t questId, uint32_t optional if( rewardItemCount > 0 ) { - for( uint32_t i = 0; i < questInfo->reward_item.size(); i++ ) + for( uint32_t i = 0; i < questInfo->itemReward0.size(); i++ ) { - // TODO: add the correct amount of items instead of 1 - addItem( -1, questInfo->reward_item.at( i ), questInfo->reward_item_count.at( i ) ); + addItem( -1, questInfo->itemReward0.at( i ), questInfo->itemCountReward0.at( i ) ); } } if( optionalItemCount > 0 ) { - auto itemId = questInfo->reward_item_optional.at( optionalChoice ); - // TODO: add the correct amount of items instead of 1 - addItem( -1, itemId, questInfo->reward_item_optional_count.at( optionalChoice ) ); + auto itemId = questInfo->itemReward1.at( optionalChoice ); + addItem( -1, itemId, questInfo->itemCountReward1.at( optionalChoice ) ); } if( gilReward > 0 ) diff --git a/src/servers/sapphire_zone/Actor/PlayerSql.cpp b/src/servers/sapphire_zone/Actor/PlayerSql.cpp index 5a242c52..fbf2f60c 100644 --- a/src/servers/sapphire_zone/Actor/PlayerSql.cpp +++ b/src/servers/sapphire_zone/Actor/PlayerSql.cpp @@ -4,7 +4,7 @@ #include #include #include -#include +#include #include #include #include @@ -16,7 +16,7 @@ #include "Player.h" -#include "Zone/ZoneMgr.h" +#include "Zone/TerritoryMgr.h" #include "Zone/Zone.h" #include "ServerZone.h" @@ -30,8 +30,8 @@ extern Core::Logger g_log; extern Core::ServerZone g_serverZone; -extern Core::ZoneMgr g_zoneMgr; -extern Core::Data::ExdData g_exdData; +extern Core::TerritoryMgr g_territoryMgr; +extern Core::Data::ExdDataGenerated g_exdDataGen; using namespace Core::Common; @@ -47,7 +47,7 @@ bool Core::Entity::Player::load( uint32_t charId, SessionPtr pSession ) stmt->setUInt( 1, charId ); auto res = g_charaDb.query( stmt ); - + if( !res->next() ) return false; @@ -57,8 +57,10 @@ bool Core::Entity::Player::load( uint32_t charId, SessionPtr pSession ) strcpy( m_name, name.c_str() ); auto zoneId = res->getUInt( "TerritoryId" ); + m_prevZoneId = res->getUInt( "OTerritoryId" ); + m_prevZoneType = res->getUInt( "OTerritoryType" ); - ZonePtr pCurrZone = g_zoneMgr.getZone( zoneId ); + ZonePtr pCurrZone = g_territoryMgr.getZoneByTerriId( zoneId ); m_zoneId = zoneId; // TODO: logic for instances needs to be added here @@ -70,7 +72,7 @@ bool Core::Entity::Player::load( uint32_t charId, SessionPtr pSession ) // default to new gridania // TODO: should probably just abort and mark character as corrupt - pCurrZone = g_zoneMgr.getZone( 132 ); + pCurrZone = g_territoryMgr.getZoneByTerriId( 132 ); m_pos.x = 0.0f; m_pos.y = 0.0f; @@ -91,6 +93,11 @@ bool Core::Entity::Player::load( uint32_t charId, SessionPtr pSession ) m_pos.z = res->getFloat( "PosZ" ); setRotation( res->getFloat( "PosR" ) ); + m_prevPos.x = res->getFloat( "OPosX" ); + m_prevPos.y = res->getFloat( "OPosY" ); + m_prevPos.z = res->getFloat( "OPosZ" ); + m_prevRot = res->getFloat( "OPosR" ); + // Model auto custom = res->getBlobVector( "Customize" ); @@ -155,7 +162,7 @@ bool Core::Entity::Player::load( uint32_t charId, SessionPtr pSession ) auto orchestrion = res->getBlobVector( "Orchestrion" ); memcpy( reinterpret_cast< char* >( m_orchestrion ), orchestrion.data(), orchestrion.size() ); - + auto gcRank = res->getBlobVector( "GrandCompanyRank" ); memcpy( reinterpret_cast< char* >( m_gcRank ), gcRank.data(), gcRank.size() ); @@ -338,12 +345,12 @@ void Core::Entity::Player::updateSql() stmt->setDouble( 22, m_pos.z ); stmt->setDouble( 23, getRotation() ); - stmt->setInt( 24, 0 ); // OTerritoryType - stmt->setInt( 25, 0 ); // OTerritoryId - stmt->setDouble( 26, 0.0f ); - stmt->setDouble( 27, 0.0f ); - stmt->setDouble( 28, 0.0f ); - stmt->setDouble( 29, 0.0f ); + stmt->setInt( 24, m_prevZoneType ); // OTerritoryType + stmt->setInt( 25, m_prevZoneId ); // OTerritoryId + stmt->setDouble( 26, m_prevPos.x ); + stmt->setDouble( 27, m_prevPos.y ); + stmt->setDouble( 28, m_prevPos.z ); + stmt->setDouble( 29, m_prevRot ); stmt->setInt( 30, static_cast< uint8_t >( getClass() ) ); stmt->setInt( 31, static_cast< uint8_t >( getStatus() ) ); @@ -426,7 +433,7 @@ void Core::Entity::Player::updateSql() void Core::Entity::Player::updateDbClass() const { - uint8_t classJobIndex = g_exdData.m_classJobInfoMap[static_cast< uint8_t >( getClass() )].exp_idx; + uint8_t classJobIndex = g_exdDataGen.getClassJob( static_cast( getClass() ) )->expArrayIndex; //Exp = ?, Lvl = ? WHERE CharacterId = ? AND ClassIdx = ? auto stmtS = g_charaDb.getPreparedStatement( Db::CHARA_CLASS_UP ); diff --git a/src/servers/sapphire_zone/CMakeLists.txt b/src/servers/sapphire_zone/CMakeLists.txt index ce106475..804b9a77 100644 --- a/src/servers/sapphire_zone/CMakeLists.txt +++ b/src/servers/sapphire_zone/CMakeLists.txt @@ -2,6 +2,8 @@ cmake_minimum_required(VERSION 2.6) cmake_policy(SET CMP0015 NEW) cmake_policy(SET CMP0014 OLD) +add_subdirectory("Script/Scripts") + project(sapphire_zone) include_directories( ${CMAKE_CURRENT_SOURCE_DIR} ) diff --git a/src/servers/sapphire_zone/DebugCommand/DebugCommandHandler.cpp b/src/servers/sapphire_zone/DebugCommand/DebugCommandHandler.cpp index cf5e983d..cf23a55d 100644 --- a/src/servers/sapphire_zone/DebugCommand/DebugCommandHandler.cpp +++ b/src/servers/sapphire_zone/DebugCommand/DebugCommandHandler.cpp @@ -8,7 +8,7 @@ #include #include #include -#include +#include #include #include "DebugCommand.h" @@ -38,11 +38,13 @@ #include #include "Network/PacketWrappers/PlayerSpawnPacket.h" +#include "Zone/TerritoryMgr.h" extern Core::Scripting::ScriptManager g_scriptMgr; -extern Core::Data::ExdData g_exdData; +extern Core::Data::ExdDataGenerated g_exdDataGen; extern Core::Logger g_log; extern Core::ServerZone g_serverZone; +extern Core::TerritoryMgr g_territoryMgr; // instanciate and initialize commands Core::DebugCommandHandler::DebugCommandHandler() @@ -59,6 +61,7 @@ Core::DebugCommandHandler::DebugCommandHandler() registerCommand( "unlock", &DebugCommandHandler::unlockCharacter, "Unlock character.", 1 ); registerCommand( "help", &DebugCommandHandler::help, "Shows registered commands.", 0 ); registerCommand( "script", &DebugCommandHandler::script, "Server script utilities.", 1 ); + registerCommand( "instance", &DebugCommandHandler::instance, "Instance utilities", 1 ); } // clear all loaded commands @@ -280,6 +283,29 @@ void Core::DebugCommandHandler::set( char * data, Entity::Player& player, boost: player.dismount(); player.mount( id ); } + else if ( subCommand == "msqguide" ) + { + int32_t id; + sscanf( params.c_str(), "%d", &id ); + + Network::Packets::ZoneChannelPacket< Network::Packets::Server::FFXIVIpcMSQTrackerProgress > msqPacket( + player.getId()); + msqPacket.data().id = id; + player.queuePacket( msqPacket ); + + player.sendDebug( "MSQ Guide updated " ); + } + else if ( subCommand == "msqdone") + { + int32_t id; + sscanf( params.c_str(), "%d", &id ); + + Network::Packets::ZoneChannelPacket< Network::Packets::Server::FFXIVIpcMSQTrackerComplete > msqPacket ( player.getId() ); + msqPacket.data().id = id; + player.queuePacket( msqPacket ); + + player.sendDebug( "MSQ Guide updated " ); + } else { player.sendUrgent( subCommand + " is not a valid SET command." ); @@ -479,7 +505,7 @@ void Core::DebugCommandHandler::get( char * data, Entity::Player& player, boost: if( ( subCommand == "pos" ) ) { - int16_t map_id = g_exdData.m_zoneInfoMap[player.getCurrentZone()->getId()].map_id; + int16_t map_id = g_exdDataGen.getTerritoryType( player.getCurrentZone()->getTerritoryId() )->map; player.sendNotice( "Pos:\n" + std::to_string( player.getPos().x ) + "\n" + @@ -487,7 +513,7 @@ void Core::DebugCommandHandler::get( char * data, Entity::Player& player, boost: std::to_string( player.getPos().z ) + "\n" + std::to_string( player.getRotation() ) + "\nMapId: " + std::to_string( map_id ) + "\nZoneID: " + - std::to_string( player.getCurrentZone()->getId() ) + "\n" ); + std::to_string(player.getCurrentZone()->getTerritoryId() ) + "\n" ); } else { @@ -557,7 +583,7 @@ void Core::DebugCommandHandler::replay( char * data, Entity::Player& player, boo player.sendUrgent( subCommand + " is not a valid replay command." ); } - + } void Core::DebugCommandHandler::nudge( char * data, Entity::Player& player, boost::shared_ptr< DebugCommand > command ) @@ -701,17 +727,70 @@ void Core::DebugCommandHandler::script( char* data, Entity::Player &player, boos player.sendDebug( "Queued script reload for script: " + params ); } } - else if( subCommand == "build" || subCommand == "b" ) - { - if( subCommand == params ) - player.sendDebug( "Command failed: requires name of cmake target" ); - else - { - - } - } else { player.sendDebug( "Unknown script subcommand: " + subCommand ); } } + +void Core::DebugCommandHandler::instance( char* data, Entity::Player &player, boost::shared_ptr< DebugCommand > command ) +{ + std::string cmd( data ), params, subCommand; + auto cmdPos = cmd.find_first_of( ' ' ); + + if( cmdPos != std::string::npos ) + { + params = cmd.substr( cmdPos + 1 ); + + auto p = params.find_first_of( ' ' ); + + if( p != std::string::npos ) + { + subCommand = params.substr( 0, p ); + params = params.substr( subCommand.length() + 1 ); + } + else + subCommand = params; + } + + if( subCommand == "create" || subCommand == "cr" ) + { + uint32_t instanceContentId; + sscanf( params.c_str(), "%d", &instanceContentId ); + + auto instance = g_territoryMgr.createInstanceContent( instanceContentId ); + if( instance ) + player.sendDebug( "Created instance with id: " + std::to_string( instance->getGuId() ) + " -> " + instance->getName() ); + else + player.sendDebug( "Failed to create instance with id: " + std::to_string( instanceContentId ) ); + } + else if( subCommand == "remove" || subCommand == "rm" ) + { + uint32_t terriId; + sscanf( params.c_str(), "%d", &terriId ); + + if( g_territoryMgr.removeTerritoryInstance( terriId ) ) + player.sendDebug( "Removed instance with id: " + std::to_string( terriId ) ); + else + player.sendDebug( "Failed to remove instance with id: " + std::to_string( terriId ) ); + } + else if( subCommand == "return" || subCommand == "ret" ) + { + player.exitInstance(); + } + else if( subCommand == "festival" ) + { + uint32_t festivalId; + sscanf( params.c_str(), "%d", &festivalId ); + + player.getCurrentZone()->setCurrentFestival( static_cast< uint16_t >( festivalId ) ); + } + else if( subCommand == "disablefestival" ) + { + Network::Packets::ZoneChannelPacket< Network::Packets::Server::FFXIVIpcActorControl143 > actorControl( player.getId() ); + actorControl.data().category = Core::Common::ActorControlType::DisableCurrentFestival; + player.queuePacket( actorControl ); + + player.getCurrentZone()->setCurrentFestival( 0 ); + } +} diff --git a/src/servers/sapphire_zone/DebugCommand/DebugCommandHandler.h b/src/servers/sapphire_zone/DebugCommand/DebugCommandHandler.h index cc5570e5..a0956764 100644 --- a/src/servers/sapphire_zone/DebugCommand/DebugCommandHandler.h +++ b/src/servers/sapphire_zone/DebugCommand/DebugCommandHandler.h @@ -44,6 +44,8 @@ public: void unlockCharacter( char* data, Entity::Player& player, boost::shared_ptr< DebugCommand > command ); + void instance( char* data, Entity::Player& player, boost::shared_ptr< DebugCommand > command ); + void script( char* data, Entity::Player& player, boost::shared_ptr< DebugCommand > command ); }; diff --git a/src/servers/sapphire_zone/Event/Director.cpp b/src/servers/sapphire_zone/Event/Director.cpp new file mode 100644 index 00000000..79e7142b --- /dev/null +++ b/src/servers/sapphire_zone/Event/Director.cpp @@ -0,0 +1 @@ +#include "Director.h" diff --git a/src/servers/sapphire_zone/Event/Director.h b/src/servers/sapphire_zone/Event/Director.h new file mode 100644 index 00000000..8a3c0245 --- /dev/null +++ b/src/servers/sapphire_zone/Event/Director.h @@ -0,0 +1,66 @@ +#ifndef SAPPHIRE_DIRECTOR_H +#define SAPPHIRE_DIRECTOR_H + +#include + +#include "Forwards.h" + +namespace Core { +namespace Event { + +/*! +\class Director +\brief Base class for all Directors implements sequence and variables + +*/ + +class Director +{ + +public: + enum DirectorType + { + InstanceContent = 0x8003, // used for dungeons/raids + CompanyLeve = 0x8007, + QuestBattle = 0x8006, + GatheringLeve = 0x8002, + BattleLeve = 0x8001, + GoldSaucer = 0x800A, + Fate = 0x801A, + DpsChallange = 0x800D + }; + +private: + /*! Id of the content of the director */ + uint16_t m_id; + + /*! DirectorType | ContentId */ + uint32_t m_directorId; + + /*! currect sequence */ + uint8_t m_sequence; + + /*! current branch */ + uint8_t m_branch; + + /*! raw storage for flags/vars */ + uint8_t m_unionData[10]; + + /*! type of the director */ + DirectorType m_type; + + uint32_t getDirectorId() const; + uint16_t getContentId() const; + DirectorType getType() const; + uint8_t getSequence() const; + uint8_t getBranch() const; + +}; + + +} +} + + + +#endif //SAPPHIRE_DIRECTOR_H diff --git a/src/servers/sapphire_zone/Event/Event.cpp b/src/servers/sapphire_zone/Event/Event.cpp deleted file mode 100644 index ee1a3f6e..00000000 --- a/src/servers/sapphire_zone/Event/Event.cpp +++ /dev/null @@ -1,73 +0,0 @@ -#include "Event.h" - -Core::Event::Event::Event( uint64_t actorId, uint32_t eventId, uint8_t eventType, uint8_t eventParam2, uint32_t eventParam3 ) - : m_actorId( actorId ), - m_eventId( eventId ), - m_playedScene( false ) -{ - - m_param1 = static_cast< uint16_t >( eventId ); - m_param2 = static_cast< uint16_t >( eventId >> 16 ); - - m_eventType = eventType; - m_eventParam2 = eventParam2; - m_eventParam3 = eventParam3; - - m_callback = nullptr; -} - -uint64_t Core::Event::Event::getActorId() const -{ - return m_actorId; -} - -uint32_t Core::Event::Event::getId() const -{ - return m_eventId; -} - -uint32_t Core::Event::Event::getParam1() const -{ - return m_param1; -} - -uint16_t Core::Event::Event::getParam2() const -{ - return m_param2; -} - -uint8_t Core::Event::Event::getEventType() const -{ - return m_eventType; -} - -uint32_t Core::Event::Event::getEventParam2() const -{ - return m_eventParam2; -} - -uint32_t Core::Event::Event::getEventParam3() const -{ - return m_eventParam3; -} - -Core::Scripting::EventReturnCallback Core::Event::Event::getEventReturnCallback() const -{ - return m_callback; -} - -void Core::Event::Event::setEventReturnCallback( Scripting::EventReturnCallback callback ) -{ - m_callback = callback; -} - - -bool Core::Event::Event::hasPlayedScene() const -{ - return m_playedScene; -} - -void Core::Event::Event::setPlayedScene( bool playedScene ) -{ - m_playedScene = playedScene; -} diff --git a/src/servers/sapphire_zone/Event/Event.h b/src/servers/sapphire_zone/Event/Event.h deleted file mode 100644 index 8935cd22..00000000 --- a/src/servers/sapphire_zone/Event/Event.h +++ /dev/null @@ -1,78 +0,0 @@ -#ifndef _EVENT_H -#define _EVENT_H - -#include "../Forwards.h" - -namespace Core { - namespace Event { - - class Event - { - public: - Event( uint64_t actorId, uint32_t eventId, uint8_t eventType, uint8_t eventParam2, uint32_t eventParam3 ); - - ~Event() {} - - uint64_t getActorId() const; - - uint32_t getId() const; - - uint32_t getParam1() const; - - uint16_t getParam2() const; - - uint8_t getEventType() const; - - uint32_t getEventParam2() const; - - uint32_t getEventParam3() const; - - bool hasPlayedScene() const; - - void setPlayedScene( bool playedScene ); - - Scripting::EventReturnCallback getEventReturnCallback() const; - - void setEventReturnCallback( Scripting::EventReturnCallback callback ); - - enum EventType : uint8_t - { - Talk = 1, - Emote = 2, - DistanceBelow = 3, - DistanceOver = 4, - BattleReward = 5, - Craft = 6, - Nest = 7, - Item = 8, - Drop = 9, - WithinRange = 10, - OutsideRange = 11, - GameStart = 12, - GameProgress = 13, - EnterTerritory = 15, - GameComeBack = 17, - ActionResult = 18, - MateriaCraft = 19, - Fishing = 20, - UI = 21, - Housing = 22, - Say = 23, - TableGame = 24, - }; - - protected: - uint64_t m_actorId; - uint32_t m_eventId; - uint32_t m_param1; - uint16_t m_param2; - uint8_t m_eventType; - uint8_t m_eventParam2; - uint32_t m_eventParam3; - bool m_playedScene; - Scripting::EventReturnCallback m_callback; - }; - - } -} -#endif diff --git a/src/servers/sapphire_zone/Event/EventHandler.cpp b/src/servers/sapphire_zone/Event/EventHandler.cpp new file mode 100644 index 00000000..1968f59b --- /dev/null +++ b/src/servers/sapphire_zone/Event/EventHandler.cpp @@ -0,0 +1,75 @@ +#include "EventHandler.h" + +Core::Event::EventHandler::EventHandler( Entity::Player* pOwner, uint64_t actorId, uint32_t eventId, EventType eventType, uint32_t eventParam ) : + m_pOwner( pOwner ), + m_actorId( actorId ), + m_eventId( eventId ), + m_eventType( eventType ), + m_playedScene( false ) +{ + m_entryId = static_cast< uint16_t >( eventId ); + m_type = static_cast< uint16_t >( eventId >> 16 ); + m_eventParam = eventParam; + m_callback = nullptr; +} + +uint64_t Core::Event::EventHandler::getActorId() const +{ + return m_actorId; +} + +uint32_t Core::Event::EventHandler::getId() const +{ + return m_eventId; +} + +uint8_t Core::Event::EventHandler::getEventType() const +{ + return m_eventType; +} + +uint16_t Core::Event::EventHandler::getType() const +{ + return m_type; +} + +uint16_t Core::Event::EventHandler::getEntryId() const +{ + return m_entryId; +} + +uint32_t Core::Event::EventHandler::getEventParam() const +{ + return m_eventParam; +} + +Core::Event::EventHandler::SceneReturnCallback Core::Event::EventHandler::getEventReturnCallback() const +{ + return m_callback; +} + +void Core::Event::EventHandler::setEventReturnCallback( SceneReturnCallback callback ) +{ + m_callback = callback; +} + +bool Core::Event::EventHandler::hasPlayedScene() const +{ + return m_playedScene; +} + +void Core::Event::EventHandler::setPlayedScene( bool playedScene ) +{ + m_playedScene = playedScene; +} + +bool Core::Event::EventHandler::hasNestedEvent() const +{ + return m_pNestedEvent != nullptr; +} + +void Core::Event::EventHandler::removeNestedEvent() +{ + m_pNestedEvent.reset(); +} + diff --git a/src/servers/sapphire_zone/Event/EventHandler.h b/src/servers/sapphire_zone/Event/EventHandler.h new file mode 100644 index 00000000..e02434c6 --- /dev/null +++ b/src/servers/sapphire_zone/Event/EventHandler.h @@ -0,0 +1,113 @@ +#ifndef _EVENT_H +#define _EVENT_H + +#include "../Forwards.h" + +namespace Core { + namespace Event { + + class EventHandler + { + public: + enum EventType : uint8_t + { + Talk = 1, + Emote = 2, + DistanceBelow = 3, + DistanceOver = 4, + BattleReward = 5, + Craft = 6, + Nest = 7, + Item = 8, + Drop = 9, + WithinRange = 10, + OutsideRange = 11, + GameStart = 12, + GameProgress = 13, + EnterTerritory = 15, + GameComeBack = 17, + ActionResult = 18, + MateriaCraft = 19, + Fishing = 20, + UI = 21, + Housing = 22, + Say = 23, + TableGame = 24, + }; + + enum EventHandlerType : uint16_t + { + Quest = 0x0001, + Warp = 0x0002, + Unknown = 0x0003, // Came up in the client with "Begin" unsure that means + Shop = 0x0004, + Aetheryte = 0x0005, + GuildLeveAssignment = 0x0006, + DefaultTalk = 0x0009, + CustomTalk = 0x000B, + CompanyLeveOfficer = 0x000C, + CraftLeve = 0x000E, + GimmickAccessor = 0x000F, + GimmickBill = 0x0010, + GimmickRect = 0x0011, + ChocoboTaxiStand = 0x0012, + Opening = 0x0013, + ExitRange = 0x0014, + GCShop = 0x0016, + GuildOrderGuide = 0x0017, + GuildOrderOfficer = 0x0018, + ContentNpc = 0x0019, + Story = 0x001A, + SpecialShop = 0x001B, + BahamutGuide = 0x001C, + FcTalk = 0x001F, + }; + + using SceneReturnCallback = std::function< void( Entity::Player&, uint32_t, uint16_t, uint16_t, uint16_t ) > ; + + EventHandler( Entity::Player* pOwner, uint64_t actorId, uint32_t eventId, EventType eventType, uint32_t eventParam ); + + ~EventHandler() {} + + uint64_t getActorId() const; + + uint32_t getId() const; + + uint16_t getType() const; + + uint16_t getEntryId() const; + + uint8_t getEventType() const; + + uint32_t getEventParam() const; + + bool hasPlayedScene() const; + + void setPlayedScene( bool playedScene ); + + SceneReturnCallback getEventReturnCallback() const; + + void setEventReturnCallback( SceneReturnCallback callback ); + + bool hasNestedEvent() const; + + void removeNestedEvent(); + + + protected: + Entity::Player* m_pOwner; + + uint64_t m_actorId; + uint32_t m_eventId; + uint16_t m_entryId; + uint16_t m_type; + uint8_t m_eventType; + uint32_t m_eventParam; + EventHandlerPtr m_pNestedEvent; + bool m_playedScene; + SceneReturnCallback m_callback; + }; + + } +} +#endif diff --git a/src/servers/sapphire_zone/Event/EventHelper.cpp b/src/servers/sapphire_zone/Event/EventHelper.cpp index 9d90cc3e..b3b598f7 100644 --- a/src/servers/sapphire_zone/Event/EventHelper.cpp +++ b/src/servers/sapphire_zone/Event/EventHelper.cpp @@ -1,9 +1,9 @@ #include "EventHelper.h" -#include "Event.h" +#include "EventHandler.h" #include -#include +#include -extern Core::Data::ExdData g_exdData; +extern Core::Data::ExdDataGenerated g_exdDataGen; using namespace Core::Common; @@ -15,43 +15,44 @@ std::string Core::Event::getEventName( uint32_t eventId ) switch( eventType ) { - case EventType::Quest: + case Event::EventHandler::EventHandlerType::Quest: { - auto questInfo = g_exdData.getQuestInfo( eventId ); + auto questInfo = g_exdDataGen.getQuest( eventId ); if( !questInfo ) return unknown + "Quest"; - std::string name = questInfo->name_intern; + std::string name = questInfo->id; std::size_t pos = name.find_first_of( "_" ); - return questInfo->name_intern.substr( 0, pos ); + return name.substr( 0, pos ); } - case EventType::CustomTalk: + case Event::EventHandler::EventHandlerType::CustomTalk: { - auto customTalkInfo = g_exdData.getCustomTalkInfo( eventId ); + auto customTalkInfo = g_exdDataGen.getCustomTalk( eventId ); if( !customTalkInfo ) return unknown + "CustomTalk"; - std::string name = customTalkInfo->name_intern; + std::string name = customTalkInfo->name; std::size_t pos = name.find_first_of( "_" ); - return customTalkInfo->name_intern.substr( 0, pos ); + return customTalkInfo->name.substr( 0, pos ); } - case EventType::Opening: + case Event::EventHandler::EventHandlerType::Opening: { - auto openingInfo = g_exdData.getOpeningInfo( eventId ); + auto openingInfo = g_exdDataGen.getOpening( eventId ); if( openingInfo ) return openingInfo->name; return unknown + "Opening"; } - case EventType::Aetheryte: + case Event::EventHandler::EventHandlerType::Aetheryte: { - auto aetherInfo = g_exdData.getAetheryteInfo( eventId & 0xFFFF ); + auto aetherInfo = g_exdDataGen.getAetheryte( eventId & 0xFFFF ); if( aetherInfo->isAetheryte ) return "Aetheryte"; return "Aethernet"; } - case EventType::ChocoPort: + + case Event::EventHandler::EventHandlerType::Warp: { return "ChocoboTaxi"; } @@ -64,9 +65,9 @@ std::string Core::Event::getEventName( uint32_t eventId ) uint32_t Core::Event::mapEventActorToRealActor( uint32_t eventActorId ) { - auto levelInfo = g_exdData.getLevelInfo( eventActorId ); + auto levelInfo = g_exdDataGen.getLevel( eventActorId ); if( levelInfo ) - return levelInfo->actor_id; + return levelInfo->objectKey; return 0; } diff --git a/src/servers/sapphire_zone/Forwards.h b/src/servers/sapphire_zone/Forwards.h index b3dbf611..54bfaa1a 100644 --- a/src/servers/sapphire_zone/Forwards.h +++ b/src/servers/sapphire_zone/Forwards.h @@ -37,7 +37,8 @@ namespace Core namespace Event { - TYPE_FORWARD( Event ); + TYPE_FORWARD( Director ); + TYPE_FORWARD( EventHandler ); } namespace Action @@ -72,7 +73,6 @@ namespace Core namespace Scripting { class NativeScriptManager; - typedef std::function< void( Entity::Player&, uint32_t, uint16_t, uint16_t, uint16_t ) > EventReturnCallback; } typedef std::function< void( Entity::Player&, uint32_t, uint64_t ) > ActionCallback; diff --git a/src/servers/sapphire_zone/Inventory/Inventory.cpp b/src/servers/sapphire_zone/Inventory/Inventory.cpp index 7d2275a4..7ace94d7 100644 --- a/src/servers/sapphire_zone/Inventory/Inventory.cpp +++ b/src/servers/sapphire_zone/Inventory/Inventory.cpp @@ -1,6 +1,6 @@ #include #include -#include +#include #include #include @@ -21,7 +21,7 @@ extern Core::Logger g_log; -extern Core::Data::ExdData g_exdData; +extern Core::Data::ExdDataGenerated g_exdDataGen; using namespace Core::Common; using namespace Core::Network; @@ -135,11 +135,11 @@ Core::ItemPtr Core::Inventory::getItemAt( uint16_t containerId, uint8_t slotId ) Core::ItemPtr Core::Inventory::createItem( uint32_t catalogId, uint8_t quantity ) { - auto itemInfo = g_exdData.getItemInfo( catalogId ); + auto itemInfo = g_exdDataGen.getItem( catalogId ); uint8_t itemAmount = quantity; - if( itemInfo->stack_size == 1 ) + if( itemInfo->stackSize == 1 ) itemAmount = 1; if( !itemInfo ) @@ -153,8 +153,8 @@ Core::ItemPtr Core::Inventory::createItem( uint32_t catalogId, uint8_t quantity pItem->setStackSize( itemAmount ); pItem->setUId( getNextUId() ); - pItem->setModelIds( itemInfo->model_primary, itemInfo->model_secondary ); - pItem->setCategory( static_cast< ItemUICategory >( itemInfo->ui_category ) ); + pItem->setModelIds( itemInfo->modelMain, itemInfo->modelSub ); + pItem->setCategory( static_cast< ItemUICategory >( itemInfo->itemUICategory ) ); g_charaDb.execute( "INSERT INTO charaglobalitem ( CharacterId, itemId, catalogId, stack, flags ) VALUES ( " + std::to_string( m_pOwner->getId() ) + ", " + @@ -473,10 +473,10 @@ bool Core::Inventory::isObtainable( uint32_t catalogId, uint8_t quantity ) int16_t Core::Inventory::addItem( uint16_t inventoryId, int8_t slotId, uint32_t catalogId, uint8_t quantity ) { - auto itemInfo = g_exdData.getItemInfo( catalogId ); + auto itemInfo = g_exdDataGen.getItem( catalogId ); // if item data doesn't exist or it's a blank field - if( !itemInfo || itemInfo->item_level == 0 ) + if( !itemInfo || itemInfo->levelItem == 0 ) { return -1; } @@ -656,13 +656,13 @@ Core::ItemPtr Core::Inventory::loadItem( uint64_t uId ) try { - auto itemInfo = g_exdData.getItemInfo( itemRes->getUInt( 1 ) ); + auto itemInfo = g_exdDataGen.getItem( itemRes->getUInt( 1 ) ); bool isHq = itemRes->getUInt( 3 ) == 1 ? true : false; ItemPtr pItem( new Item( uId, - itemInfo->id, - itemInfo->model_primary, - itemInfo->model_secondary, - static_cast< ItemUICategory >( itemInfo->ui_category ), + itemRes->getUInt( 1 ), + itemInfo->modelMain, + itemInfo->modelSub, + static_cast< ItemUICategory >( itemInfo->itemUICategory ), isHq ) ); pItem->setStackSize( itemRes->getUInt( 2 ) ); diff --git a/src/servers/sapphire_zone/Inventory/Item.cpp b/src/servers/sapphire_zone/Inventory/Item.cpp index e77c4ca4..01f7639c 100644 --- a/src/servers/sapphire_zone/Inventory/Item.cpp +++ b/src/servers/sapphire_zone/Inventory/Item.cpp @@ -1,8 +1,8 @@ #include -#include +#include #include "Item.h" -extern Core::Data::ExdData g_exdData; +extern Core::Data::ExdDataGenerated g_exdDataGen; Core::Item::Item() { @@ -24,13 +24,13 @@ Core::Item::Item( uint64_t uId, uint32_t catalogId, uint64_t model1, uint64_t mo m_model2( model2 ), m_isHq( isHq ) { - auto itemInfo = g_exdData.getItemInfo( catalogId ); - m_delayMs = itemInfo->delayMs; - m_physicalDmg = itemInfo->physical_damage; - m_magicalDmg = itemInfo->magical_damage; + auto itemInfo = g_exdDataGen.getItem( catalogId ); + m_delayMs = itemInfo->delayms; + m_physicalDmg = itemInfo->damagePhys; + m_magicalDmg = itemInfo->damageMag; m_weaponDmg = ( m_physicalDmg != 0 ) ? m_physicalDmg : m_magicalDmg; m_autoAttackDmg = static_cast< float >( m_weaponDmg * m_delayMs ) / 3000; - m_itemLevel = itemInfo->item_level; + m_itemLevel = itemInfo->levelItem; } Core::Item::~Item() diff --git a/src/servers/sapphire_zone/Math/CalcBattle.cpp b/src/servers/sapphire_zone/Math/CalcBattle.cpp index 12f93936..89a522cd 100644 --- a/src/servers/sapphire_zone/Math/CalcBattle.cpp +++ b/src/servers/sapphire_zone/Math/CalcBattle.cpp @@ -1,6 +1,6 @@ #include -#include +#include #include #include "Actor/Actor.h" #include "Actor/Player.h" @@ -10,7 +10,7 @@ using namespace Core::Math; using namespace Core::Entity; -extern Core::Data::ExdData g_exdData; +extern Core::Data::ExdDataGenerated g_exdDataGen; /* Class used for battle-related formulas and calculations. @@ -30,14 +30,13 @@ extern Core::Data::ExdData g_exdData; uint32_t CalcBattle::calculateHealValue( PlayerPtr pPlayer, uint32_t potency ) { - auto classInfoIt = g_exdData.m_classJobInfoMap.find( static_cast< uint8_t >( pPlayer->getClass() ) ); - auto paramGrowthInfoIt = g_exdData.m_paramGrowthInfoMap.find( pPlayer->getLevel() ); + auto classInfo = g_exdDataGen.getClassJob( static_cast< uint8_t >( pPlayer->getClass() ) ); + auto paramGrowthInfo = g_exdDataGen.getParamGrow( pPlayer->getLevel() ); - if ( classInfoIt == g_exdData.m_classJobInfoMap.end() || - paramGrowthInfoIt == g_exdData.m_paramGrowthInfoMap.end()) + if ( !classInfo || !paramGrowthInfo ) return 0; - auto jobModVal = classInfoIt->second; + //auto jobModVal = classInfoIt->second; // consider 3% variation return potency / 10; diff --git a/src/servers/sapphire_zone/Math/CalcStats.cpp b/src/servers/sapphire_zone/Math/CalcStats.cpp index 2e390887..63bf66ea 100644 --- a/src/servers/sapphire_zone/Math/CalcStats.cpp +++ b/src/servers/sapphire_zone/Math/CalcStats.cpp @@ -1,6 +1,6 @@ #include -#include +#include #include #include "Actor/Actor.h" #include "Actor/Player.h" @@ -11,7 +11,7 @@ using namespace Core::Math; using namespace Core::Entity; -extern Core::Data::ExdData g_exdData; +extern Core::Data::ExdDataGenerated g_exdDataGen; /* Class used for battle-related formulas and calculations. @@ -61,19 +61,18 @@ uint32_t CalcStats::calculateMaxHp( PlayerPtr pPlayer ) // Is there any way to pull reliable BaseHP without having to manually use a pet for every level, and using the values from a table? // More info here: https://docs.google.com/spreadsheets/d/1de06KGT0cNRUvyiXNmjNgcNvzBCCQku7jte5QxEQRbs/edit?usp=sharing - auto classInfoIt = g_exdData.m_classJobInfoMap.find( static_cast< uint8_t >( pPlayer->getClass() ) ); - auto paramGrowthInfoIt = g_exdData.m_paramGrowthInfoMap.find( pPlayer->getLevel() ); + auto classInfo = g_exdDataGen.getClassJob( static_cast< uint8_t >( pPlayer->getClass() ) ); + auto paramGrowthInfo = g_exdDataGen.getParamGrow( pPlayer->getLevel() ); - if ( classInfoIt == g_exdData.m_classJobInfoMap.end() || - paramGrowthInfoIt == g_exdData.m_paramGrowthInfoMap.end() ) + if ( !classInfo || !paramGrowthInfo ) return 0; uint8_t level = pPlayer->getLevel(); float baseStat = calculateBaseStat( pPlayer ); uint16_t vitStat = pPlayer->getStats().vit; - uint16_t hpMod = paramGrowthInfoIt->second.hp_mod; - uint16_t jobModHp = classInfoIt->second.mod_hp; + uint16_t hpMod = paramGrowthInfo->hpModifier; + uint16_t jobModHp = classInfo->modifierHitPoints; float approxBaseHp = 0.0f; // Read above // These values are not precise. @@ -83,7 +82,7 @@ uint32_t CalcStats::calculateMaxHp( PlayerPtr pPlayer ) else if ( level >= 50 ) approxBaseHp = 1700 + ( ( level - 50 ) * ( 1700 * 1.04325f ) ); else - approxBaseHp = paramGrowthInfoIt->second.mp_const * 0.7667f; + approxBaseHp = paramGrowthInfo->mpModifier * 0.7667f; uint16_t result = static_cast< uint16_t >( floor( jobModHp * ( approxBaseHp / 100.0f ) ) + floor( hpMod / 100.0f * ( vitStat - baseStat ) ) ); @@ -95,18 +94,17 @@ uint32_t CalcStats::calculateMaxHp( PlayerPtr pPlayer ) uint32_t CalcStats::calculateMaxMp( PlayerPtr pPlayer ) { - auto classInfoIt = g_exdData.m_classJobInfoMap.find( static_cast< uint8_t >( pPlayer->getClass() ) ); - auto paramGrowthInfoIt = g_exdData.m_paramGrowthInfoMap.find( pPlayer->getLevel() ); + auto classInfo = g_exdDataGen.getClassJob( static_cast< uint8_t >( pPlayer->getClass() ) ); + auto paramGrowthInfo = g_exdDataGen.getParamGrow( pPlayer->getLevel() ); - if ( classInfoIt == g_exdData.m_classJobInfoMap.end() || - paramGrowthInfoIt == g_exdData.m_paramGrowthInfoMap.end() ) + if ( !classInfo || !paramGrowthInfo ) return 0; float baseStat = calculateBaseStat( pPlayer ); uint16_t piety = pPlayer->getStats().pie; - uint16_t pietyScalar = paramGrowthInfoIt->second.mp_mod; - uint16_t jobModMp = classInfoIt->second.mod_mpcpgp; - uint16_t baseMp = paramGrowthInfoIt->second.mp_const; + uint16_t pietyScalar = paramGrowthInfo->mpModifier; + uint16_t jobModMp = classInfo->modifierManaPoints; + uint16_t baseMp = paramGrowthInfo->mpModifier; uint16_t result = static_cast< uint16_t >( floor( floor( piety - baseStat ) * ( pietyScalar / 100 ) + baseMp ) * jobModMp / 100 ); diff --git a/src/servers/sapphire_zone/Network/GameConnection.cpp b/src/servers/sapphire_zone/Network/GameConnection.cpp index 396324d5..4d802fa0 100644 --- a/src/servers/sapphire_zone/Network/GameConnection.cpp +++ b/src/servers/sapphire_zone/Network/GameConnection.cpp @@ -76,17 +76,17 @@ Core::Network::GameConnection::GameConnection( Core::Network::HivePtr pHive, setZoneHandler( ClientZoneIpcType::InventoryModifyHandler,"InventoryModifyHandler", &GameConnection::inventoryModifyHandler ); - setZoneHandler( ClientZoneIpcType::TalkEventHandler, "EventHandler", &GameConnection::eventHandler ); - setZoneHandler( ClientZoneIpcType::EmoteEventHandler, "EventHandler", &GameConnection::eventHandler ); - setZoneHandler( ClientZoneIpcType::WithinRangeEventHandler, "EventHandler", &GameConnection::eventHandler ); - setZoneHandler( ClientZoneIpcType::OutOfRangeEventHandler, "EventHandler", &GameConnection::eventHandler ); - setZoneHandler( ClientZoneIpcType::EnterTeriEventHandler, "EventHandler", &GameConnection::eventHandler ); + setZoneHandler( ClientZoneIpcType::TalkEventHandler, "EventHandlerTalk", &GameConnection::eventHandlerTalk ); + setZoneHandler( ClientZoneIpcType::EmoteEventHandler, "EventHandlerEmote", &GameConnection::eventHandlerEmote ); + setZoneHandler( ClientZoneIpcType::WithinRangeEventHandler, "EventHandlerWithinRange", &GameConnection::eventHandlerWithinRange ); + setZoneHandler( ClientZoneIpcType::OutOfRangeEventHandler, "EventHandlerOutsideRange", &GameConnection::eventHandlerOutsideRange ); + setZoneHandler( ClientZoneIpcType::EnterTeriEventHandler, "EventHandlerEnterTeri", &GameConnection::eventHandlerEnterTerritory ); - setZoneHandler( ClientZoneIpcType::ReturnEventHandler, "EventHandlerReturn", &GameConnection::eventHandler ); - setZoneHandler( ClientZoneIpcType::TradeReturnEventHandler, "EventHandlerReturn", &GameConnection::eventHandler ); + setZoneHandler( ClientZoneIpcType::ReturnEventHandler, "EventHandlerReturn", &GameConnection::eventHandlerReturn ); + setZoneHandler( ClientZoneIpcType::TradeReturnEventHandler, "EventHandlerReturn", &GameConnection::eventHandlerReturn ); - setZoneHandler( ClientZoneIpcType::LinkshellEventHandler, "LinkshellEventHandler", &GameConnection::eventHandler ); - setZoneHandler( ClientZoneIpcType::LinkshellEventHandler1, "LinkshellEventHandler1", &GameConnection::eventHandler ); + setZoneHandler( ClientZoneIpcType::LinkshellEventHandler, "LinkshellEventHandler", &GameConnection::eventHandlerLinkshell ); + setZoneHandler( ClientZoneIpcType::LinkshellEventHandler1, "LinkshellEventHandler1", &GameConnection::eventHandlerLinkshell ); setZoneHandler( ClientZoneIpcType::CFDutyInfoHandler, "CFDutyInfoRequest", &GameConnection::cfDutyInfoRequest ); setZoneHandler( ClientZoneIpcType::CFRegisterDuty, "CFRegisterDuty", &GameConnection::cfRegisterDuty ); diff --git a/src/servers/sapphire_zone/Network/GameConnection.h b/src/servers/sapphire_zone/Network/GameConnection.h index 7b6a0824..55896f11 100644 --- a/src/servers/sapphire_zone/Network/GameConnection.h +++ b/src/servers/sapphire_zone/Network/GameConnection.h @@ -101,7 +101,14 @@ public: DECLARE_HANDLER( actionHandler ); DECLARE_HANDLER( inventoryModifyHandler ); DECLARE_HANDLER( discoveryHandler ); - DECLARE_HANDLER( eventHandler ); + DECLARE_HANDLER( eventHandlerTalk ); + DECLARE_HANDLER( eventHandlerEmote ); + DECLARE_HANDLER( eventHandlerWithinRange ); + DECLARE_HANDLER( eventHandlerOutsideRange ); + DECLARE_HANDLER( eventHandlerEnterTerritory ); + DECLARE_HANDLER( eventHandlerReturn ); + DECLARE_HANDLER( eventHandlerLinkshell ); + DECLARE_HANDLER( logoutHandler ); DECLARE_HANDLER( cfDutyInfoRequest ); diff --git a/src/servers/sapphire_zone/Network/Handlers/ActionHandler.cpp b/src/servers/sapphire_zone/Network/Handlers/ActionHandler.cpp index b1494413..c8bbc0f9 100644 --- a/src/servers/sapphire_zone/Network/Handlers/ActionHandler.cpp +++ b/src/servers/sapphire_zone/Network/Handlers/ActionHandler.cpp @@ -2,7 +2,7 @@ #include #include #include -#include +#include #include #include @@ -13,7 +13,6 @@ #include "Zone/Zone.h" #include "Zone/ZonePosition.h" #include "ServerZone.h" -#include "Zone/ZoneMgr.h" #include "Network/PacketWrappers/InitUIPacket.h" #include "Network/PacketWrappers/PingPacket.h" @@ -37,8 +36,7 @@ extern Core::Logger g_log; extern Core::ServerZone g_serverZone; -extern Core::ZoneMgr g_zoneMgr; -extern Core::Data::ExdData g_exdData; +extern Core::Data::ExdDataGenerated g_exdDataGen; extern Core::DebugCommandHandler g_gameCommandMgr; using namespace Core::Common; @@ -196,22 +194,21 @@ void Core::Network::GameConnection::actionHandler( const Packets::GamePacket& in player.unsetStateFlag( PlayerStateFlag::BetweenAreas ); player.unsetStateFlag( PlayerStateFlag::BetweenAreas1 ); - player.sendStateFlags(); break; } case 0xCA: // Teleport { // TODO: only register this action if enough gil is in possession - auto targetAetheryte = g_exdData.getAetheryteInfo( param11 ); + auto targetAetheryte = g_exdDataGen.getAetheryte( param11 ); if( targetAetheryte ) { - auto fromAetheryte = g_exdData.getAetheryteInfo( g_exdData.m_zoneInfoMap[player.getZoneId()].aetheryte_index ); + auto fromAetheryte = g_exdDataGen.getAetheryte( g_exdDataGen.getTerritoryType( player.getZoneId() )->aetheryte ); // calculate cost - does not apply for favorite points or homepoints neither checks for aether tickets - auto cost = static_cast< uint16_t > ( ( sqrt( pow( fromAetheryte->map_coord_x - targetAetheryte->map_coord_x, 2 ) + - pow( fromAetheryte->map_coord_y - targetAetheryte->map_coord_y, 2 ) ) / 2 ) + 100 ); + auto cost = static_cast< uint16_t > ( ( sqrt( pow( fromAetheryte->aetherstreamX - targetAetheryte->aetherstreamX, 2 ) + + pow( fromAetheryte->aetherstreamY - targetAetheryte->aetherstreamY, 2 ) ) / 2 ) + 100 ); // cap at 999 gil cost = cost > uint16_t{999} ? uint16_t{999} : cost; diff --git a/src/servers/sapphire_zone/Network/Handlers/EventHandlers.cpp b/src/servers/sapphire_zone/Network/Handlers/EventHandlers.cpp index 54875ca5..507dfb9f 100644 --- a/src/servers/sapphire_zone/Network/Handlers/EventHandlers.cpp +++ b/src/servers/sapphire_zone/Network/Handlers/EventHandlers.cpp @@ -1,4 +1,5 @@ #include +#include #include #include #include @@ -20,138 +21,192 @@ #include "Forwards.h" #include "Event/EventHelper.h" +extern Core::Data::ExdDataGenerated g_exdDataGen; extern Core::Scripting::ScriptManager g_scriptMgr; using namespace Core::Common; using namespace Core::Network::Packets; using namespace Core::Network::Packets::Server; -void Core::Network::GameConnection::eventHandler( const Packets::GamePacket& inPacket, - Entity::Player& player ) +void Core::Network::GameConnection::eventHandlerTalk( const Packets::GamePacket& inPacket, Entity::Player& player ) { - uint16_t eventHandlerId = inPacket.getValAt< uint16_t >( 0x12 ); + auto actorId = inPacket.getValAt< uint64_t >( 0x20 ); + auto eventId = inPacket.getValAt< uint32_t >( 0x28 ); + auto eventType = static_cast< uint16_t >( eventId >> 16 ); - // we need to abort the event in case it has not been scripted so the player wont be locked up - auto abortEventFunc = []( Core::Entity::Player& player, uint64_t actorId, uint32_t eventId ) + std::string eventName = "onTalk"; + std::string objName = Event::getEventName( eventId ); + + player.sendDebug( "Actor: " + + std::to_string( actorId ) + " -> " + + std::to_string( Event::mapEventActorToRealActor( static_cast< uint32_t >( actorId ) ) ) + + " \neventId: " + + std::to_string( eventId ) + + " (0x" + boost::str( boost::format( "%|08X|" ) + % static_cast< uint64_t >( eventId & 0xFFFFFFF ) ) + ")" ); + + + player.sendDebug( "Calling: " + objName + "." + eventName ); + player.eventStart( actorId, eventId, Event::EventHandler::Talk, 0, 0 ); + + if( !g_scriptMgr.onTalk( player, actorId, eventId ) && + eventType == Event::EventHandler::EventHandlerType::Quest ) { - player.queuePacket( EventStartPacket( player.getId(), actorId, eventId, 1, 0, 0 ) ); - player.queuePacket( EventFinishPacket( player.getId(), eventId, 1, 0 ) ); - // this isn't ideal as it will also reset any other status that might be active - player.queuePacket( PlayerStateFlagsPacket( player, PlayerStateFlagList{} ) ); - }; - - std::string eventIdStr = boost::str( boost::format( "%|04X|" ) % static_cast< uint32_t >( eventHandlerId & 0xFFFF ) ); - player.sendDebug( "---------------------------------------" ); - player.sendDebug( "EventHandler ( " + eventIdStr + " )" ); - - switch( eventHandlerId ) - { - - case ClientZoneIpcType::TalkEventHandler: // Talk event - { - uint64_t actorId = inPacket.getValAt< uint64_t >( 0x20 ); - uint32_t eventId = inPacket.getValAt< uint32_t >( 0x28 ); - - if( !g_scriptMgr.onTalk( player, actorId, eventId ) ) - abortEventFunc( player, actorId, eventId ); - break; + auto questInfo = g_exdDataGen.getQuest( eventId ); + if ( questInfo ) + player.sendUrgent( "Quest not implemented: " + questInfo->name + " (" + questInfo->id + ")" ); } - case ClientZoneIpcType::EmoteEventHandler: // Emote event + player.checkEvent( eventId ); + +} + +void Core::Network::GameConnection::eventHandlerEmote( const Packets::GamePacket& inPacket, Entity::Player& player ) +{ + + auto actorId = inPacket.getValAt< uint64_t >( 0x20 ); + auto eventId = inPacket.getValAt< uint32_t >( 0x28 ); + auto emoteId = inPacket.getValAt< uint16_t >( 0x2C ); + auto eventType = static_cast< uint16_t >( eventId >> 16 ); + + std::string eventName = "onEmote"; + std::string objName = Event::getEventName( eventId ); + + player.sendDebug( "Actor: " + + std::to_string( actorId ) + " -> " + + std::to_string( Event::mapEventActorToRealActor( static_cast< uint32_t >( actorId ) ) ) + + " \neventId: " + + std::to_string( eventId ) + + " (0x" + boost::str( boost::format( "%|08X|" ) + % static_cast< uint64_t >( eventId & 0xFFFFFFF ) ) + ")" ); + + player.sendDebug( "Calling: " + objName + "." + eventName ); + + player.eventStart( actorId, eventId, Event::EventHandler::Emote, 0, emoteId ); + + if( !g_scriptMgr.onEmote( player, actorId, eventId, static_cast< uint8_t >( emoteId ) ) && + eventType == Event::EventHandler::EventHandlerType::Quest ) { - uint64_t actorId = inPacket.getValAt< uint64_t >( 0x20 ); - uint32_t eventId = inPacket.getValAt< uint32_t >( 0x28 ); - uint16_t emoteId = inPacket.getValAt< uint16_t >( 0x2C ); - - std::string eventName = Event::getEventName( eventId ); - - if( !g_scriptMgr.onEmote( player, actorId, eventId, static_cast< uint8_t >( emoteId ) ) ) - abortEventFunc( player, actorId, eventId ); - break; + auto questInfo = g_exdDataGen.getQuest( eventId ); + if( questInfo ) + player.sendUrgent( "Quest not implemented: " + questInfo->name ); } + player.checkEvent( eventId ); +} - case ClientZoneIpcType::WithinRangeEventHandler: +void Core::Network::GameConnection::eventHandlerWithinRange( const Packets::GamePacket& inPacket, + Entity::Player& player ) +{ + + auto eventId = inPacket.getValAt< uint32_t >( 0x24 ); + auto param1 = inPacket.getValAt< uint32_t >( 0x20 ); + auto x = inPacket.getValAt< float >( 0x28 ); + auto y = inPacket.getValAt< float >( 0x2C ); + auto z = inPacket.getValAt< float >( 0x30 ); + + std::string eventName = "onWithinRange"; + std::string objName = Event::getEventName( eventId ); + player.sendDebug( "Calling: " + objName + "." + eventName + " - " + std::to_string( eventId ) + + " p1: " + std::to_string( param1 ) ); + + player.eventStart( player.getId(), eventId, Event::EventHandler::WithinRange, 1, param1 ); + + g_scriptMgr.onWithinRange( player, eventId, param1, x, y, z ); + + player.checkEvent( eventId ); +} + +void Core::Network::GameConnection::eventHandlerOutsideRange( const Packets::GamePacket& inPacket, + Entity::Player& player ) +{ + + auto eventId = inPacket.getValAt< uint32_t >( 0x24 ); + auto param1 = inPacket.getValAt< uint32_t >( 0x20 ); + auto x = inPacket.getValAt< float >( 0x28 ); + auto y = inPacket.getValAt< float >( 0x2C ); + auto z = inPacket.getValAt< float >( 0x30 ); + + std::string eventName = "onOutsideRange"; + std::string objName = Event::getEventName( eventId ); + player.sendDebug( "Calling: " + objName + "." + eventName + " - " + std::to_string( eventId ) + + " p1: " + std::to_string( param1 ) ); + + player.eventStart( player.getId(), eventId, Event::EventHandler::WithinRange, 1, param1 ); + + g_scriptMgr.onOutsideRange( player, eventId, param1, x, y, z ); + + player.checkEvent( eventId ); +} + +void Core::Network::GameConnection::eventHandlerEnterTerritory( const Packets::GamePacket &inPacket, + Entity::Player &player ) +{ + auto eventId = inPacket.getValAt< uint32_t >( 0x20 ); + auto param1 = inPacket.getValAt< uint16_t >( 0x24 ); + auto param2 = inPacket.getValAt< uint16_t >( 0x26 ); + + std::string eventName = "onEnterTerritory"; + + std::string objName = Event::getEventName( eventId ); + + player.sendDebug( "Calling: " + objName + "." + eventName + " - " + std::to_string( eventId ) ); + + player.eventStart( player.getId(), eventId, Event::EventHandler::EnterTerritory, 0, player.getZoneId() ); + + g_scriptMgr.onEnterTerritory( player, eventId, param1, param2 ); + + player.checkEvent( eventId ); +} + +void Core::Network::GameConnection::eventHandlerReturn( const Packets::GamePacket &inPacket, + Entity::Player &player ) +{ + auto eventId = inPacket.getValAt< uint32_t >( 0x20 ); + auto scene = inPacket.getValAt< uint16_t >( 0x24 ); + auto param1 = inPacket.getValAt< uint16_t >( 0x26 ); + auto param2 = inPacket.getValAt< uint16_t >( 0x28 ); + auto param3 = inPacket.getValAt< uint16_t >( 0x2C ); + + std::string eventName = Event::getEventName( eventId ); + + player.sendDebug( "eventId: " + + std::to_string( eventId ) + + " ( 0x" + boost::str( boost::format( "%|08X|" ) % ( uint64_t ) ( eventId & 0xFFFFFFF ) ) + " ) " + + " scene: " + std::to_string( scene ) + + " p1: " + std::to_string( param1 ) + + " p2: " + std::to_string( param2 ) + + " p3: " + std::to_string( param3 ) ); + + auto pEvent = player.getEvent( eventId ); + if( pEvent ) { - uint32_t eventId = inPacket.getValAt< uint32_t >( 0x24 ); - uint32_t eventParam1 = inPacket.getValAt< uint32_t >( 0x20 ); - float x = inPacket.getValAt< float >( 0x28 ); - float y = inPacket.getValAt< float >( 0x2C ); - float z = inPacket.getValAt< float >( 0x30 ); - - std::string eventName = Event::getEventName( eventId ); - - if( !g_scriptMgr.onWithinRange( player, eventId, eventParam1, x, y, z ) ) - abortEventFunc( player, 0, eventId ); - break; + pEvent->setPlayedScene( false ); + // try to retrieve a stored callback + auto eventCallback = pEvent->getEventReturnCallback(); + // if there is one, proceed to call it + if( eventCallback ) + eventCallback( player, eventId, param1, param2, param3 ); } - case ClientZoneIpcType::OutOfRangeEventHandler: - { - uint32_t eventId = inPacket.getValAt< uint32_t >( 0x24 ); - uint32_t eventParam1 = inPacket.getValAt< uint32_t >( 0x20 ); - float x = inPacket.getValAt< float >( 0x28 ); - float y = inPacket.getValAt< float >( 0x2C ); - float z = inPacket.getValAt< float >( 0x30 ); + player.checkEvent( eventId ); - std::string eventName = Event::getEventName( eventId ); +} - if( !g_scriptMgr.onOutsideRange( player, eventId, eventParam1, x, y, z ) ) - abortEventFunc( player, 0, eventId ); - break; - } +void Core::Network::GameConnection::eventHandlerLinkshell( const Packets::GamePacket &inPacket, + Entity::Player &player ) +{ + auto eventId = inPacket.getValAt< uint32_t >( 0x20 ); + auto scene = inPacket.getValAt< uint16_t >( 0x24 ); + auto lsName = inPacket.getStringAt( 0x27 ); - case ClientZoneIpcType::EnterTeriEventHandler: - { - uint32_t eventId = inPacket.getValAt< uint32_t >( 0x20 ); - uint16_t eventParam1 = inPacket.getValAt< uint16_t >( 0x24 ); - uint16_t eventParam2 = inPacket.getValAt< uint16_t >( 0x26 ); - - std::string eventName = Event::getEventName( eventId ); - - if( !g_scriptMgr.onEnterTerritory( player, eventId, eventParam1, eventParam2 ) ) - abortEventFunc( player, 0, eventId ); - break; - } - - case ClientZoneIpcType::ReturnEventHandler: - case ClientZoneIpcType::TradeReturnEventHandler: - { - uint32_t eventId = inPacket.getValAt< uint32_t >( 0x20 ); - uint16_t subEvent = inPacket.getValAt< uint16_t >( 0x24 ); - uint16_t param1 = inPacket.getValAt< uint16_t >( 0x26 ); - uint16_t param2 = inPacket.getValAt< uint16_t >( 0x28 ); - uint16_t param3 = inPacket.getValAt< uint16_t >( 0x2C ); - - std::string eventName = Event::getEventName( eventId ); - - if( !g_scriptMgr.onEventHandlerReturn( player, eventId, subEvent, param1, param2, param3 ) ) - abortEventFunc( player, 0, eventId ); - break; - } - - case ClientZoneIpcType::LinkshellEventHandler: - case ClientZoneIpcType::LinkshellEventHandler1: - { - uint32_t eventId = inPacket.getValAt< uint32_t >( 0x20 ); - uint16_t subEvent = inPacket.getValAt< uint16_t >( 0x24 ); - std::string lsName = inPacket.getStringAt( 0x27 ); - - ZoneChannelPacket< FFXIVIpcEventLinkshell > linkshellEvent( player.getId() ); - linkshellEvent.data().eventId = eventId; - linkshellEvent.data().scene = static_cast< uint8_t >( subEvent ); - linkshellEvent.data().param3 = 1; - linkshellEvent.data().unknown1 = 0x15a; - player.queuePacket( linkshellEvent ); - -// abortEventFunc( pPlayer, 0, eventId ); - break; - } - - } + ZoneChannelPacket< FFXIVIpcEventLinkshell > linkshellEvent( player.getId() ); + linkshellEvent.data().eventId = eventId; + linkshellEvent.data().scene = static_cast< uint8_t >( scene ); + linkshellEvent.data().param3 = 1; + linkshellEvent.data().unknown1 = 0x15a; + player.queuePacket( linkshellEvent ); } - - diff --git a/src/servers/sapphire_zone/Network/Handlers/GMCommandHandlers.cpp b/src/servers/sapphire_zone/Network/Handlers/GMCommandHandlers.cpp index 15dc09fc..d3226c3a 100644 --- a/src/servers/sapphire_zone/Network/Handlers/GMCommandHandlers.cpp +++ b/src/servers/sapphire_zone/Network/Handlers/GMCommandHandlers.cpp @@ -10,10 +10,10 @@ #include "Network/GameConnection.h" #include "Session.h" +#include "Zone/TerritoryMgr.h" #include "Zone/Zone.h" #include "Zone/ZonePosition.h" #include "ServerZone.h" -#include "Zone/ZoneMgr.h" #include "Network/PacketWrappers/InitUIPacket.h" #include "Network/PacketWrappers/PingPacket.h" @@ -37,7 +37,7 @@ extern Core::Logger g_log; extern Core::ServerZone g_serverZone; -extern Core::ZoneMgr g_zoneMgr; +extern Core::TerritoryMgr g_territoryMgr; extern Core::Data::ExdData g_exdData; extern Core::DebugCommandHandler g_gameCommandMgr; @@ -403,16 +403,27 @@ void Core::Network::GameConnection::gm1Handler( const Packets::GamePacket& inPac } case GmCommand::Teri: { - auto zoneInfo = g_zoneMgr.getZone( param1 ); - if ( !zoneInfo ) + if( auto instance = g_territoryMgr.getInstanceZonePtr( param1 ) ) + { + player.sendDebug( "Found instance: " + instance->getName() + ", id: " + std::to_string( param1 ) ); + + player.setInstance( instance ); + } + else if( !g_territoryMgr.isValidTerritory( param1 ) ) { player.sendUrgent( "Invalid zone " + std::to_string( param1 ) ); } else { + auto pZone = g_territoryMgr.getZoneByTerriId( param1 ); + if( !pZone ) + { + player.sendUrgent( "No zone instance found for " + std::to_string( param1 ) ); + break; + } targetPlayer->setPosition( targetPlayer->getPos() ); targetPlayer->performZoning( param1, targetPlayer->getPos(), 0 ); - player.sendNotice( targetPlayer->getName() + " was warped to zone " + std::to_string( param1 ) + " (" + zoneInfo->getName( ) + ")" ); + player.sendNotice( targetPlayer->getName() + " was warped to zone " + std::to_string( param1 ) + " (" + pZone->getName() + ")" ); } break; } @@ -438,7 +449,7 @@ void Core::Network::GameConnection::gm1Handler( const Packets::GamePacket& inPac player.sendNotice( "Jumping to " + targetPlayer->getName() + " in range." ); break; } - + default: player.sendUrgent( "GM1 Command not implemented: " + std::to_string( commandId ) ); break; diff --git a/src/servers/sapphire_zone/Network/Handlers/InventoryHandler.cpp b/src/servers/sapphire_zone/Network/Handlers/InventoryHandler.cpp index 3f87d2ab..752ca776 100644 --- a/src/servers/sapphire_zone/Network/Handlers/InventoryHandler.cpp +++ b/src/servers/sapphire_zone/Network/Handlers/InventoryHandler.cpp @@ -13,7 +13,6 @@ #include "Zone/Zone.h" #include "Zone/ZonePosition.h" #include "ServerZone.h" -#include "Zone/ZoneMgr.h" #include "Network/PacketWrappers/ServerNoticePacket.h" #include "Network/PacketWrappers/ActorControlPacket142.h" @@ -27,7 +26,6 @@ extern Core::Logger g_log; extern Core::ServerZone g_serverZone; -extern Core::ZoneMgr g_zoneMgr; extern Core::Data::ExdData g_exdData; extern Core::DebugCommandHandler g_gameCommandMgr; diff --git a/src/servers/sapphire_zone/Network/Handlers/PacketHandlers.cpp b/src/servers/sapphire_zone/Network/Handlers/PacketHandlers.cpp index 125104f4..3582a67f 100644 --- a/src/servers/sapphire_zone/Network/Handlers/PacketHandlers.cpp +++ b/src/servers/sapphire_zone/Network/Handlers/PacketHandlers.cpp @@ -12,10 +12,10 @@ #include "Network/GameConnection.h" #include "Session.h" +#include "ServerZone.h" +#include "Zone/TerritoryMgr.h" #include "Zone/Zone.h" #include "Zone/ZonePosition.h" -#include "ServerZone.h" -#include "Zone/ZoneMgr.h" #include "Network/PacketWrappers/InitUIPacket.h" #include "Network/PacketWrappers/PingPacket.h" @@ -41,7 +41,7 @@ extern Core::Logger g_log; extern Core::ServerZone g_serverZone; -extern Core::ZoneMgr g_zoneMgr; +extern Core::TerritoryMgr g_territoryMgr; extern Core::Data::ExdData g_exdData; extern Core::DebugCommandHandler g_gameCommandMgr; extern Core::Social::SocialMgr< Core::Social::FriendList > g_friendListMgr; @@ -299,7 +299,7 @@ void Core::Network::GameConnection::zoneLineHandler( const Packets::GamePacket& auto pZone = player.getCurrentZone(); - auto pLine = g_zoneMgr.getZonePosition( zoneLineId ); + auto pLine = g_territoryMgr.getTerritoryPosition( zoneLineId ); Common::FFXIVARR_POSITION3 targetPos{}; uint32_t targetZone; @@ -326,7 +326,7 @@ void Core::Network::GameConnection::zoneLineHandler( const Packets::GamePacket& targetPos.x = 0; targetPos.y = 0; targetPos.z = 0; - targetZone = pZone->getId(); + targetZone = pZone->getTerritoryId(); } player.performZoning( targetZone, targetPos, rotation); @@ -444,7 +444,7 @@ void Core::Network::GameConnection::socialListHandler( const Packets::GamePacket int32_t entrysizes = sizeof( listPacket.data().entries ); memset( listPacket.data().entries, 0, sizeof( listPacket.data().entries ) ); - listPacket.data().entries[0].bytes[2] = player.getCurrentZone()->getId(); + listPacket.data().entries[0].bytes[2] = player.getCurrentZone()->getTerritoryId(); listPacket.data().entries[0].bytes[3] = 0x80; listPacket.data().entries[0].bytes[4] = 0x02; listPacket.data().entries[0].bytes[6] = 0x3B; @@ -452,8 +452,8 @@ void Core::Network::GameConnection::socialListHandler( const Packets::GamePacket listPacket.data().entries[0].classJob = player.getClass(); listPacket.data().entries[0].contentId = player.getContentId(); listPacket.data().entries[0].level = player.getLevel(); - listPacket.data().entries[0].zoneId = player.getCurrentZone()->getId(); - //listPacket.data().entries[0].zoneId1 = 0x0100; + listPacket.data().entries[0].zoneId = player.getCurrentZone()->getTerritoryId(); + listPacket.data().entries[0].zoneId1 = 0x0100; // TODO: no idea what this does //listPacket.data().entries[0].one = 1; diff --git a/src/servers/sapphire_zone/Network/Handlers/SkillHandler.cpp b/src/servers/sapphire_zone/Network/Handlers/SkillHandler.cpp index 38b339c7..1240bf8c 100644 --- a/src/servers/sapphire_zone/Network/Handlers/SkillHandler.cpp +++ b/src/servers/sapphire_zone/Network/Handlers/SkillHandler.cpp @@ -1,6 +1,6 @@ #include #include -#include +#include #include #include #include @@ -32,7 +32,7 @@ extern Core::Scripting::ScriptManager g_scriptMgr; -extern Core::Data::ExdData g_exdData; +extern Core::Data::ExdDataGenerated g_exdDataGen; extern Core::Logger g_log; using namespace Core::Common; @@ -60,7 +60,7 @@ void Core::Network::GameConnection::skillHandler( const Packets::GamePacket& inP std::string actionIdStr = boost::str( boost::format( "%|04X|" ) % action ); player.sendDebug( "---------------------------------------" ); player.sendDebug( "ActionHandler ( " + actionIdStr + " | " + - g_exdData.getActionInfo( action )->name + + g_exdDataGen.getAction( action )->name + " | " + std::to_string( targetId ) + " )" ); player.queuePacket( ActorControlPacket142( player.getId(), ActorControlType::ActionStart, 0x01, action ) ); @@ -100,11 +100,11 @@ void Core::Network::GameConnection::skillHandler( const Packets::GamePacket& inP } else if( action < 3000000 ) // item action { - auto info = g_exdData.getEventItemInfo( action ); + auto info = g_exdDataGen.getEventItem( action ); if( info ) { g_log.debug( info->name ); - g_scriptMgr.onEventItem( player, action, info->eventId, info->castTime, targetId ); + g_scriptMgr.onEventItem( player, action, info->quest, info->castTime, targetId ); } } else if( action > 3000000 ) // unknown diff --git a/src/servers/sapphire_zone/Script/NativeScriptApi.h b/src/servers/sapphire_zone/Script/NativeScriptApi.h index 65d317d4..72c0fac6 100644 --- a/src/servers/sapphire_zone/Script/NativeScriptApi.h +++ b/src/servers/sapphire_zone/Script/NativeScriptApi.h @@ -2,6 +2,9 @@ #define NATIVE_SCRIPT_API #include +#include +#include + #include #include #include @@ -18,41 +21,24 @@ using namespace Core; #define EVENTSCRIPT_AETHERYTE_ID 0x50000 #define EVENTSCRIPT_AETHERNET_ID 0x50001 -enum ScriptType -{ - None, - ScriptedStatusEffect, - ScriptedAction, - ScriptedEvent, - ScriptedBattleNpc, - ScriptedZone -}; - class ScriptObject { protected: - std::string m_scriptName; uint32_t m_id; - ScriptType m_type; + std::size_t m_type; public: - ScriptObject( std::string name, uint32_t id, ScriptType type ) : - m_scriptName( name ), + ScriptObject( uint32_t id, std::size_t type ) : m_id( id ), m_type( type ) { } - virtual const std::string& getName() const - { - return m_scriptName; - } - virtual uint32_t getId() const { return m_id; } - virtual ScriptType getType() const + virtual std::size_t getType() const { return m_type; } @@ -62,8 +48,8 @@ public: class StatusEffectScript : public ScriptObject { public: - StatusEffectScript( std::string name, uint32_t effectId ) : - ScriptObject( name, effectId, ScriptType::ScriptedStatusEffect ) + StatusEffectScript( uint32_t effectId ) : + ScriptObject( effectId, typeid( StatusEffectScript ).hash_code() ) { } virtual void onTick( Entity::Actor& actor ) { } @@ -80,8 +66,8 @@ public: class ActionScript : public ScriptObject { public: - ActionScript( std::string name, uint32_t abilityId ) : - ScriptObject( name, abilityId, ScriptType::ScriptedAction ) + ActionScript( uint32_t abilityId ) : + ScriptObject( abilityId, typeid( ActionScript ).hash_code() ) { } virtual void onStart( Entity::Actor& sourceActor, Entity::Actor& targetActor ) { } @@ -93,8 +79,8 @@ public: class EventScript : public ScriptObject { public: - EventScript( std::string name, uint32_t questId ) : - ScriptObject( name, questId, ScriptType::ScriptedEvent ) + EventScript( uint32_t questId ) : + ScriptObject( questId, typeid( EventScript ).hash_code() ) { } virtual void onTalk( uint32_t eventId, Entity::Player& player, uint64_t actorId ) { } @@ -111,16 +97,16 @@ public: class BattleNpcScript : public ScriptObject { public: - BattleNpcScript( std::string name, uint32_t npcId ) : - ScriptObject( name, npcId, ScriptType::ScriptedBattleNpc ) + BattleNpcScript( uint32_t npcId ) : + ScriptObject( npcId, typeid( BattleNpcScript ).hash_code() ) { } }; class ZoneScript : public ScriptObject { public: - ZoneScript( std::string name, uint32_t zoneId ) : - ScriptObject( name, zoneId, ScriptType::ScriptedZone ) + ZoneScript( uint32_t zoneId ) : + ScriptObject( zoneId, typeid( ZoneScript ).hash_code() ) { } virtual void onZoneInit() { } diff --git a/src/servers/sapphire_zone/Script/NativeScriptManager.h b/src/servers/sapphire_zone/Script/NativeScriptManager.h index af3e256c..a793b68e 100644 --- a/src/servers/sapphire_zone/Script/NativeScriptManager.h +++ b/src/servers/sapphire_zone/Script/NativeScriptManager.h @@ -19,7 +19,7 @@ namespace Scripting { class NativeScriptManager { protected: - std::unordered_map< ScriptType, std::unordered_map< uint32_t, ScriptObject* > > m_scripts; + std::unordered_map< std::size_t, std::unordered_map< uint32_t, ScriptObject* > > m_scripts; ScriptLoader m_loader; @@ -40,11 +40,11 @@ namespace Scripting { const std::string getModuleExtension(); bool isModuleLoaded( const std::string& name ); - // todo: use some template magic (type_traits is_same?) to avoid ScriptType param - // not sure if worthwhile given that it adds an extra place where script types need to be managed template< typename T > - T* getScript( ScriptType type, uint32_t scriptId ) + T* getScript( uint32_t scriptId ) { + auto type = typeid( T ).hash_code(); + auto script = m_scripts[type].find( scriptId ); if( script == m_scripts[type].end() ) return nullptr; diff --git a/src/servers/sapphire_zone/Script/ScriptInfo.h b/src/servers/sapphire_zone/Script/ScriptInfo.h index 7ddabc18..f57c1a7c 100644 --- a/src/servers/sapphire_zone/Script/ScriptInfo.h +++ b/src/servers/sapphire_zone/Script/ScriptInfo.h @@ -26,7 +26,6 @@ namespace Scripting { ModuleHandle handle; std::vector< ScriptObject* > scripts; - ScriptType type; }; } } diff --git a/src/servers/sapphire_zone/Script/ScriptManager.cpp b/src/servers/sapphire_zone/Script/ScriptManager.cpp index 5188ae23..2467fa07 100644 --- a/src/servers/sapphire_zone/Script/ScriptManager.cpp +++ b/src/servers/sapphire_zone/Script/ScriptManager.cpp @@ -1,5 +1,5 @@ #include -#include +#include #include #include "NativeScriptManager.h" @@ -8,7 +8,7 @@ #include "Actor/Player.h" #include "Actor/BattleNpc.h" #include "ServerZone.h" -#include "Event/Event.h" +#include "Event/EventHandler.h" #include "Event/EventHelper.h" #include "StatusEffect/StatusEffect.h" #include "Network/PacketWrappers/ServerNoticePacket.h" @@ -26,7 +26,7 @@ #include extern Core::Logger g_log; -extern Core::Data::ExdData g_exdData; +extern Core::Data::ExdDataGenerated g_exdDataGen; extern Core::ServerZone g_serverZone; Core::Scripting::ScriptManager::ScriptManager() : @@ -74,6 +74,10 @@ bool Core::Scripting::ScriptManager::init() void Core::Scripting::ScriptManager::watchDirectories() { + auto shouldWatch = g_serverZone.getConfig()->getValue< bool >( "Settings.General.Scripts.HotSwap.Enabled", true ); + if( !shouldWatch ) + return; + Watchdog::watchMany( g_serverZone.getConfig()->getValue< std::string >( "Settings.General.Scripts.Path", "./compiledscripts/" ) + "*" + m_nativeScriptManager->getModuleExtension(), [ this ]( const std::vector< ci::fs::path >& paths ) { @@ -143,159 +147,63 @@ bool Core::Scripting::ScriptManager::registerBnpcTemplate( std::string templateN bool Core::Scripting::ScriptManager::onTalk( Entity::Player& player, uint64_t actorId, uint32_t eventId ) { - std::string eventName = "onTalk"; - std::string objName = Event::getEventName( eventId ); - - player.sendDebug( "Actor: " + - std::to_string( actorId ) + " -> " + - std::to_string( Event::mapEventActorToRealActor( static_cast< uint32_t >( actorId ) ) ) + - " \neventId: " + - std::to_string( eventId ) + - " (0x" + boost::str( boost::format( "%|08X|" ) - % static_cast< uint64_t >( eventId & 0xFFFFFFF ) ) + ")" ); uint16_t eventType = eventId >> 16; uint32_t scriptId = eventId; // aethernet/aetherytes need to be handled separately - if( eventType == Common::EventType::Aetheryte ) + if( eventType == Event::EventHandler::EventHandlerType::Aetheryte ) { - auto aetherInfo = g_exdData.getAetheryteInfo( eventId & 0xFFFF ); + auto aetherInfo = g_exdDataGen.getAetheryte( eventId & 0xFFFF ); scriptId = EVENTSCRIPT_AETHERYTE_ID; if( !aetherInfo->isAetheryte ) scriptId = EVENTSCRIPT_AETHERNET_ID; } - auto script = m_nativeScriptManager->getScript< EventScript >( ScriptType::ScriptedEvent, scriptId ); - if( script ) - { - player.sendDebug( "Calling: " + objName + "." + eventName ); - - player.eventStart( actorId, eventId, Event::Event::Talk, 0, 0 ); - - script->onTalk( eventId, player, actorId ); - - player.checkEvent( eventId ); - } - else - { - if ( eventType == Common::EventType::Quest ) - { - auto questInfo = g_exdData.getQuestInfo( eventId ); - if ( questInfo ) - { - player.sendUrgent( "Quest not implemented: " + questInfo->name + " (" + questInfo->name_intern + ")" ); - - } - } - + auto script = m_nativeScriptManager->getScript< EventScript >( scriptId ); + if( !script ) return false; - } - + script->onTalk( eventId, player, actorId ); return true; } bool Core::Scripting::ScriptManager::onEnterTerritory( Entity::Player& player, uint32_t eventId, uint16_t param1, uint16_t param2 ) { - std::string eventName = "onEnterTerritory"; - std::string objName = Event::getEventName( eventId ); - - player.sendDebug( "Calling: " + objName + "." + eventName + " - " + std::to_string( eventId ) ); - - auto script = m_nativeScriptManager->getScript< EventScript >( ScriptType::ScriptedEvent, eventId ); - if( script ) - { - player.eventStart( player.getId(), eventId, Event::Event::EnterTerritory, 0, player.getZoneId() ); - - script->onEnterZone( player, eventId, param1, param2 ); - - player.checkEvent( eventId ); - - return true; - } - - return false; + auto script = m_nativeScriptManager->getScript< EventScript >( eventId ); + if( !script ) + return false; + script->onEnterZone( player, eventId, param1, param2 ); + return true; } bool Core::Scripting::ScriptManager::onWithinRange( Entity::Player& player, uint32_t eventId, uint32_t param1, float x, float y, float z ) { - - std::string eventName = "onWithinRange"; - std::string objName = Event::getEventName( eventId ); - player.sendDebug( "Calling: " + objName + "." + eventName + " - " + std::to_string( eventId ) + " p1: " + std::to_string( param1 ) ); - - auto script = m_nativeScriptManager->getScript< EventScript >( ScriptType::ScriptedEvent, eventId ); - if( script ) - { - player.eventStart( player.getId(), eventId, Event::Event::WithinRange, 1, param1 ); - - script->onWithinRange( player, eventId, param1, x, y, z ); - - player.checkEvent( eventId ); - - return true; - } - - return false; + auto script = m_nativeScriptManager->getScript< EventScript >( eventId ); + if( !script ) + return false; + script->onWithinRange( player, eventId, param1, x, y, z ); + return true; } bool Core::Scripting::ScriptManager::onOutsideRange( Entity::Player& player, uint32_t eventId, uint32_t param1, float x, float y, float z ) { - std::string eventName = "onOutsideRange"; - std::string objName = Event::getEventName( eventId ); - player.sendDebug( "Calling: " + objName + "." + eventName + " - " + std::to_string( eventId ) ); - - auto script = m_nativeScriptManager->getScript< EventScript >( ScriptType::ScriptedEvent, eventId ); - if( script ) - { - player.eventStart( player.getId(), eventId, Event::Event::WithinRange, 1, param1 ); - - script->onOutsideRange( player, eventId, param1, x, y, z ); - - player.checkEvent( eventId ); - - return true; - } - - return false; + auto script = m_nativeScriptManager->getScript< EventScript >( eventId ); + if( !script ) + return false; + script->onOutsideRange( player, eventId, param1, x, y, z ); + return true; } bool Core::Scripting::ScriptManager::onEmote( Entity::Player& player, uint64_t actorId, uint32_t eventId, uint8_t emoteId ) { - std::string eventName = "onEmote"; - std::string objName = Event::getEventName( eventId ); - - auto script = m_nativeScriptManager->getScript< EventScript >( ScriptType::ScriptedEvent, eventId ); - if( script ) - { - player.sendDebug( "Calling: " + objName + "." + eventName ); - - player.eventStart( actorId, eventId, Event::Event::Emote, 0, emoteId ); - - script->onEmote( actorId, eventId, emoteId, player ); - - player.checkEvent( eventId ); - } - else - { - uint16_t eventType = eventId >> 16; - - if( eventType == Common::EventType::Quest ) - { - auto questInfo = g_exdData.getQuestInfo( eventId ); - if( questInfo ) - { - player.sendUrgent( "Quest not implemented: " + questInfo->name ); - return false; - } - } + auto script = m_nativeScriptManager->getScript< EventScript >( eventId ); + if( !script ) return false; - } - + script->onEmote( actorId, eventId, emoteId, player ); return true; } @@ -304,53 +212,16 @@ bool Core::Scripting::ScriptManager::onEventHandlerReturn( Entity::Player& playe uint16_t param3 ) { - player.sendDebug( "eventId: " + - std::to_string( eventId ) + - " ( 0x" + boost::str( boost::format( "%|08X|" ) % ( uint64_t ) ( eventId & 0xFFFFFFF ) ) + " ) " + - " scene: " + std::to_string( subEvent ) + - " p1: " + std::to_string( param1 ) + - " p2: " + std::to_string( param2 ) + - " p3: " + std::to_string( param3 ) ); - - try - { - auto pEvent = player.getEvent( eventId ); - if( pEvent ) - { - pEvent->setPlayedScene( false ); - // try to retrieve a stored callback - auto eventCallback = pEvent->getEventReturnCallback(); - // if there is one, proceed to call it - if( eventCallback ) - { - eventCallback( player, eventId, param1, param2, param3 ); - if( !pEvent->hasPlayedScene() ) - player.eventFinish( eventId, 1 ); - else - pEvent->setPlayedScene( false ); - } - // else, finish the event. - else - player.eventFinish( eventId, 1 ); - } - } - catch( std::exception& e ) - { - player.sendNotice( e.what() ); - return false; - } - - return true; + return false; } bool Core::Scripting::ScriptManager::onEventHandlerTradeReturn( Entity::Player& player, uint32_t eventId, uint16_t subEvent, uint16_t param, uint32_t catalogId ) { - auto script = m_nativeScriptManager->getScript< EventScript >( ScriptType::ScriptedEvent, eventId ); + auto script = m_nativeScriptManager->getScript< EventScript >( eventId ); if( script ) { script->onEventHandlerTradeReturn( player, eventId, subEvent, param, catalogId ); - return true; } @@ -364,13 +235,12 @@ bool Core::Scripting::ScriptManager::onEventItem( Entity::Player& player, uint32 std::string objName = Event::getEventName( eventId ); player.sendDebug( "Calling: " + objName + "." + eventName + " - " + std::to_string( eventId ) ); - auto script = m_nativeScriptManager->getScript< EventScript >( ScriptType::ScriptedEvent, eventId ); + auto script = m_nativeScriptManager->getScript< EventScript >( eventId ); if( script ) { - player.eventStart( targetId, eventId, Event::Event::Item, 0, 0 ); + player.eventStart( targetId, eventId, Event::EventHandler::Item, 0, 0 ); script->onEventItem( player, eventItemId, eventId, castTime, targetId ); - return true; } @@ -391,7 +261,7 @@ bool Core::Scripting::ScriptManager::onMobKill( Entity::Player& player, uint16_t uint16_t questId = activeQuests->c.questId; - auto script = m_nativeScriptManager->getScript< EventScript >( ScriptType::ScriptedEvent, questId ); + auto script = m_nativeScriptManager->getScript< EventScript >( questId ); if( script ) { std::string objName = Event::getEventName( 0x00010000 | questId ); @@ -407,17 +277,16 @@ bool Core::Scripting::ScriptManager::onMobKill( Entity::Player& player, uint16_t bool Core::Scripting::ScriptManager::onCastFinish( Entity::Player& player, Entity::ActorPtr pTarget, uint32_t actionId ) { - auto script = m_nativeScriptManager->getScript< ActionScript >( ScriptType::ScriptedAction, actionId ); + auto script = m_nativeScriptManager->getScript< ActionScript >( actionId ); if( script ) script->onCastFinish( player, *pTarget ); - return true; } bool Core::Scripting::ScriptManager::onStatusReceive( Entity::ActorPtr pActor, uint32_t effectId ) { - auto script = m_nativeScriptManager->getScript< StatusEffectScript >( ScriptType::ScriptedStatusEffect, effectId ); + auto script = m_nativeScriptManager->getScript< StatusEffectScript >( effectId ); if( script ) { @@ -425,7 +294,6 @@ bool Core::Scripting::ScriptManager::onStatusReceive( Entity::ActorPtr pActor, u pActor->getAsPlayer()->sendDebug( "Calling status receive for statusid: " + std::to_string( effectId ) ); script->onApply( *pActor ); - return true; } @@ -434,14 +302,13 @@ bool Core::Scripting::ScriptManager::onStatusReceive( Entity::ActorPtr pActor, u bool Core::Scripting::ScriptManager::onStatusTick( Entity::ActorPtr pActor, Core::StatusEffect::StatusEffect& effect ) { - auto script = m_nativeScriptManager->getScript< StatusEffectScript >( ScriptType::ScriptedStatusEffect, effect.getId() ); + auto script = m_nativeScriptManager->getScript< StatusEffectScript >( effect.getId() ); if( script ) { if( pActor->isPlayer() ) pActor->getAsPlayer()->sendDebug( "Calling status tick for statusid: " + std::to_string( effect.getId() ) ); script->onTick( *pActor ); - return true; } @@ -450,14 +317,13 @@ bool Core::Scripting::ScriptManager::onStatusTick( Entity::ActorPtr pActor, Core bool Core::Scripting::ScriptManager::onStatusTimeOut( Entity::ActorPtr pActor, uint32_t effectId ) { - auto script = m_nativeScriptManager->getScript< StatusEffectScript >( ScriptType::ScriptedStatusEffect, effectId ); + auto script = m_nativeScriptManager->getScript< StatusEffectScript >( effectId ); if( script ) { if( pActor->isPlayer() ) pActor->getAsPlayer()->sendDebug( "Calling status timeout for statusid: " + std::to_string( effectId ) ); script->onExpire( *pActor ); - return true; } @@ -466,11 +332,10 @@ bool Core::Scripting::ScriptManager::onStatusTimeOut( Entity::ActorPtr pActor, u bool Core::Scripting::ScriptManager::onZoneInit( ZonePtr pZone ) { - auto script = m_nativeScriptManager->getScript< ZoneScript >( ScriptType::ScriptedZone, pZone->getId() ); + auto script = m_nativeScriptManager->getScript< ZoneScript >(pZone->getTerritoryId() ); if( script ) { script->onZoneInit(); - return true; } diff --git a/scripts/native/CMakeLists.txt b/src/servers/sapphire_zone/Script/Scripts/CMakeLists.txt similarity index 100% rename from scripts/native/CMakeLists.txt rename to src/servers/sapphire_zone/Script/Scripts/CMakeLists.txt diff --git a/scripts/native/CmnDef/CmnDefCutSceneReplay.cpp b/src/servers/sapphire_zone/Script/Scripts/CmnDef/CmnDefCutSceneReplay.cpp similarity index 92% rename from scripts/native/CmnDef/CmnDefCutSceneReplay.cpp rename to src/servers/sapphire_zone/Script/Scripts/CmnDef/CmnDefCutSceneReplay.cpp index 618c1610..39bf4300 100644 --- a/scripts/native/CmnDef/CmnDefCutSceneReplay.cpp +++ b/src/servers/sapphire_zone/Script/Scripts/CmnDef/CmnDefCutSceneReplay.cpp @@ -3,7 +3,7 @@ class CmnDefCutSceneReplay : public EventScript { public: - CmnDefCutSceneReplay() : EventScript( "CmnDefCutSceneReplay", 721028 ) + CmnDefCutSceneReplay() : EventScript( 721028 ) {} void Scene00000( Entity::Player& player ) diff --git a/scripts/native/CmnDef/CmnDefInnBed.cpp b/src/servers/sapphire_zone/Script/Scripts/CmnDef/CmnDefInnBed.cpp similarity index 96% rename from scripts/native/CmnDef/CmnDefInnBed.cpp rename to src/servers/sapphire_zone/Script/Scripts/CmnDef/CmnDefInnBed.cpp index 5e675b88..ac8a0a68 100644 --- a/scripts/native/CmnDef/CmnDefInnBed.cpp +++ b/src/servers/sapphire_zone/Script/Scripts/CmnDef/CmnDefInnBed.cpp @@ -3,7 +3,7 @@ class CmnDefInnBed : public EventScript { public: - CmnDefInnBed() : EventScript( "CmnDefInnBed", 720916 ) + CmnDefInnBed() : EventScript( 720916 ) {} // menu diff --git a/scripts/native/CmnDef/CmnDefLinkShell.cpp b/src/servers/sapphire_zone/Script/Scripts/CmnDef/CmnDefLinkShell.cpp similarity index 95% rename from scripts/native/CmnDef/CmnDefLinkShell.cpp rename to src/servers/sapphire_zone/Script/Scripts/CmnDef/CmnDefLinkShell.cpp index eb2a7b29..f0df71f9 100644 --- a/scripts/native/CmnDef/CmnDefLinkShell.cpp +++ b/src/servers/sapphire_zone/Script/Scripts/CmnDef/CmnDefLinkShell.cpp @@ -7,7 +7,7 @@ class CmnDefLinkShell : public EventScript { public: - CmnDefLinkShell() : EventScript( "CmnDefLinkShell", 0xB0006 ) + CmnDefLinkShell() : EventScript( 0xB0006 ) {} void Scene00001( Entity::Player& player ) diff --git a/scripts/native/CmnDef/HouFurOrchestrion.cpp b/src/servers/sapphire_zone/Script/Scripts/CmnDef/HouFurOrchestrion.cpp similarity index 82% rename from scripts/native/CmnDef/HouFurOrchestrion.cpp rename to src/servers/sapphire_zone/Script/Scripts/CmnDef/HouFurOrchestrion.cpp index bb370e24..9e47c554 100644 --- a/scripts/native/CmnDef/HouFurOrchestrion.cpp +++ b/src/servers/sapphire_zone/Script/Scripts/CmnDef/HouFurOrchestrion.cpp @@ -3,7 +3,7 @@ class HouFurOrchestrion : public EventScript { public: - HouFurOrchestrion() : EventScript( "HouFurOrchestrion", 721226 ) + HouFurOrchestrion() : EventScript( 721226 ) {} void Scene00000( Entity::Player& player ) diff --git a/scripts/native/ScriptLoader.cpp.in b/src/servers/sapphire_zone/Script/Scripts/ScriptLoader.cpp.in similarity index 84% rename from scripts/native/ScriptLoader.cpp.in rename to src/servers/sapphire_zone/Script/Scripts/ScriptLoader.cpp.in index 633ca309..4530fb82 100644 --- a/scripts/native/ScriptLoader.cpp.in +++ b/src/servers/sapphire_zone/Script/Scripts/ScriptLoader.cpp.in @@ -1,4 +1,5 @@ #include +#include