@@ -669,7 +669,11 @@ public bool IsServerAuthoritative()
669669 /// </remarks>
670670 protected virtual bool OnIsServerAuthoritative ( )
671671 {
672- return m_LocalNetworkManager && m_LocalNetworkManager . DistributedAuthorityMode ? true : AuthorityMode == AuthorityModes . Server ;
672+ if ( m_LocalNetworkManager && m_LocalNetworkManager . DistributedAuthorityMode )
673+ {
674+ return true ;
675+ }
676+ return AuthorityMode == AuthorityModes . Server ;
673677 }
674678
675679 private int [ ] m_TransitionHash ;
@@ -760,10 +764,7 @@ protected virtual void Awake()
760764
761765 foreach ( var parameterEntry in AnimatorParameterEntries . ParameterEntries )
762766 {
763- if ( ! AnimatorParameterEntryTable . ContainsKey ( parameterEntry . NameHash ) )
764- {
765- AnimatorParameterEntryTable . Add ( parameterEntry . NameHash , parameterEntry ) ;
766- }
767+ AnimatorParameterEntryTable . TryAdd ( parameterEntry . NameHash , parameterEntry ) ;
767768 }
768769
769770 int layers = m_Animator . layerCount ;
@@ -1692,8 +1693,8 @@ private void InternalSetTrigger(int hash, bool isSet = true)
16921693 }
16931694
16941695 /// <summary>
1695- /// Distributed Authority: Internally-called RPC client receiving function to update a trigger when the server wants to forward
1696- /// a trigger to a client
1696+ /// Distributed Authority: Internally-called RPC client receiving function to update a trigger when the authority wants
1697+ /// to forward a trigger to a client
16971698 /// </summary>
16981699 /// <param name="animationTriggerMessage">the payload containing the trigger data to apply</param>
16991700 [ Rpc ( SendTo . NotAuthority , AllowTargetOverride = true , InvokePermission = RpcInvokePermission . Owner ) ]
0 commit comments