feat(master): outdated instances take nobody new and stop once empty

Instances on an old binary or old zone files are marked outdated: routing,
private passwords and merges skip them. Outdated properties remind their
players every 10 minutes that an update is waiting (ANNOUNCE) and stop once
empty. A new instance of the same property waits for the old one to be gone
before its world server starts, so two worlds never save one property.
The server list carries the flag after the endpoints (read when present).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Aaron Kimbrell
2026-09-30 04:03:15 -05:00
parent c6831ac80e
commit 8f891229e6
9 changed files with 327 additions and 9 deletions

View File

@@ -158,6 +158,7 @@ namespace {
entry.isPrivate = inst->GetIsPrivate() ? 1 : 0;
entry.state = inst->GetIsShuttingDown() ? eState::STOPPING : !inst->GetIsReady() ? eState::STARTING :
inst->GetIsDraining() ? eState::DRAINING : eState::READY;
entry.outdated = inst->GetIsOutdated() ? 1 : 0;
auto& endpoint = response.endpoints.emplace_back();
endpoint.type = ServiceType::WORLD;
endpoint.zoneID = entry.mapID;
@@ -632,6 +633,8 @@ int main(int argc, char** argv) {
LiveUpdateCoordinator::Update();
CDClientReloader::Update();
WorldReloader::Update();
// Instances on an old binary or old zone files: reminders on properties, and stopping empty ones
Game::im->UpdateOutdatedInstances();
CheckPlayerActionTimeouts();
// Spare instances for busy zones (zone_limits), checked every few seconds