Music Player
FreakLib.Music.Track Class Reference

This class implements a single Track for the MusicPlayer. Tracks are added to a Playlist that the MusicPlayer can then play. More...

Public Member Functions

 Track ()
 Initializes a new instance of the FreakLib.Music.Track class. More...
 
 Track (AudioClip aClip, string aName="")
 Initializes a new instance of the FreakLib.Music.Track class. More...
 
override string ToString ()
 Returns a System.String that represents the current FreakLib.Music.Track. More...
 

Public Attributes

string name = ""
 The Track name. More...
 
AudioClip clip
 The AudioClip for the Track. More...
 
bool enabled = true
 If the Track is enabled. When disabled, the track will not be played. More...
 
bool foldout = false
 If this Track should be expanded in the inspector. More...
 

Properties

float Length [get]
 The Track length, in seconds. More...
 
int Plays [get, set]
 The number of times this track has been played. More...
 

Detailed Description

This class implements a single Track for the MusicPlayer. Tracks are added to a Playlist that the MusicPlayer can then play.

Constructor & Destructor Documentation

FreakLib.Music.Track.Track ( )

Initializes a new instance of the FreakLib.Music.Track class.

FreakLib.Music.Track.Track ( AudioClip  aClip,
string  aName = "" 
)

Initializes a new instance of the FreakLib.Music.Track class.

Parameters
aClipThe AudioClip for this Track.
aNameThe name of this Track.

Member Function Documentation

override string FreakLib.Music.Track.ToString ( )

Returns a System.String that represents the current FreakLib.Music.Track.

Returns
A System.String that represents the current FreakLib.Music.Track.

Member Data Documentation

AudioClip FreakLib.Music.Track.clip

The AudioClip for the Track.

bool FreakLib.Music.Track.enabled = true

If the Track is enabled. When disabled, the track will not be played.

bool FreakLib.Music.Track.foldout = false

If this Track should be expanded in the inspector.

string FreakLib.Music.Track.name = ""

The Track name.

Property Documentation

float FreakLib.Music.Track.Length
get

The Track length, in seconds.

Track length.

int FreakLib.Music.Track.Plays
getset

The number of times this track has been played.

This will be reset by the MusicPlayer whenever a new Playlist is started.

The number of plays.


The documentation for this class was generated from the following file: