コード例 #1
0
 public SpawnPlayerSimulationCommand(
     WorldPlayers players,
     PlayerId playerId,
     IPhysicsWorld physicsWorld,
     PlayerConnectionRef connectionRef)
 {
     this._players       = players;
     this._connectionRef = connectionRef;
     this._playerId      = playerId;
     this._physicsWorld  = physicsWorld;
 }
コード例 #2
0
 public WorldReplicationManager(
     ReplicationConfig config,
     WorldPlayers players,
     IEntityGridMap entityGridMap)
 {
     this._players                  = players ?? throw new ArgumentNullException(nameof(players));
     this._entityGridMap            = entityGridMap ?? throw new ArgumentNullException(nameof(entityGridMap));
     this._packetPriorityComponents = new ReplicationPriorityEntityComponents(config.Capacity.InitialReplicatedEntityCapacity);
     this._packetPriorityCalculator = new PacketPriorityCalculator(config.PacketPriority);
     this._entityBuffer             = new Entity[256];
 }