Description
On the network animator component. There is this check in the send animation functions:
if (NetworkManager.ConnectedClientsIds.Count - 2 > 0)
I believe this meant to be a comparison of greater than or equal.
As when there are only 2 connected clients this returns false and the animations are not sent to any client from the server. After a third client joins all the clients can see the animations of all the other clients.
This may be a result from testing based on hosted servers where there will only be one remote client and a host. Since the host is on the server he would be seeing the client's animations while sending his animations to the client. While the client would be seeing his own animations and sending his to the server(host). This check malfunctions when a dedicated server is used since the total number of clients will be less than 3 while also not having any player be on the server where the animations will always be expected.
Reproduce Steps
- Set your Network Animator component to owner authoritative
- Run a dedicated server
- connect 2 clients
- observe that neither client gets the other's animations
- connect a 3rd client
- observe that each client can now see there others' animations
Actual Outcome
Animations from clients are not synced when only 2 clients are connected to a dedicated server.
Expected Outcome
A client should be able to see the other client's animation on a dedicated server.
Environment
- OS: Windows 10
- Unity Version: 2021.10f1
- Netcode Version: 1.0.0
- Netcode Commit: d23f93d
Description
On the network animator component. There is this check in the send animation functions:
if (NetworkManager.ConnectedClientsIds.Count - 2 > 0)I believe this meant to be a comparison of greater than or equal.
As when there are only 2 connected clients this returns false and the animations are not sent to any client from the server. After a third client joins all the clients can see the animations of all the other clients.
This may be a result from testing based on hosted servers where there will only be one remote client and a host. Since the host is on the server he would be seeing the client's animations while sending his animations to the client. While the client would be seeing his own animations and sending his to the server(host). This check malfunctions when a dedicated server is used since the total number of clients will be less than 3 while also not having any player be on the server where the animations will always be expected.
Reproduce Steps
Actual Outcome
Animations from clients are not synced when only 2 clients are connected to a dedicated server.
Expected Outcome
A client should be able to see the other client's animation on a dedicated server.
Environment