mirror of
https://github.com/SapphireServer/Sapphire.git
synced 2025-04-26 14:37:44 +00:00
Merge pull request #676 from Sophira/fix-completeflags
Fix quest completion for questId > 2047 (67583)
This commit is contained in:
commit
ef90bb0397
2 changed files with 3 additions and 3 deletions
|
@ -1070,7 +1070,7 @@ namespace Sapphire::Entity
|
||||||
uint8_t m_homePoint;
|
uint8_t m_homePoint;
|
||||||
uint8_t m_startTown;
|
uint8_t m_startTown;
|
||||||
uint16_t m_townWarpFstFlags;
|
uint16_t m_townWarpFstFlags;
|
||||||
uint8_t m_questCompleteFlags[476];
|
uint8_t m_questCompleteFlags[487];
|
||||||
uint8_t m_discovery[445];
|
uint8_t m_discovery[445];
|
||||||
uint32_t m_playTime;
|
uint32_t m_playTime;
|
||||||
|
|
||||||
|
|
|
@ -1015,7 +1015,7 @@ Sapphire::Entity::Player::sendQuestMessage( uint32_t questId, int8_t msgId, uint
|
||||||
|
|
||||||
void Sapphire::Entity::Player::updateQuestsCompleted( uint32_t questId )
|
void Sapphire::Entity::Player::updateQuestsCompleted( uint32_t questId )
|
||||||
{
|
{
|
||||||
uint8_t index = questId / 8;
|
uint16_t index = questId / 8;
|
||||||
uint8_t bitIndex = ( questId ) % 8;
|
uint8_t bitIndex = ( questId ) % 8;
|
||||||
|
|
||||||
uint8_t value = 0x80 >> bitIndex;
|
uint8_t value = 0x80 >> bitIndex;
|
||||||
|
@ -1025,7 +1025,7 @@ void Sapphire::Entity::Player::updateQuestsCompleted( uint32_t questId )
|
||||||
|
|
||||||
void Sapphire::Entity::Player::removeQuestsCompleted( uint32_t questId )
|
void Sapphire::Entity::Player::removeQuestsCompleted( uint32_t questId )
|
||||||
{
|
{
|
||||||
uint8_t index = questId / 8;
|
uint16_t index = questId / 8;
|
||||||
uint8_t bitIndex = ( questId ) % 8;
|
uint8_t bitIndex = ( questId ) % 8;
|
||||||
|
|
||||||
uint8_t value = 0x80 >> bitIndex;
|
uint8_t value = 0x80 >> bitIndex;
|
||||||
|
|
Loading…
Add table
Reference in a new issue