Keyboard and mouse controls can share a stream. The format-specific header describes device grouping; a stream is not evidence of a distinct person.
Arguments
- movie
A replayr_movie or replayr_poll_stream returned by
read_movie()or a format-specific reader.
Value
Integer scalar: the second dimension of movie$inputs.
An unassigned poll stream returns NA_integer_ because the number of
participating players cannot be determined from its records.
Examples
movie <- read_movie(system.file("extdata", "sample.fm2", package = "replayr"))
n_players(movie)
#> [1] 2
# Polls of two controllers without a known order have no number of players.
stream <- read_movie(system.file("extdata", "paper", "unassigned.dtm", package = "replayr"))
n_players(stream)
#> [1] NA