Player

The Player class represents a full-featured player instance defined as a link between a ComoSource and a ComoScript.

A player is always instantiated on a given {@ComoNode}, although it si possible to create a mirror of a Player on a different node.

Attributes

id :String

Description:
  • Id of the player

Source:

nodeId :String

Description:
  • Id of the como node

Source:

source :SharedState

Description:
  • Source of the player

Source:

state :SharedState

Description:
  • Underlying state of the player.

Source:

Methods

(async) delete()

Description:
  • Delete the player

Source:

(async) setScript(scriptNameopt)

Description:
  • Set the script associated to this player

Source:
Parameters:
Name Type Attributes Default Description
scriptName String <optional>
null

Name of the script. If null just exit from current script.