interface IAuthorityReplicator (Niantic.ARDK.Networking.HLAPI.Authority.IAuthorityReplicator)
Overview
A replicator that will replicate authority info about a network entity. More…
interface IAuthorityReplicator: Niantic.ARDK.Networking.HLAPI.INetworkedDataHandler { // properties Role LocalRole; // methods IReadOnlyCollection<IPeer> PeersOfRole(Role role); Role RoleOfPeer(IPeer peer); void TryClaimRole(Role role, Action onPass, Action onFail); }; // direct descendants class GreedyAuthorityReplicator; class AuthBehaviour;
Inherited Members
public: // properties INetworkGroup Group; string Identifier; // methods void Unregister();
Detailed Documentation
A replicator that will replicate authority info about a network entity.
Properties
Role LocalRole
The local role of this network entity.
Methods
IReadOnlyCollection<IPeer> PeersOfRole(Role role)
Gets all peers that are of a given role. This method should never return null, if needed an empty collection is returned.
Role RoleOfPeer(IPeer peer)
Gets the role of a peer.
void TryClaimRole(Role role, Action onPass, Action onFail)
Trys to claim a role for the local peer.
Parameters:
| role | The role to claim. | 
| onPass | Called if the role could be claimed. | 
| onFail | Called if the role could not be claimed. |