mirror of
https://github.com/SapphireServer/Sapphire.git
synced 2025-04-29 07:37:45 +00:00
Fixed quest state breaking on zoning, fixed some formatting issues in some quests, more are still messed up though
This commit is contained in:
parent
083ce1d5f2
commit
90018d0137
9 changed files with 196 additions and 187 deletions
|
@ -42,7 +42,9 @@ class SubFst001 : public Sapphire::ScriptAPI::QuestScript
|
|||
static constexpr auto Seq1Actor1Npctradeok = 100;
|
||||
|
||||
public:
|
||||
SubFst001() : Sapphire::ScriptAPI::QuestScript( 65560 ){};
|
||||
SubFst001() : Sapphire::ScriptAPI::QuestScript( 65560 )
|
||||
{};
|
||||
|
||||
~SubFst001() = default;
|
||||
|
||||
//////////////////////////////////////////////////////////////////////
|
||||
|
|
|
@ -42,7 +42,9 @@ class SubFst003 : public Sapphire::ScriptAPI::QuestScript
|
|||
static constexpr auto Seq1Actor1Npctradeok = 100;
|
||||
|
||||
public:
|
||||
SubFst003() : Sapphire::ScriptAPI::QuestScript( 65562 ){};
|
||||
SubFst003() : Sapphire::ScriptAPI::QuestScript( 65562 )
|
||||
{};
|
||||
|
||||
~SubFst003() = default;
|
||||
|
||||
//////////////////////////////////////////////////////////////////////
|
||||
|
|
|
@ -37,7 +37,9 @@ class SubFst005 : public Sapphire::ScriptAPI::QuestScript
|
|||
static constexpr auto Seq1Actor1 = 1;
|
||||
|
||||
public:
|
||||
SubFst005() : Sapphire::ScriptAPI::QuestScript( 65564 ){};
|
||||
SubFst005() : Sapphire::ScriptAPI::QuestScript( 65564 )
|
||||
{};
|
||||
|
||||
~SubFst005() = default;
|
||||
|
||||
//////////////////////////////////////////////////////////////////////
|
||||
|
|
|
@ -46,7 +46,9 @@ class SubFst008 : public Sapphire::ScriptAPI::QuestScript
|
|||
static constexpr auto Seq2Actor2Npctradeok = 100;
|
||||
|
||||
public:
|
||||
SubFst008() : Sapphire::ScriptAPI::QuestScript( 65568 ){};
|
||||
SubFst008() : Sapphire::ScriptAPI::QuestScript( 65568 )
|
||||
{};
|
||||
|
||||
~SubFst008() = default;
|
||||
|
||||
//////////////////////////////////////////////////////////////////////
|
||||
|
|
|
@ -114,7 +114,7 @@ namespace Sapphire::Entity
|
|||
int16_t getQuestTracking( uint8_t index ) const;
|
||||
|
||||
/*! finish a given quest */
|
||||
void finishQuest( uint16_t questId );
|
||||
void finishQuest( uint16_t questId, uint8_t optionalChoice = 0 );
|
||||
|
||||
/*! finish a given quest */
|
||||
void unfinishQuest( uint16_t questId );
|
||||
|
|
|
@ -17,7 +17,7 @@ using namespace Sapphire::Common;
|
|||
using namespace Sapphire::Network::Packets;
|
||||
using namespace Sapphire::Network::Packets::WorldPackets::Server;
|
||||
|
||||
void Sapphire::Entity::Player::finishQuest( uint16_t questId )
|
||||
void Sapphire::Entity::Player::finishQuest( uint16_t questId, uint8_t optionalChoice )
|
||||
{
|
||||
removeQuest( questId );
|
||||
|
||||
|
@ -183,7 +183,7 @@ bool Sapphire::Entity::Player::giveQuestRewards( uint32_t questId, uint32_t opti
|
|||
uint32_t exp =
|
||||
( questInfo->data().Reward.ExpBonus * paramGrowth->data().EventExpRate * ( 45 + 5 * questInfo->data().ClassLevel ) ) / 100;
|
||||
|
||||
exp = questInfo->data().Reward.ExpBonus;
|
||||
//exp = questInfo->data().Reward.ExpBonus;
|
||||
|
||||
//auto rewardItemCount = questInfo->data().Reward.itemReward0.size();
|
||||
//uint16_t optionalItemCount = static_cast< uint16_t >( questInfo->itemReward1.size() );
|
||||
|
|
|
@ -350,10 +350,10 @@ void Sapphire::Network::GameConnection::zoneJumpHandler( const Packets::FFXIVARR
|
|||
pPopRange->header.transform.rotation.z,
|
||||
rotation );
|
||||
|
||||
auto preparePacket = makeZonePacket< FFXIVIpcPrepareZoning >( player.getId() );
|
||||
preparePacket->data().targetZone = pExitRange->data.destTerritoryType;
|
||||
// auto preparePacket = makeZonePacket< FFXIVIpcPrepareZoning >( player.getId() );
|
||||
// preparePacket->data().targetZone = pExitRange->data.destTerritoryType;
|
||||
|
||||
server.queueForPlayer( player.getCharacterId(), preparePacket );
|
||||
//server.queueForPlayer( player.getCharacterId(), preparePacket );
|
||||
|
||||
}
|
||||
}
|
||||
|
@ -414,9 +414,12 @@ void Sapphire::Network::GameConnection::syncHandler( const Packets::FFXIVARR_PAC
|
|||
|
||||
void Sapphire::Network::GameConnection::setLanguageHandler( const Packets::FFXIVARR_PACKET_RAW& inPacket,
|
||||
Entity::Player& player )
|
||||
{
|
||||
if( player.isLogin() )
|
||||
{
|
||||
auto &questMgr = Common::Service< World::Manager::QuestMgr >::ref();
|
||||
questMgr.sendQuestsInfo( player );
|
||||
}
|
||||
|
||||
auto& playerMgr = Common::Service< World::Manager::PlayerMgr >::ref();
|
||||
|
||||
|
|
|
@ -258,8 +258,6 @@ void Sapphire::World::WorldServer::run( int32_t argc, char* argv[] )
|
|||
Common::Service< Manager::BlacklistMgr >::set( pBlacklistMgr );
|
||||
Common::Service< ContentFinder >::set( contentFinder );
|
||||
|
||||
auto& exdData = Common::Service< Sapphire::Data::ExdData >::ref();
|
||||
|
||||
Logger::info( "World server running on {0}:{1}", m_ip, m_port );
|
||||
|
||||
mainLoop();
|
||||
|
|
Loading…
Add table
Reference in a new issue