mirror of
https://git.huckle.dev/Huckles-Minecraft-Archive/LCE-Revelations.git
synced 2026-06-15 06:01:57 +00:00
fix: player list no longer limited by render distance
The previous IQNet cleanup in handleRemoveEntity fired on every entity despawn, which happens both when a player goes out of tracking range and when they disconnect. This caused players to vanish from the Tab list whenever they moved beyond render distance. Introduce two custom payload channels (MC|ForkHello, MC|ForkPLeave) so the client can distinguish "out of range" from "actually left": - Server sends MC|ForkHello during login to identify itself as a fork - Server sends MC|ForkPLeave with the player's gamertag on disconnect - Client skips IQNet cleanup in handleRemoveEntity on fork servers - Client cleans up IQNet only when MC|ForkPLeave arrives Fully backwards-compatible: no existing packet wire formats changed. Upstream clients ignore the unknown channels, fork clients on upstream servers fall back to the old entity-tracking-based cleanup.
This commit is contained in:
@@ -22,6 +22,9 @@ const wstring CustomPayloadPacket::IDENTITY_TOKEN_ISSUE = L"MC|CTIssue";
|
||||
const wstring CustomPayloadPacket::IDENTITY_TOKEN_CHALLENGE = L"MC|CTChallenge";
|
||||
const wstring CustomPayloadPacket::IDENTITY_TOKEN_RESPONSE = L"MC|CTResponse";
|
||||
|
||||
const wstring CustomPayloadPacket::FORK_HELLO_CHANNEL = L"MC|ForkHello";
|
||||
const wstring CustomPayloadPacket::FORK_PLAYER_LEAVE_CHANNEL = L"MC|ForkPLeave";
|
||||
|
||||
CustomPayloadPacket::CustomPayloadPacket()
|
||||
: length(0)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user