public sealed class NetworkRulesRegistryWhich rules apply to which object.
No guide page documents this yet — the page shows what the code says about itself.
Remarks
One default and a per-object override, which is the shape the policy takes at run time. The authoring shape is a .vxnetrules asset referenced by a prefab — the asset pipeline's half of this, and not built: what is here is the thing that asset will be loaded into, and the questions it answers are the questions it will answer then.
The registry is also the only place that knows both the rules and the ownership, which is why the questions live here rather than on NetworkRules: a rule about the owner is not a question a policy can answer on its own.
Fields and properties (2)
public NetworkRules DefaultWhat applies to an object that has not been given anything more specific.
public int OverrideCountHow many objects have rules of their own.
Methods (10)
public NetworkRulesRegistry(NetworkOwnership ownership)Creates a registry over an ownership table.
public void Set(NetworkId id, NetworkRules rules)Gives one object its own rules.
public bool Clear(NetworkId id)Puts an object back on the default rules.
public NetworkRules For(NetworkId id)The rules that apply to an object.
public bool MayCallServerRpc(NetworkId id, PlayerId requester, bool requiresOwnership)Whether a client may invoke a server call on an object.
public bool MayChangeOwner(NetworkId id, PlayerId requester)Whether a client may hand an object to somebody else.
public bool MaySpawn(NetworkId id, PlayerId requester)Whether a client may ask the server to create one of these.
public bool MayDespawn(NetworkId id, PlayerId requester)Whether a client may ask the server to destroy an object.
public bool MayWrite(NetworkId id, PlayerId requester)Whether a client may write an object's replicated state.
public int OnOwnerLeft(PlayerId player, List<DisconnectAction> actions)Works out what should happen to everything a departing player owned, and does the part of it that is ownership's to do.
Used by (16)
- NetworkAnimatorApplySystemVixen.Net.Animation
- NetworkAnimatorCaptureSystemVixen.Net.Animation
- NetworkAnimatorTestsVixen.Net.Animation.Tests
- NetworkAudioApplySystemVixen.Net.Audio
- NetworkAudioCaptureSystemVixen.Net.Audio
- NetworkAudioTestsVixen.Net.Audio.Tests
- NetworkBonesApplySystemVixen.Net.Animation
- NetworkBonesCaptureSystemVixen.Net.Animation
- NetworkRigidBodyCaptureSystemVixen.Net.Physics
- NetworkRigidBodyCorrectionSystemVixen.Net.Physics
- NetworkRigidBodyTestsVixen.Net.Physics.Tests
- NetworkRulesTestsVixen.Net.Tests
- NetworkSpawnerVixen.Net.Engine
- PredictedOwnershipSystemVixen.Net
- PredictionWiringTestsVixen.Net.Tests
- RpcRouterVixen.Net