new PiioConnector(name, subscriptions)
- name: A string representing the name of the PiioConnector instance.
- subscriptions: An array of strings representing the events to subscribe to.
Registers a callback function to be executed when the specified event is triggered.
- name: The name of the event to listen for.
- callback: The function to execute when the event is triggered.
Registers a callback function to be executed only once when the specified event is triggered.
- name: The name of the event to listen for.
- callback: The function to execute when the event is triggered.
Returns the player object for the specified team and player number.
- teamNum: The team number.
- playerNum: The player number (optional).
Returns the position of the specified player in the team.
- teamNum: The team number.
- playerNum: The player number (optional).
Returns a list of players ordered by their position.
Returns the selected player for the specified team.
- teamNum: The team number.
Returns the name of the specified team.
- teamNum: The team number.
- options: Additional options (optional).
Returns the status of the specified team and player.
- teamNum: The team number.
- playerNum: The player number (optional).
Returns a list of players for the specified team.
- teamNum: The team number.
Returns the score of the specified team.
- teamNum: The team number.
Returns the state of the specified team.
- teamNum: The team number.
Returns the country of the specified player.
- teamNum: The team number.
- playerNum: The player number (optional).
Returns the pride flags of the specified player.
- teamNum: The team number.
- playerNum: The player number (optional).
Returns the port number of the specified player.
- teamNum: The team number.
- playerNum: The player number (optional).
Returns the character of the specified player.
- teamNum: The team number.
- playerNum: The player number (optional).
Returns a list of teams for the specified player.
- teamNum: The team number.
- playerNum: The player number (optional).
Returns the caster object for the specified caster number.
- casterNum: The caster number.
Returns the country of the specified caster.
- casterNum: The caster number.
Returns the pride flags of the specified caster.
- casterNum: The caster number.
Returns the current game object.
Returns the field object for the specified field name.
- name: The field name.
Returns the value of the specified field.
- name: The field name.
Returns the size of the team.
Returns the current game object.
Returns the URL of the picture if it exists.
- url: The base URL of the picture.
Returns the name of the move corresponding to the given move ID.
- move: The ID of the move.
Requests the statistics for a specified number of games. It will be returned by the slippiStats subscription.
- amount: The number of games to retrieve statistics for (default is 1).
- ready: Triggered when the PiioConnector instance is ready.
- scoreboard: Triggered when the scoreboard data changes.
- slippiFrame: Triggered when new Slippi frame data is available.
- slippiGameStarted: Triggered when a new Slippi game starts.
- slippiGameEnded: Triggered when a Slippi game ends.
- obsSceneChanged: Triggered when the OBS scene changes.
- obsSceneList: Triggered when the OBS scene list is updated.
- slippiStats: Triggered when the Stats will be resolved.