Package com.reign.kat.lib.voice.newvoice
Class PlaylistPlayer
java.lang.Object
com.sedmelluq.discord.lavaplayer.player.event.AudioEventAdapter
com.reign.kat.lib.voice.newvoice.PlaylistPlayer
- All Implemented Interfaces:
com.sedmelluq.discord.lavaplayer.player.event.AudioEventListener
public class PlaylistPlayer
extends com.sedmelluq.discord.lavaplayer.player.event.AudioEventAdapter
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final int
final com.sedmelluq.discord.lavaplayer.player.AudioPlayer
LavaPlayer AudioPlayer instance.Current playing track - null if nothing is playing. -
Constructor Summary
ConstructorsConstructorDescriptionPlaylistPlayer
(com.sedmelluq.discord.lavaplayer.player.AudioPlayerManager manager, int volume) -
Method Summary
Modifier and TypeMethodDescriptionvoid
pause()
Pause the player.boolean
play
(RequestedTrack track) Immediately load and play the track.void
resume()
Resume the player.long
seek
(long position) Seek to position in the current playing track.void
stop()
Stops the current playing track, and do not play any next song in the queue.Methods inherited from class com.sedmelluq.discord.lavaplayer.player.event.AudioEventAdapter
onEvent, onPlayerPause, onPlayerResume, onTrackEnd, onTrackException, onTrackStart, onTrackStuck, onTrackStuck
-
Field Details
-
ERROR_LIMIT
public static final int ERROR_LIMIT- See Also:
-
lavaPlayer
public final com.sedmelluq.discord.lavaplayer.player.AudioPlayer lavaPlayerLavaPlayer AudioPlayer instance. This class DOES NOT manage JDAs audio player. -
nowPlaying
Current playing track - null if nothing is playing.
-
-
Constructor Details
-
PlaylistPlayer
public PlaylistPlayer(com.sedmelluq.discord.lavaplayer.player.AudioPlayerManager manager, int volume)
-
-
Method Details
-
play
Immediately load and play the track.- Parameters:
track
- RequestedTrack to start playing.- Returns:
- boolean true if the play was successful.
-
pause
public void pause()Pause the player. -
resume
public void resume()Resume the player. -
stop
public void stop()Stops the current playing track, and do not play any next song in the queue. -
seek
public long seek(long position) Seek to position in the current playing track.- Parameters:
position
- long milliseconds to seek to.- Returns:
- long milliseconds position of the track.
-
getSendHandler
-