mirror of
https://github.com/EQEmu/Server.git
synced 2026-06-11 15:58:36 +00:00
Let world shutdown dz early for empty expeditions
Since world now tracks empty expeditions it can determine when to shutdown dynamic zone instances when the rule is enabled rather than letting zones do it.
This commit is contained in:
@@ -395,25 +395,6 @@ ExpeditionMember ExpeditionDatabase::GetExpeditionLeader(uint32_t expedition_id)
|
||||
return leader;
|
||||
}
|
||||
|
||||
uint32_t ExpeditionDatabase::GetExpeditionMemberCount(uint32_t expedition_id)
|
||||
{
|
||||
auto query = fmt::format(SQL(
|
||||
SELECT COUNT(IF(is_current_member = TRUE, 1, NULL)) member_count
|
||||
FROM expedition_members
|
||||
WHERE expedition_id = {};
|
||||
), expedition_id);
|
||||
|
||||
auto results = database.QueryDatabase(query);
|
||||
|
||||
uint32_t member_count = 0;
|
||||
if (results.Success() && results.RowCount() > 0)
|
||||
{
|
||||
auto row = results.begin();
|
||||
member_count = static_cast<uint32_t>(strtoul(row[0], nullptr, 10));
|
||||
}
|
||||
return member_count;
|
||||
}
|
||||
|
||||
void ExpeditionDatabase::InsertCharacterLockouts(
|
||||
uint32_t character_id, const std::vector<ExpeditionLockoutTimer>& lockouts,
|
||||
bool update_expire_times, bool is_pending)
|
||||
|
||||
Reference in New Issue
Block a user