Search Issue Tracker
By Design
Votes
0
Found in
5.4.0f3
Issue ID
845453
Regression
No
[Command] functions used by Invoke are called locally
Reproduction steps:
1. Open project attached.
2. Open scene "Main" from folder "Scene".
3. Make 2 game clients:
3.1. First one by using Build and Run.
3.2. Second - by entering Play Mode.
4. Join together:
4.1. With first one press LAN Host(H)
4.2. With second - press LAN Client(C)
5. On second client try to shoot by pressing left mouse button.
Expected result: bullets will appear on server.
Actual result: bullets is only created on Client, error: "NetworkServer is not active. Cannot spawn objects without an active server."
There are 2 workarounds:
First: instead of calling Invoke("CmdShoot") call Invoke("CallCmdShoot") - which is the generated method.
Second one: Use simple method calling instead of Invoke().
This is how to do it in this project:
1. Go to: Scripts -> Controls -> PlayerController.cs
2. Comment line 21, uncomment line 22;
3. Repeat reproduction 3 - 5 steps.
Reproducible on: 5.3.0f4, 5.4.0f3, 5.4.2f2, 5.5.0b9.
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Profiler - Taking you to the wrong section when using 'show'
- Draw Renderers custom pass doesn't work with SSGI
- WebCamTexture does not set the requested resolution when used in WebGL
- Editor default Stylesheet/Matching Selector buttons in Debugger don't do anything
- Graphics.DrawMeshNow stops rendering Render Texture after a few frames when viewed in the Player
Add comment