Overview
TheGuildQueuePlayerNode class manages all playback operations for a guild queue, including playing, pausing, seeking, volume control, and track manipulation. It is accessible via queue.node.
Constructor
The guild queue instance that owns this player node
Properties
The guild queue instance associated with this player node
Internal async queue for managing sequential tasks
The stream time for the current playback session in milliseconds
Current playback duration with history included in milliseconds
Estimated progress of the player adjusted for filters in milliseconds
Estimated total duration of the current track adjusted for filters in milliseconds
Total duration of the current audio track in milliseconds
Current volume level (0-100)
Playback State Methods
isIdle()
Checks if the player is currently in idle mode.true if the player is idle, false otherwiseisBuffering()
Checks if the player is currently buffering the track.true if the player is buffering, false otherwiseisPlaying()
Checks if the player is currently playing a track.true if the player is playing, false otherwiseisPaused()
Checks if the player is currently paused.true if the player is paused, false otherwisePlayback Control Methods
play()
Plays the given track or the next track in the queue.The track to play. If not provided, plays the next track from the queue
Play options
pause()
Pauses the playback.true if paused successfully, false otherwiseresume()
Resumes the playback.true if resumed successfully, false otherwisesetPaused()
Sets the paused state.true to pause, false to resumetrue if state changed successfully, false otherwiseskip()
Skips the current track.Skip options
true if skipped successfully, false otherwisestop()
Stops the playback and clears the queue.If
true, forcefully stops playback and destroys the dispatchertrue if stopped successfully, false otherwiseseek()
Seeks to a specific position in the current track.The position to seek to in milliseconds
true if seek was successful, false otherwiseVolume Control Methods
setVolume()
Sets the volume level.Volume level (0-100+). Values over 100 are allowed but may cause distortion
true if volume changed successfully, false otherwisesetBitrate()
Sets the bitrate for audio encoding.Bitrate in bits per second, or
'auto' to use the voice channel’s bitrateTrack Management Methods
insert()
Inserts a track at a specific position in the queue.The track to insert
The position to insert at (0 = next track)
remove()
Removes a track from the queue.The track to remove (can be Track instance, track ID string, or index number)
Whether to emit the
audioTrackRemove eventThe removed track, or
null if not foundjump()
Jumps to a specific track without removing other tracks.The track to jump to
true if jumped successfully, false if track not foundskipTo()
Skips to a specific track, removing all tracks before it.The track to skip to
true if skipped successfully, false if track not foundmove()
Moves a track from one position to another.The track to move
The destination position
copy()
Copies a track to another position in the queue.The track to copy
The position to copy to
swap()
Swaps two tracks in the queue.The first track to swap
The second track to swap
getTrackPosition()
Gets the position of a track in the queue.The track to find
The index of the track, or
-1 if not foundProgress Methods
getTimestamp()
Gets the current playback timestamp information.If
true, returns raw timestamps without filter adjustmentsTimestamp object or
null if no track is playingcreateProgressBar()
Creates a visual progress bar for the current track.Progress bar customization options
The formatted progress bar string, or
null if no track is playingresetProgress()
Resets the progress history.setProgress()
Manually sets the player progress.The progress value in milliseconds
getDurationMultiplier()
Gets the duration multiplier based on active filters.The duration multiplier value
Advanced Methods
requestSeek()
Requests the source to seek (for seekable streams).Seek event data containing position information
true if seek request was successful, false otherwiseRelated Types
TrackResolvable
- A
Trackinstance - A track ID string
- A queue index number