Search Issue Tracker
By Design
Votes
0
Found in [Package]
tools-2.1.0
Issue ID
MTTB-1492
Regression
No
Network Simulator 'Disconnected' state does not persist on Reconnect attempt
Reproduction steps:
1. Open the attached “IN-106120” project
2. Open the “Scenes/Startup” Scene
3. Use “Client” Play Mode Scenario and enter the Play Mode
4. Select the “Network Simulator” GameObject in the Hierarchy window
5. Select “Connection” option to be “Disconnected” under the “Network Simulator” component in the Inspector window
6. Wait till the game disconnects you
7. In the Game View, press the “Connect” button to reconnect to the server
Expected result: Reconnect logic fails as-if there were no internet connection
Actual result: Player reconnects successfully
Reproducible with: 1.1.0, 2.2.6 (6000.0.55f1, 6000.1.16f1, 6000.2.0f1, 6000.3.0a4)
Couldn’t test with: 1.0.0 (6000.0.55f1, 6000.1.16f1, 6000.2.0f1, 6000.3.0a4) - NetworkSimulator is not available
Reproducible on: Windows 11, Windows 10
Not reproducible on: No other environments tested
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- UI Builder Data Path Source List starts flickering and scrolling when trying to select the last item in the list
- Crash on ProcessSceneBeforeExport when analyzing selected Addressables rules in a specific project
- HDR images are compressed incorrectly with default settings on Android Platform
- Crash with multiple stack traces when painting detail on Terrain with a highly detailed Prefab
- Crash on mono_object_handle_isinst_mbyref_raw when SerializedReference points to a struct implementing ISerializationCallbackReceiver whose first field is a UnityEngine.Object
Resolution Note:
The behavior you are observing is the Network Simulator working as expected.
Here’s a breakdown of what is happening:
The Network Simulator is not a firewall, it functions by modifying the parameters of the SimulatorLayer within the active NetworkDriver instance in the Unity Transport.
When you set the Network Simulator to disconnected, it sets the packet loss for that specific connection to 100%, effectively simulating a dropped connection.
However, when your reconnect logic calls NetworkManager.StartClient(), that call establishes a fresh connection, which involves creating and initializing a new NetworkDriver.
This new driver is initialized with default simulation settings and, therefore, does not retain the 100% packet loss configuration from the previous driver instance.
In short, the Network Simulator's disconnect setting is tied to the current, active connection and is not a persistent, editor-wide state. It is not designed to simulate a complete and persistent loss of the machine's network interface.