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
- Mono Windows Builds don't produce full log callstacks when generating logs
- AssetBundles fail to load when running in Built Players for Mobile Devices
- UI elements with text gets bigger and grey when Player window is moved to another screen with different resolution
- System name accepts multiline text but crops it on confirmation, duplicates input, and shrinks the field when empty
- UI element scale and position are wrong in project build when DRS is changed with HDR and Software Dynamic Resolution enabled
Add comment