1.0
This commit is contained in:
parent
94ebd47d0e
commit
cf1a3899d1
@ -689,7 +689,21 @@ namespace NadekoBot.Modules.Administration
|
|||||||
|
|
||||||
await NadekoBot.Client.GetCurrentUser().ModifyStatusAsync(u => u.Game = new Game(game)).ConfigureAwait(false);
|
await NadekoBot.Client.GetCurrentUser().ModifyStatusAsync(u => u.Game = new Game(game)).ConfigureAwait(false);
|
||||||
|
|
||||||
await channel.SendMessageAsync("New game set.").ConfigureAwait(false);
|
await channel.SendMessageAsync("`New game set.`").ConfigureAwait(false);
|
||||||
|
}
|
||||||
|
|
||||||
|
[NadekoCommand, Usage, Description, Aliases]
|
||||||
|
[RequireContext(ContextType.Guild)]
|
||||||
|
[OwnerOnly]
|
||||||
|
public async Task SetStream(IUserMessage umsg, string url, [Remainder] string name = null)
|
||||||
|
{
|
||||||
|
var channel = (ITextChannel)umsg.Channel;
|
||||||
|
|
||||||
|
name = name ?? "";
|
||||||
|
|
||||||
|
await NadekoBot.Client.GetCurrentUser().ModifyStatusAsync(u => u.Game = new Game(name, url, StreamType.Twitch)).ConfigureAwait(false);
|
||||||
|
|
||||||
|
await channel.SendMessageAsync("`New stream set.`").ConfigureAwait(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
[NadekoCommand, Usage, Description, Aliases]
|
[NadekoCommand, Usage, Description, Aliases]
|
||||||
|
@ -36,7 +36,7 @@ namespace NadekoBot.Modules.Utility
|
|||||||
`TextChannels:` **{(await server.GetTextChannelsAsync()).Count()}** `VoiceChannels:` **{(await server.GetVoiceChannelsAsync()).Count()}**
|
`TextChannels:` **{(await server.GetTextChannelsAsync()).Count()}** `VoiceChannels:` **{(await server.GetVoiceChannelsAsync()).Count()}**
|
||||||
`Members:` **{users.Count}** `-` {users.Count(u => u.Status == UserStatus.Online)}:green_heart: {users.Count(u => u.Status == UserStatus.Idle)}:yellow_heart: {users.Count(u => u.Status == UserStatus.DoNotDisturb)}:heart: {users.Count(u=> u.Status == UserStatus.Offline || u.Status == UserStatus.Unknown)}:black_heart:
|
`Members:` **{users.Count}** `-` {users.Count(u => u.Status == UserStatus.Online)}:green_heart: {users.Count(u => u.Status == UserStatus.Idle)}:yellow_heart: {users.Count(u => u.Status == UserStatus.DoNotDisturb)}:heart: {users.Count(u=> u.Status == UserStatus.Offline || u.Status == UserStatus.Unknown)}:black_heart:
|
||||||
`Roles:` **{server.Roles.Count()}**
|
`Roles:` **{server.Roles.Count()}**
|
||||||
`Created At:` **{createdAt}**
|
`Created At:` **{createdAt.ToString("dd.MM.yyyy HH:mm")}**
|
||||||
");
|
");
|
||||||
if (server.Emojis.Count() > 0)
|
if (server.Emojis.Count() > 0)
|
||||||
sb.AppendLine($"`Custom Emojis:` **{string.Join(", ", server.Emojis)}**");
|
sb.AppendLine($"`Custom Emojis:` **{string.Join(", ", server.Emojis)}**");
|
||||||
@ -57,7 +57,7 @@ namespace NadekoBot.Modules.Utility
|
|||||||
var createdAt = new DateTime(2015, 1, 1, 0, 0, 0, 0, DateTimeKind.Utc).AddMilliseconds(ch.Id >> 22);
|
var createdAt = new DateTime(2015, 1, 1, 0, 0, 0, 0, DateTimeKind.Utc).AddMilliseconds(ch.Id >> 22);
|
||||||
var toReturn = $@"`Name:` **#{ch.Name}**
|
var toReturn = $@"`Name:` **#{ch.Name}**
|
||||||
`Id:` **{ch.Id}**
|
`Id:` **{ch.Id}**
|
||||||
`Created At:` **{createdAt}**
|
`Created At:` **{createdAt.ToString("dd.MM.yyyy HH:mm")}**
|
||||||
`Topic:` **{ch.Topic}**
|
`Topic:` **{ch.Topic}**
|
||||||
`Users:` **{(await ch.GetUsersAsync()).Count()}**";
|
`Users:` **{(await ch.GetUsersAsync()).Count()}**";
|
||||||
await msg.Reply(toReturn).ConfigureAwait(false);
|
await msg.Reply(toReturn).ConfigureAwait(false);
|
||||||
@ -76,7 +76,8 @@ namespace NadekoBot.Modules.Utility
|
|||||||
toReturn += $"`Nickname:` **{user.Nickname}**";
|
toReturn += $"`Nickname:` **{user.Nickname}**";
|
||||||
toReturn += $@"`Id:` **{user.Id}**
|
toReturn += $@"`Id:` **{user.Id}**
|
||||||
`Current Game:` **{(user.Game?.Name == null ? "-" : user.Game.Name)}**
|
`Current Game:` **{(user.Game?.Name == null ? "-" : user.Game.Name)}**
|
||||||
`Joined At:` **{user.JoinedAt}**
|
`Joined Server:` **{user.JoinedAt?.ToString("dd.MM.yyyy HH:mm")}**
|
||||||
|
`Joined Discord:` **{user.CreatedAt.ToString("dd.MM.yyyy HH:mm")}**
|
||||||
`Roles:` **({user.Roles.Count()}) - {string.Join(", ", user.Roles.Select(r => r.Name)).SanitizeMentions()}**
|
`Roles:` **({user.Roles.Count()}) - {string.Join(", ", user.Roles.Select(r => r.Name)).SanitizeMentions()}**
|
||||||
`AvatarUrl:` **{user.AvatarUrl}**";
|
`AvatarUrl:` **{user.AvatarUrl}**";
|
||||||
await msg.Reply(toReturn).ConfigureAwait(false);
|
await msg.Reply(toReturn).ConfigureAwait(false);
|
||||||
|
27
src/NadekoBot/Resources/CommandStrings.Designer.cs
generated
27
src/NadekoBot/Resources/CommandStrings.Designer.cs
generated
@ -5729,6 +5729,33 @@ namespace NadekoBot.Resources {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Looks up a localized string similar to setstream.
|
||||||
|
/// </summary>
|
||||||
|
public static string setstream_cmd {
|
||||||
|
get {
|
||||||
|
return ResourceManager.GetString("setstream_cmd", resourceCulture);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Looks up a localized string similar to Sets the bots stream. First argument is the twitch link, second argument is stream name..
|
||||||
|
/// </summary>
|
||||||
|
public static string setstream_desc {
|
||||||
|
get {
|
||||||
|
return ResourceManager.GetString("setstream_desc", resourceCulture);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Looks up a localized string similar to `{0}setstream https://www.twitch.tv/masterkwoth Developing Nakedo`.
|
||||||
|
/// </summary>
|
||||||
|
public static string setstream_usage {
|
||||||
|
get {
|
||||||
|
return ResourceManager.GetString("setstream_usage", resourceCulture);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Looks up a localized string similar to settopic st.
|
/// Looks up a localized string similar to settopic st.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
@ -2475,4 +2475,13 @@
|
|||||||
<data name="adsarm_usage" xml:space="preserve">
|
<data name="adsarm_usage" xml:space="preserve">
|
||||||
<value>`{0}adsarm`</value>
|
<value>`{0}adsarm`</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="setstream_cmd" xml:space="preserve">
|
||||||
|
<value>setstream</value>
|
||||||
|
</data>
|
||||||
|
<data name="setstream_desc" xml:space="preserve">
|
||||||
|
<value>Sets the bots stream. First argument is the twitch link, second argument is stream name.</value>
|
||||||
|
</data>
|
||||||
|
<data name="setstream_usage" xml:space="preserve">
|
||||||
|
<value>`{0}setstream https://www.twitch.tv/masterkwoth Developing Nakedo`</value>
|
||||||
|
</data>
|
||||||
</root>
|
</root>
|
||||||
|
Loading…
Reference in New Issue
Block a user