File tree 1 file changed +6
-3
lines changed 1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -85,9 +85,12 @@ public abstract class NetworkBehaviour : MonoBehaviour
85
85
// also note that this is a per-NetworkBehaviour flag.
86
86
// another component may not be client authoritative, etc.
87
87
public bool authority =>
88
- isClient
89
- ? syncDirection == SyncDirection . ClientToServer && isOwned
90
- : syncDirection == SyncDirection . ServerToClient ;
88
+ // check isServer instead of isClient, which covers host mode too.
89
+ // otherwise host mode would only have authority if ClientToServer.
90
+ // fixes: https://github.com/MirrorNetworking/Mirror/issues/3529
91
+ isServer
92
+ ? syncDirection == SyncDirection . ServerToClient
93
+ : syncDirection == SyncDirection . ClientToServer && isOwned ;
91
94
92
95
/// <summary>The unique network Id of this object (unique at runtime).</summary>
93
96
public uint netId => netIdentity . netId ;
You can’t perform that action at this time.
0 commit comments