Skip to content

fix: accept CMaNGOS 0x6000 elevator and tram guids - #592

Merged
Xian55 merged 1 commit into
masterfrom
fix/cmangos-elevator-guid-high
Nov 10, 2026
Merged

Xian55 merged 1 commit into
masterfrom
fix/cmangos-elevator-guid-high

Conversation

@Xian55

@Xian55 Xian55 commented Nov 10, 2026

Copy link
Copy Markdown
Owner

Summary

  • CMaNGOS classic numbers elevators and trams (gameobject type 11) with the guid high 0x6000 since mangos-classic 85e06ac9d (2026-11-06), one commit after the ship change of fix: accept CMaNGOS 0x8000 MO_TRANSPORT guids #590. Before it they went out as plain gameobjects, 0xF110.
  • The proxy did not know 0x6000. It logged Unknown legacy high-guid 0x6000 for each of them and then threw NullReferenceException in StoreObjectUpdateInternal. The update packet the elevator came in was lost whole: the shaft stayed empty, and everything else in that packet was missing too.
  • 0x6000 now maps to a transport, beside 0xF120.
  • On the way back to the server the guid carries the high the server sent. LegacyTransportGuidHigh keeps it, the way LegacyMoTransportGuidHigh does for ships. It follows the last high seen, so one proxy serves a server from either side of that commit, with no setting. The default stays 0xF120 for every other core, and an older CMaNGOS classic keeps its elevators as gameobjects.

Test plan

  • dotnet test -c Release: all passed. New tests cover the mapping, the round trip in both highs, a change of high under a running proxy, an elevator and a ship from the same server, an elevator sent as a plain gameobject, and the create that threw, through the real handler. That last test fails with the exception above when the mapping is taken out.
  • The movement tests under all six build pairs: passed.
  • 1.14.2 on a CMaNGOS classic that uses 0x6000, the Undercity lift: the character rides from the shaft floor to the top and back, and the server reports it aboard the lift. The moves sent from the platform carry 0x6000.
  • The same server before the fix: Unknown legacy high-guid 0x6000 ten times, one NullReferenceException on a 3.5 kB update packet, no lift, and the character never leaves the shaft floor.
  • Control, lift created but its guid sent back as 0xF120 to that server: the client rides, the server never takes the character aboard. So both directions are needed.
  • 1.14.2 on a CMaNGOS classic from before the commit (0xF110): the same ride passes, before and after this change, and the moves carry 0xF110.
  • A boat ride from Menethil Harbor to Theramore on the 0x6000 server (ships are 0x8000 there): still passes.
  • The Deeprun Tram: not run. It is the same gameobject type and takes the same path.
  • VMaNGOS, 2.5 and 3.4.3 clients: not run. Their elevators arrive as 0xF120, which is still the default.

The local 0x6000 server is an older CMaNGOS classic with the two guid commits applied, not a full upstream build.

The progress pages were regenerated and did not change.

Refs #590

🤖 Generated with Claude Code

CMaNGOS classic numbers elevators and trams (gameobject type 11) with
the guid high 0x6000 since mangos-classic 85e06ac9d (2026-11-06), one
commit after the ship change of #590. Before it they went out as plain
gameobjects, 0xF110. The proxy did not know 0x6000: each one became a
null guid, logged "Unknown legacy high-guid 0x6000", and the create
then threw NullReferenceException in StoreObjectUpdateInternal. The
update packet it came in was lost whole, so the shaft stayed empty and
everything else in that packet was missing too.

0x6000 now maps to a transport, beside 0xF120. On the way back the guid
is rebuilt with the high the server sent, which LegacyTransportGuidHigh
keeps the way LegacyMoTransportGuidHigh does for ships. It follows the
last high seen, so one proxy serves a server from either side of the
commit with no setting. The default stays 0xF120 for every other core,
and an older CMaNGOS classic keeps its elevators as gameobjects.

Verified with a 1.14.2 client on the Undercity lift, on a CMaNGOS
classic built from each side of the commit: the character rides from
the shaft floor to the top and back, and the server reports it aboard
the lift. The moves sent from the platform carry 0x6000 on the one
server and 0xF110 on the other. Without the fix the 0x6000 server shows
no lift and the character never leaves the floor. With the lift created
but its guid still sent back as 0xF120, the client rides and the server
never takes the character aboard. A boat ride on the 0x6000 server
still passes.

Refs #590

Co-Authored-By: Claude <noreply@anthropic.com>
@Xian55 Xian55 added bugfix A fix has been proposed or merged for this reported bug ai Artificial Intelligence contribution cmangos cmangos server labels Nov 10, 2026
@Xian55

Xian55 commented Nov 10, 2026

Copy link
Copy Markdown
Owner Author

Proof

A 1.14.2 client on the Undercity lift (gameobject 20649), against two builds of CMaNGOS classic: one that numbers elevators 0x6000, and one from before that commit, which sends them as plain gameobjects (0xF110).

The character stands on the shaft floor and takes a small step every second or so for about 50 seconds, three rounds of the lift. Every 1.5 s the server is asked where it has the character (.gps): its height, and whether it adds a Transport coords: line, which it prints only for a passenger. The last column is counted in the capture of what the proxy sent to the server.

Server Proxy Ride (server height) Server has the character aboard Moves to the server carry
0x6000 before this PR no lift, stays at -41.4 no (0 of 34 answers) no lift guid at all
0x6000 this PR -41.4 to 55.1 yes (33 of 34) 0x6000, 81 packets
0x6000 control: lift created, guid sent back as 0xF120 -41.4 to 55.1 no (0 of 34) 0xF120, 71 packets
0xF110 before this PR -41.4 to 55.1 yes (30 of 34) 0xF110, 73 packets
0xF110 this PR -41.4 to 55.1 yes (32 of 34) 0xF110, 79 packets

What the rows say:

  • Row 1 is the bug. The proxy logged Unknown legacy high-guid 0x6000 ten times and threw one NullReferenceException on a 3.5 kB update packet. The shaft was empty and the character never left the floor.
  • Row 2 is the fix. The proxy logged [TransportGuid] Backend uses high-guid 0x6000 for elevators and trams; rebuilding their guids with it. once, and nothing else.
  • Row 3 is why the way back matters. With only the create fixed, the client has a lift and rides it, but the server does not know the guid it is told about and never takes the character aboard.
  • Rows 4 and 5 are the older server. It worked before and works the same now.

Also on the 0x6000 server, where ships are 0x8000: a boat ride from Menethil Harbor to Theramore, across the map change, still passes with this PR.

Not run: the Deeprun Tram, and VMaNGOS, 2.5 and 3.4.3 clients.

The 0x6000 server here is an older CMaNGOS classic with the two guid commits applied, not a full upstream build.

@Xian55
Xian55 merged commit 6b9329b into master Nov 10, 2026
5 checks passed
@Xian55
Xian55 deleted the fix/cmangos-elevator-guid-high branch November 10, 2026 13:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ai Artificial Intelligence contribution bugfix A fix has been proposed or merged for this reported bug cmangos cmangos server

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant