fixed !!ms on local songs
This commit is contained in:
parent
9f9548b33b
commit
28563c1f0b
@ -47,7 +47,7 @@ namespace NadekoBot.Modules.Music.Classes
|
|||||||
|
|
||||||
public string PrettyFullTime => PrettyCurrentTime + " / " + PrettyTotalTime;
|
public string PrettyFullTime => PrettyCurrentTime + " / " + PrettyTotalTime;
|
||||||
|
|
||||||
public string PrettyName => $"**[{SongInfo.Title.TrimTo(65)}]({songUrl})**";
|
public string PrettyName => $"**[{SongInfo.Title.TrimTo(65)}]({SongUrl})**";
|
||||||
|
|
||||||
public string PrettyInfo => $"{MusicPlayer.PrettyVolume} | {PrettyTotalTime} | {PrettyProvider} | {QueuerName}";
|
public string PrettyInfo => $"{MusicPlayer.PrettyVolume} | {PrettyTotalTime} | {PrettyProvider} | {QueuerName}";
|
||||||
|
|
||||||
@ -104,7 +104,7 @@ namespace NadekoBot.Modules.Music.Classes
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private string songUrl {
|
public string SongUrl {
|
||||||
get {
|
get {
|
||||||
switch (SongInfo.ProviderType)
|
switch (SongInfo.ProviderType)
|
||||||
{
|
{
|
||||||
|
@ -512,12 +512,13 @@ namespace NadekoBot.Modules.Music
|
|||||||
[RequireContext(ContextType.Guild)]
|
[RequireContext(ContextType.Guild)]
|
||||||
public async Task MoveSong([Remainder] string fromto)
|
public async Task MoveSong([Remainder] string fromto)
|
||||||
{
|
{
|
||||||
|
if (string.IsNullOrWhiteSpace(fromto))
|
||||||
|
return;
|
||||||
|
|
||||||
MusicPlayer musicPlayer;
|
MusicPlayer musicPlayer;
|
||||||
if (!MusicPlayers.TryGetValue(Context.Guild.Id, out musicPlayer))
|
if (!MusicPlayers.TryGetValue(Context.Guild.Id, out musicPlayer))
|
||||||
{
|
|
||||||
return;
|
return;
|
||||||
}
|
|
||||||
fromto = fromto?.Trim();
|
fromto = fromto?.Trim();
|
||||||
var fromtoArr = fromto.Split('>');
|
var fromtoArr = fromto.Split('>');
|
||||||
|
|
||||||
@ -541,7 +542,7 @@ namespace NadekoBot.Modules.Music
|
|||||||
|
|
||||||
var embed = new EmbedBuilder()
|
var embed = new EmbedBuilder()
|
||||||
.WithTitle($"{s.SongInfo.Title.TrimTo(70)}")
|
.WithTitle($"{s.SongInfo.Title.TrimTo(70)}")
|
||||||
.WithUrl($"{s.SongInfo.Query}")
|
.WithUrl(s.SongUrl)
|
||||||
.WithAuthor(eab => eab.WithName("Song Moved").WithIconUrl("https://cdn.discordapp.com/attachments/155726317222887425/258605269972549642/music1.png"))
|
.WithAuthor(eab => eab.WithName("Song Moved").WithIconUrl("https://cdn.discordapp.com/attachments/155726317222887425/258605269972549642/music1.png"))
|
||||||
.AddField(fb => fb.WithName("**From Position**").WithValue($"#{n1}").WithIsInline(true))
|
.AddField(fb => fb.WithName("**From Position**").WithValue($"#{n1}").WithIsInline(true))
|
||||||
.AddField(fb => fb.WithName("**To Position**").WithValue($"#{n2}").WithIsInline(true))
|
.AddField(fb => fb.WithName("**To Position**").WithValue($"#{n2}").WithIsInline(true))
|
||||||
|
Loading…
Reference in New Issue
Block a user