Add read-only world boss tracking (AVA2 uitrack port)

Each game core snapshots its timed boss regens once a second and shares
them over the original HEADER_GG_RELAY addressed to "#mt_boss", so old
cores just miss the player lookup instead of dropping the P2P link.
New /mt_features query kind "bosses" (capability bit 256, mask 511)
lists the player's channel plus the shared channel 99.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
shenlei
2026-10-15 22:36:04 +09:00
co-authored by Claude Opus 5.5
parent a5293945b7
commit 400e44fae4
10 changed files with 322 additions and 5 deletions
+3 -1
View File
@@ -13,6 +13,7 @@ Request through existing CG chat command:
/mt_features 1 REQUEST stats
/mt_features 1 REQUEST dungeons
/mt_features 1 REQUEST calendar 1 OFFSET
/mt_features 1 REQUEST bosses
```
REQUEST: 1..2147483647, independent for each game session's pending command. Subject: unsigned 32-bit nonzero ID. OFFSET: 0..4096. Other versions, excess arguments, oversized tokens, signed/overflow identifiers are rejected. Queries require an own PC descriptor. Per-character throttle: 250 ms. No gameplay mutation, consumption, random draws or database write.
@@ -25,11 +26,12 @@ MTF1 begin REQUEST KIND SUBJECT OFFSET TOTAL MODE SERVER_TIME
MTF1 row REQUEST INDEX ITEM COUNT RULE MIN MAX WEIGHT GROUP_TOTAL RARE
MTF1 stat REQUEST INDEX KEY SIGNED_VALUE
MTF1 event REQUEST INDEX EVENT_ID KIND START END CHANNEL EMPIRE ACTIVE
MTF1 boss REQUEST INDEX VNUM MAP X Y CHANNEL ALIVE MAX NEXT PERIOD
MTF1 end REQUEST ROW_COUNT
MTF1 error REQUEST ERROR
```
MASK: 1 mob drops, 2 chest preview, 4 own stats, 8 item sources, 16 dungeon snapshots, 32 scheduled calendar, 64 switchbot (separate `/mt_switchbot` / `MTSB1` protocol, see FEATURE-SWITCHBOT.md). Unknown capability bits are ignored; unknown versions are rejected. Capability advertises the query implementation; missing quest/config can still return unsupported/schedule_unavailable. The client negotiates before business queries; old servers time out to unsupported, not an empty result.
MASK: 1 mob drops, 2 chest preview, 4 own stats, 8 item sources, 16 dungeon snapshots, 32 scheduled calendar, 64 switchbot (separate `/mt_switchbot` / `MTSB1` protocol, see FEATURE-SWITCHBOT.md), 256 world bosses (see FEATURE-BOSS-TRACK.md). The current mask is 511. Unknown capability bits are ignored; unknown versions are rejected. Capability advertises the query implementation; missing quest/config can still return unsupported/schedule_unavailable. The client negotiates before business queries; old servers time out to unsupported, not an empty result.
Each drop/chest/source page contains at most 8 rows, with consecutive absolute indices. TOTAL is capped at 4096; stats are one complete bounded snapshot (currently the named keys in kPortStats, less than 128). Client commits only a complete, matching begin/rows/end sequence. Unknown/stale request IDs cannot overwrite the current selection. Each line is bounded below 512 bytes; rows contain IDs and values, not server-provided script/names/markup.