public MovementDirectionDispatchTickable([NotNull] IReadonlyEntityGuidMappable <IMovementDirectionChangedListener> movementDirectionChangeListenerMappable, [NotNull] IReadonlyEntityGuidMappable <IMovementData> movementDataMappable, [NotNull] IReadonlyKnownEntitySet knownEntities) { MovementDirectionChangeListenerMappable = movementDirectionChangeListenerMappable ?? throw new ArgumentNullException(nameof(movementDirectionChangeListenerMappable)); MovementDataMappable = movementDataMappable ?? throw new ArgumentNullException(nameof(movementDataMappable)); KnownEntities = knownEntities ?? throw new ArgumentNullException(nameof(knownEntities)); }
public NetworkedTrackerChangedTickable(IPlayerTrackerTransformChangedEventSubscribable subscriptionService, ILog logger, [NotNull] IReadonlyKnownEntitySet knownEntities, [NotNull] IReadonlyEntityGuidMappable<EntityGameObjectDirectory> gameObjectDirectoryMappable) : base(subscriptionService, true, logger) { KnownEntities = knownEntities ?? throw new ArgumentNullException(nameof(knownEntities)); GameObjectDirectoryMappable = gameObjectDirectoryMappable ?? throw new ArgumentNullException(nameof(gameObjectDirectoryMappable)); }
/// <inheritdoc /> public PlayerActorDeathWatchTickable([NotNull] IReadonlyEntityGuidMappable <IActorRef> entityDataContainer, [NotNull] ILog logger, [NotNull] IReadonlyKnownEntitySet knownEntities, [NotNull] IEntityDestructionRequestedEventPublisher entityDestructionPublisher) { EntityDataContainer = entityDataContainer ?? throw new ArgumentNullException(nameof(entityDataContainer)); Logger = logger ?? throw new ArgumentNullException(nameof(logger)); KnownEntities = knownEntities ?? throw new ArgumentNullException(nameof(knownEntities)); EntityDestructionPublisher = entityDestructionPublisher ?? throw new ArgumentNullException(nameof(entityDestructionPublisher)); }
/// <inheritdoc /> public PlayerConnectionWatchTickable([NotNull] IReadonlyEntityGuidMappable <IActorRef> entityDataContainer, [NotNull] ILog logger, [NotNull] IReadonlyKnownEntitySet knownEntities, [NotNull] IReadonlyEntityGuidMappable <IConnectionService> connectionServiceMappable) { EntityDataContainer = entityDataContainer ?? throw new ArgumentNullException(nameof(entityDataContainer)); Logger = logger ?? throw new ArgumentNullException(nameof(logger)); KnownEntities = knownEntities ?? throw new ArgumentNullException(nameof(knownEntities)); ConnectionServiceMappable = connectionServiceMappable ?? throw new ArgumentNullException(nameof(connectionServiceMappable)); }
public CleanupInterestCollectionsEventListener(IEntityDeconstructionFinishedEventSubscribable subscriptionService, IReadonlyEntityGuidMappable <InterestCollection> interestCollections, IEntityInterestChangeEventSpoofable interestEventSpoofer, [NotNull] IReadonlyKnownEntitySet knownEntities) : base(subscriptionService) { InterestCollections = interestCollections; InterestEventSpoofer = interestEventSpoofer; KnownEntities = knownEntities ?? throw new ArgumentNullException(nameof(knownEntities)); }
/// <inheritdoc /> public EntityDataChangeTrackerTickable(IReadonlyEntityGuidMappable <IChangeTrackableEntityDataCollection> changeTrackableMap, IEntityDataChangeCallbackService entityDataCallbackDispatcher, [NotNull] IReadonlyKnownEntitySet knownEntites, [NotNull] ILog logger) { ChangeTrackableMap = changeTrackableMap ?? throw new ArgumentNullException(nameof(changeTrackableMap)); EntityDataCallbackDispatcher = entityDataCallbackDispatcher ?? throw new ArgumentNullException(nameof(entityDataCallbackDispatcher)); KnownEntites = knownEntites ?? throw new ArgumentNullException(nameof(knownEntites)); Logger = logger ?? throw new ArgumentNullException(nameof(logger)); }
public OnAvatarDownloadedInitializeRelevantMappablesEventListener(IContentPrefabCompletedDownloadEventSubscribable subscriptionService, [NotNull] IEntityGuidMappable <IPrefabContentResourceHandle> prefabHandleMappable, [NotNull] IReadonlyKnownEntitySet knownEntities, [NotNull] ILog logger) : base(subscriptionService) { PrefabHandleMappable = prefabHandleMappable ?? throw new ArgumentNullException(nameof(prefabHandleMappable)); KnownEntities = knownEntities ?? throw new ArgumentNullException(nameof(knownEntities)); Logger = logger ?? throw new ArgumentNullException(nameof(logger)); }
/// <inheritdoc /> public MovementSimulationTickable( IReadonlyEntityGuidMappable <IMovementGenerator <GameObject> > movementGenerators, IReadonlyEntityGuidMappable <GameObject> worldObjectMap, INetworkTimeService timeService, [NotNull] IReadonlyKnownEntitySet knownEntities) { MovementGenerators = movementGenerators ?? throw new ArgumentNullException(nameof(movementGenerators)); WorldObjectMap = worldObjectMap ?? throw new ArgumentNullException(nameof(worldObjectMap)); TimeService = timeService ?? throw new ArgumentNullException(nameof(timeService)); KnownEntities = knownEntities ?? throw new ArgumentNullException(nameof(knownEntities)); }
/// <inheritdoc /> public MovementUpdateMessageHandler( ILog logger, [NotNull] IFactoryCreatable <IMovementGenerator <IWorldObject>, EntityAssociatedData <IMovementData> > movementGeneratorFactory, [NotNull] IEntityGuidMappable <IMovementGenerator <IWorldObject> > movementGeneratorMappable, [NotNull] IEntityGuidMappable <IMovementData> movementDataMappable, [NotNull] IKnownEntitySet knownEntities) : base(logger) { MovementGeneratorFactory = movementGeneratorFactory ?? throw new ArgumentNullException(nameof(movementGeneratorFactory)); MovementGeneratorMappable = movementGeneratorMappable ?? throw new ArgumentNullException(nameof(movementGeneratorMappable)); MovementDataMappable = movementDataMappable ?? throw new ArgumentNullException(nameof(movementDataMappable)); KnownEntities = knownEntities ?? throw new ArgumentNullException(nameof(knownEntities)); }
/// <inheritdoc /> public EntityDataUpdateManager( IReadonlyEntityGuidMappable <IPeerPayloadSendService <GameServerPacketPayload> > sessionMappable, IReadonlyEntityGuidMappable <InterestCollection> guidToInterestCollectionMappable, IFactoryCreatable <FieldValueUpdate, EntityFieldUpdateCreationContext> updateFactory, IReadonlyEntityGuidMappable <IChangeTrackableEntityDataCollection> changeTrackingCollections, [NotNull] IReadonlyKnownEntitySet knownEntities) { SessionMappable = sessionMappable; GuidToInterestCollectionMappable = guidToInterestCollectionMappable; UpdateFactory = updateFactory; ChangeTrackingCollections = changeTrackingCollections; KnownEntities = knownEntities ?? throw new ArgumentNullException(nameof(knownEntities)); }
/// <inheritdoc /> public MovementSimulationTickable( IReadonlyEntityGuidMappable <IMovementGenerator <IWorldObject> > movementGenerators, IReadonlyEntityGuidMappable <IWorldObject> worldObjectMap, INetworkTimeService timeService, [NotNull] IReadonlyKnownEntitySet knonwnEntities, [JetBrains.Annotations.NotNull] RsUnityClient client) { MovementGenerators = movementGenerators ?? throw new ArgumentNullException(nameof(movementGenerators)); WorldObjectMap = worldObjectMap ?? throw new ArgumentNullException(nameof(worldObjectMap)); TimeService = timeService ?? throw new ArgumentNullException(nameof(timeService)); KnonwnEntities = knonwnEntities ?? throw new ArgumentNullException(nameof(knonwnEntities)); Client = client ?? throw new ArgumentNullException(nameof(client)); }
/// <inheritdoc /> public InterestChangeEventHandlerTickable( [NotNull] IEntityInterestChangeEventSubscribable subscriptionService, [NotNull] ILog logger, [NotNull] IReadonlyEntityGuidMappable <InterestCollection> managedInterestCollections, [NotNull] INetworkMessageSender <EntityVisibilityChangeContext> visibilityMessageSender, [NotNull] IReadonlyKnownEntitySet knownEntities, [NotNull] IReadonlyEntityGuidMappable <IActorRef> actorReferenceMappable) : base(subscriptionService, true, logger) { ManagedInterestCollections = managedInterestCollections ?? throw new ArgumentNullException(nameof(managedInterestCollections)); VisibilityMessageSender = visibilityMessageSender ?? throw new ArgumentNullException(nameof(visibilityMessageSender)); KnownEntities = knownEntities ?? throw new ArgumentNullException(nameof(knownEntities)); ActorReferenceMappable = actorReferenceMappable ?? throw new ArgumentNullException(nameof(actorReferenceMappable)); }
public ServerPingPacketTickable([NotNull] IReadonlyEntityGuidMappable <IPeerPayloadSendService <GameServerPacketPayload> > sendServiceMappable, [NotNull] IReadonlyKnownEntitySet knownEntities) { SendServiceMappable = sendServiceMappable ?? throw new ArgumentNullException(nameof(sendServiceMappable)); KnownEntities = knownEntities ?? throw new ArgumentNullException(nameof(knownEntities)); }
//Never used this before, new C# feature. Named tuples. They seem like a bad idea, but I figured I should write one in my life. public static IEnumerable <(NetworkEntityGuid EntityGuid, TReturnType ComponentValue)> EnumerateWithGuid <TReturnType>(this IReadonlyEntityGuidMappable <NetworkEntityGuid, TReturnType> collection, IReadonlyKnownEntitySet entitySet, EntityType exclusiveEntityType = EntityType.None) { if (collection == null)
public static IEnumerable <TReturnType> Enumerate <TReturnType>(this IReadonlyEntityGuidMappable <NetworkEntityGuid, TReturnType> collection, IReadonlyKnownEntitySet entitySet) { if (collection == null) { throw new ArgumentNullException(nameof(collection)); } if (entitySet == null) { throw new ArgumentNullException(nameof(entitySet)); } //Thread safe internally to iterate foreach (var element in entitySet) { if (collection.ContainsKey(element)) { yield return(collection.RetrieveEntity(element)); } } }
public PlayerEntityGuidEnumerable([NotNull] IReadonlyKnownEntitySet entitySet) { EntitySet = entitySet ?? throw new ArgumentNullException(nameof(entitySet)); }
public SimpleEnemyTargetSpellEffectTargetValidator([NotNull] IReadonlyKnownEntitySet knownEntitySet) { KnownEntitySet = knownEntitySet ?? throw new ArgumentNullException(nameof(knownEntitySet)); }
/// <inheritdoc /> public DemoTestingGameTickable([NotNull] IReadonlyEntityGuidMappable <IEntityDataFieldContainer> entityDataContainer, [NotNull] IReadonlyKnownEntitySet knownEntities) { EntityDataContainer = entityDataContainer ?? throw new ArgumentNullException(nameof(entityDataContainer)); KnownEntities = knownEntities ?? throw new ArgumentNullException(nameof(knownEntities)); }