Repository navigation
feat(host): expose FakeIP UDP ports, the game server FakeIP request and networking diagnostics - #4
Merged
Merged
Conversation
…nd networking diagnostics Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Host mode gains what an engine needs for Steam FakeIP datagrams. It mirrors the HL25 GoldSrc engine (
hw.so), which sends to FakeIPs from client and listen-server fake UDP ports. Needed for HLND2T/HLND2T-DiligentGraphics#704.API (
include/SteamAPIBridge.h)SteamBridge_FakeUDPPortCreate/Destroycreate and destroy an opaque port on the client session (SteamNetworkingSockets013 of the user) or on the game server session (of the game server).fakeServerPortis the fake port index, or-1. A session's shutdown destroys the ports it still holds.SteamBridge_FakeUDPPortSendreturns the SteamEResult.SteamBridge_FakeUDPPortReceivetakes one message, copies it out and releases it. It reports the sender as IPv4 and port in host order.SB_FAKE_UDP_TOO_LARGE/SB_FAKE_UDP_NOT_IP, with Steam's text for the peer.SteamBridge_FakeUDPPortScheduleCleanup.SteamBridge_IsFakeIPv4checks an address.SteamBridge_NetworkingSetDebugOutputforwards SteamNetworkingSockets diagnostics to a C callback.SteamBridge_ServerBeginAsyncRequestFakeIPandSteamBridge_ServerGetFakeIPrequest and query the FakeIP.SteamNetworkingFakeIPResult_tnow reaches the server callback asSB_SERVER_FAKE_IP_RESULT, with theEResultinresult.Port send, receive and cleanup may run on any thread while the port exists, so an engine's network thread can poll a port. Creation and destruction stay on the host's main thread. No Steam object crosses the ABI.
Tests
tests/HostStubs.hgains empty SteamNetworkingSockets013 and SteamNetworkingUtils004 implementations, generated from the SDK v1.65 declarations like the existing stubs.SteamBridge.Hostcovers:Verification
-m32)clang-format 23.1.3:
format-checkreports 0 differences.Simulated only. FakeIP traffic over the Steam relay is not verified here: it needs a running Steam client, and a second Steam account to receive. It will be checked through the engine.
🤖 Generated with Claude Code