示例#1
0
		public BaseHub(
			IRoomEvents roomEvents,
			IConnectionMappingService connectionMappingService)
		{
			RoomEvents = roomEvents;
			ConnectionMappingService = connectionMappingService;
		}
示例#2
0
 public SignalRHub(
     IRoomEvents roomEvents,
     IConnectionMappingService connectionMappingService)
     : base(
         roomEvents,
         connectionMappingService)
 {
 }
示例#3
0
        public RoomParticipantService(
            IRoomEvents roomEvents,
            IRoomManagementService roomManagementService,
            IMassTransitSignalRBackplaneService signalRBackplaneService)
        {
            _roomManagementService   = roomManagementService;
            _signalRBackplaneService = signalRBackplaneService;
            _participantInfo         = new();

            RegisterEventHandler(roomEvents.ParticipantJoined, OnParticipantJoined);
            RegisterEventHandler(roomEvents.ParticipantDisconnected, OnParticipantDisconnected);
        }
示例#4
0
#pragma warning restore CS0067

        public AGSRoom(string id, IAGSEdges edges, IGameEvents gameEvents,
                       IRoomEvents roomEvents, IGameState state, ICustomProperties properties,
                       IRoomLimitsProvider roomLimitsProvider)
        {
            _state             = state;
            RoomLimitsProvider = roomLimitsProvider;
            _gameEvents        = gameEvents;
            Events             = roomEvents;
            ID         = id;
            Objects    = new AGSConcurrentHashSet <IObject>();
            Areas      = new AGSBindingList <IArea>(5);
            ShowPlayer = true;
            _edges     = edges;
            Properties = properties;
            gameEvents.OnRepeatedlyExecute.Subscribe(onRepeatedlyExecute);
        }
示例#5
0
 public AGSRoom(string id, IViewport viewport, IAGSEdges edges, IGameEvents gameEvents,
                IRoomEvents roomEvents, IGameState state, ICustomProperties properties,
                IRoomLimitsProvider roomLimitsProvider)
 {
     _sorter = new RenderOrderSelector {
         Backwards = true
     };
     _state             = state;
     RoomLimitsProvider = roomLimitsProvider;
     _gameEvents        = gameEvents;
     Viewport           = viewport;
     Events             = roomEvents;
     ID         = id;
     Objects    = new AGSConcurrentHashSet <IObject> ();
     Areas      = new List <IArea> ();
     ShowPlayer = true;
     _edges     = edges;
     Properties = properties;
     gameEvents.OnRepeatedlyExecute.Subscribe(onRepeatedlyExecute);
 }