Search Issue Tracker
Postponed means that the issue was either a feature request or something that requires major refactoring on our side. Since that makes the issue not actionable in the close future we choose to close it as Postponed and add it on our internal roadmaps and technical debt pages instead.
Postponed
Votes
1
Found in
5.3.6p2
Issue ID
822355
Regression
No
SyncVar hook isn't called most of the time if SyncVar value is changed during scene change
Steps to reproduce:
1. Open attached project
2. Build and run project as host
3. In editor, open scene "SceneStart" and run it
4. Connect to chost
5. Return to build and start spamming "Enter scene 1"
6. In client (editor) notice that not all SyncVar changes are called
Reproduced with: 5.3.6p2, 5.4.0p1, 5.5.0a5
Comments (2)
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
- Blank, Light-Themed "Create Node" window becomes visible on the next project open
- UI Elements/Layout inconsistencies in the Particle System component
- The Game view and Scene view fail to render when launching the Editor with a maximized Render Graph Viewer window
- "List is empty" is poorly visible in the "Create Node" window
- [Android] GameObject with a custom shader becomes invisible when deployed with the Vulkan Graphics API
Zullar
Sep 19, 2016 13:51
The SyncVar hook bug is also likely related to this bug.
https://fogbugz.unity3d.com/default.asp?831893_63262uhermqgeju4
Zullar
Aug 12, 2016 21:16
OnSerialize (with initialState=true) is sent on a scene change to all persistent DontDestroyOnLoad networked objects. I believe this is how the SyncVar value is changing on the client, without the hook being called. It appears that persistent DontDestroyOnLoad networked objects are being treated as new network scene objects and "spawned" when the new scene is loaded.