mirror of
https://github.com/EQEmu/Server.git
synced 2026-04-11 21:22:31 +00:00
Don't sync character lockout uuid
Fixes regression that caused loot event apis to stop working
This commit is contained in:
parent
8b2b2db848
commit
a312cd6e1d
@ -2238,7 +2238,7 @@ void Expedition::SendMembersExpireWarning(uint32_t minutes_remaining)
|
|||||||
void Expedition::SyncCharacterLockouts(
|
void Expedition::SyncCharacterLockouts(
|
||||||
uint32_t character_id, std::vector<ExpeditionLockoutTimer>& client_lockouts)
|
uint32_t character_id, std::vector<ExpeditionLockoutTimer>& client_lockouts)
|
||||||
{
|
{
|
||||||
// adds missing event lockouts to client for this expedition and replaces
|
// adds missing event lockouts to client for this expedition and updates
|
||||||
// client timers that are both shorter and from another expedition
|
// client timers that are both shorter and from another expedition
|
||||||
BenchTimer benchmark;
|
BenchTimer benchmark;
|
||||||
|
|
||||||
@ -2265,9 +2265,10 @@ void Expedition::SyncCharacterLockouts(
|
|||||||
else if (client_lockout_iter->GetSecondsRemaining() < lockout.GetSecondsRemaining() &&
|
else if (client_lockout_iter->GetSecondsRemaining() < lockout.GetSecondsRemaining() &&
|
||||||
client_lockout_iter->GetExpeditionUUID() != m_uuid)
|
client_lockout_iter->GetExpeditionUUID() != m_uuid)
|
||||||
{
|
{
|
||||||
|
// only update lockout timer not uuid so loot event apis still work
|
||||||
modified = true;
|
modified = true;
|
||||||
client_lockouts.erase(client_lockout_iter);
|
client_lockout_iter->SetDuration(lockout.GetDuration());
|
||||||
client_lockouts.emplace_back(lockout); // replaced existing
|
client_lockout_iter->SetExpireTime(lockout.GetExpireTime());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -60,6 +60,8 @@ public:
|
|||||||
bool IsSameLockout(const ExpeditionLockoutTimer& compare_lockout) const;
|
bool IsSameLockout(const ExpeditionLockoutTimer& compare_lockout) const;
|
||||||
bool IsSameLockout(const std::string& expedition_name, const std::string& event_name) const;
|
bool IsSameLockout(const std::string& expedition_name, const std::string& event_name) const;
|
||||||
void Reset() { m_expire_time = std::chrono::system_clock::now() + m_duration; }
|
void Reset() { m_expire_time = std::chrono::system_clock::now() + m_duration; }
|
||||||
|
void SetDuration(uint32_t seconds) { m_duration = std::chrono::seconds(seconds); }
|
||||||
|
void SetExpireTime(uint64_t expire_time) { m_expire_time = std::chrono::system_clock::from_time_t(expire_time); }
|
||||||
void SetUUID(const std::string& uuid) { m_expedition_uuid = uuid; }
|
void SetUUID(const std::string& uuid) { m_expedition_uuid = uuid; }
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user