fix: fixed issues with the "is in vc" check
chore: update README.md Signed-off-by: limited_dev <loginakkisativ@gmail.com>
This commit is contained in:
parent
16069d6ccd
commit
c8d7003ef5
6 changed files with 18 additions and 8 deletions
|
@ -38,7 +38,7 @@ class NowPlayingExt : Extension() {
|
|||
val guildId = this.guild!!.id
|
||||
val link = Bot.lava.getLink(guildId)
|
||||
val player = link.player
|
||||
if (link.state != Link.State.CONNECTED) {
|
||||
if (link.state == Link.State.NOT_CONNECTED) {
|
||||
MessageUtil.sendEmbedForPublicSlashCommand(
|
||||
this,
|
||||
"Not connected",
|
||||
|
@ -58,7 +58,11 @@ class NowPlayingExt : Extension() {
|
|||
MessageUtil.sendEmbedForPublicSlashCommandWithImage(
|
||||
this,
|
||||
"Currently playing",
|
||||
"**${track.title}**\n*Now Playing*\nby ${track.author} :: ${
|
||||
"**${track.title}**\n*Now Playing*\nby ${track.author} :${
|
||||
TimeUtil.getTimeFormatedRaw(
|
||||
track.position.inWholeMilliseconds
|
||||
)
|
||||
}: ${
|
||||
TimeUtil.getTimeFormatedRaw(
|
||||
track.length.inWholeMilliseconds
|
||||
)
|
||||
|
|
|
@ -37,7 +37,7 @@ class QueueExt : Extension() {
|
|||
val guildId = this.guild!!.id
|
||||
val link = Bot.lava.getLink(guildId.toString())
|
||||
val player = link.player
|
||||
if (link.state != Link.State.CONNECTED) {
|
||||
if (link.state == Link.State.NOT_CONNECTED) {
|
||||
MessageUtil.sendEmbedForPublicSlashCommand(
|
||||
this,
|
||||
"Not connected",
|
||||
|
|
|
@ -50,7 +50,7 @@ class SkipExt : Extension() {
|
|||
}
|
||||
|
||||
val channelId = voiceState.channelId
|
||||
if (link.state != Link.State.CONNECTED) {
|
||||
if (link.state == Link.State.NOT_CONNECTED) {
|
||||
MessageUtil.sendEmbedForPublicSlashCommand(
|
||||
this,
|
||||
"Not connected",
|
||||
|
|
|
@ -52,7 +52,7 @@ class StopExt : Extension() {
|
|||
return@action
|
||||
}
|
||||
val channelId = vcsUser.channelId
|
||||
if (link.state != Link.State.CONNECTED) {
|
||||
if (link.state == Link.State.NOT_CONNECTED) {
|
||||
this.respond {
|
||||
this.embeds.add(
|
||||
MessageUtil.getEmbed(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue