4,936 Commits over 1,461 Days - 0.14cph!
Fix hostname changing back to default after map change
Some refactoring, use SnapshotState to store last received snapshot - only updating from the ack if snapshot id is newer than the last one
Batch network spawn messages when cloning / network spawning an object so that references to/from child networked objects are kept intact when spawning on the receiving end
Fixed right click to show cursor on Scoreboard making weapons shoot. Added Mute/Unmute to player menu in Scoreboard and MuteableVoice component.
Added VoiceComponent.ShouldHearVoice( Connection ) - to change whether a voice can be heard on the receiving end
Fixed a bug where the parent network object could be destroyed when doing a network refresh if there were children to prune (Fixes Facepunch/sbox-issues#7812)
Game.Close will no longer NRE when called from Dedicated Server - will exit the whole application instead (Fixes Facepunch/sbox-issues#7781)
Use target local for delta snapshot transform and when reconstructing on the other side
Don't process incoming transform update if predicted and we own it (handle reconciliation later?)
SyncFlags.Predicted. go.Network.Predicted
Update messages sent and messages received on connection for dedicated server as well
Pass recipient SteamId from native to managed OnSessionFailed. Update debug log to show that connection if we can find it, or just log the steam id if we can't
Get MessagesReceived working for Connections so it displays in status properly - to help debug an issue
Connection.Ping is in milliseconds
Log instead of disconnect on invalid session for now for debugging
Separate slots for Pos,Rot,Scale
Make sure when sending snapshot before owner change that its a full one not a partial one
Update protocol, snapshot in refresh, cleanup
Add channel / connection state to status ConCmd output
Optimizing bandwidth with direct snapshot messages, tests involving byte serialization deltas for snapshots. Lots of stuff, further work needed to further reduce bandwidth on stress test
Fixed a rare scenario where it was possible to store a last received snapshot that may never have been actually received
Branch to test trying to gracefully sending final snapshots for owned objects when disconnecting
Update logic in PlayerInventory.DropCoffin and do a network refresh on the carryables after we set Enabled to false
Ensure we only process snapshot clusters if the sending connection has control / owns the object. Update refresh message snapshot id check to use latest logic.
Update SnapshotState check for newer incoming snapshot packet to properly handle wraparound on snapshot id
Server/Lobby Data, Hostname / ServerName Changes, etc (#1827)
Exposes:
* Networking.ServerName
* Networking.MapName
* Networking.SetData
* Networking.GetData
Fix naming of internal DedicatedServer method
Fix mistake in Networking.CreateLobby - return early again if IsActive
Rename to Networking.SetData/GetData. Make Networking.Metadata internal, it wasn't supposed to be exposed. Add some extra documentation to Networking.SetData.
Change terminology elsewhere to match
Add support for map name - but have the setter internal now, keep it set automatically - remove old HostInfo that previously handled it so we dont have two different systems for this kind of thing
Redo everything. Implement handling of server name, metadata on sockets. Add Networking.ServerName, Networking.MaxPlayers, Networking.SetMetadata and Networking.GetMetadata. Make "hostname" a ConCmd instead of a ConVar, it just sets/changes Networking.ServerName and is admin-only.
Log a warning instead of throwing an exception when trying to send an RPC without being connected to a network session - it's harmless anyway and could happen with async tasks even after disconnecting
Groundwork for active lobby info and get / set metadata for lobbies. Dedicated server, tcp and p2p support
CreateLobby async returns active lobby
Fixes
Protocol++
Track object messages and RPC stats and display the top 10 in the top left when net_debug is enabled
Keep everything nicely contained in NetworkDebugSystem
Show top 10 object messages by total calls then by total bytes received in top left when net_debug is true ( https://files.facepunch.com/conna/1b1911b1/sbox_OEOfBa3MKH.png )
Start by storing incoming RPCs by name, increment total calls, total size, and build an average message size
Track other messages too like spawn and destroy messages and their frequency. Add a temporary command to log the top 10
Connection.GetUserData will now work for any client - not just the host. ConVars marked with ConVarFlags.UserInfo will update for all clients when changed. Updated ConnectionInfo string table to store values individually so when one changes it doesn't send the whole lot again.
We can now include ping in the string table so that Connection.Ping should be correct even if you aren't the host
Track other messages too like spawn and destroy messages and their frequency. Add a temporary command to log the top 10
Start by storing incoming RPCs by name, increment total calls, total size, and build an average message size
Show progress (#/#) when downloading files in loading screen
Shut down properly before reconnecting - ensure we've destroyed the scene etc
CreateLobby async returns active lobby