Don't send client replicated CVars when not connected to a server

This commit is contained in:
PJB3005
2025-09-16 18:56:52 +02:00
parent 51bbc5dc45
commit 0c691b061d
2 changed files with 2 additions and 1 deletions

View File

@@ -46,6 +46,7 @@ END TEMPLATE-->
### Bugfixes
* Fixed `Matrix3Helpers.TransformBounds()` returning an incorrect result. Now it effectively behaves like `Matrix3Helpers.TransformBox()` and has been marked as obsolete.
* The client no longer tries to send `CLIENT | REPLICATED` CVars when not connected to a server. This could cause test failures.
### Other

View File

@@ -71,7 +71,7 @@ internal sealed class ClientNetConfigurationManager : NetConfigurationManager, I
// Actually set the CVar
base.SetCVar(name, value, force);
if ((flags & CVar.REPLICATED) == 0)
if ((flags & CVar.REPLICATED) == 0 || !NetManager.IsConnected)
return;
var msg = new MsgConVars();