cleanup, added prune command
This commit is contained in:
parent
e1d1f196fe
commit
1d632b61d8
@ -140,6 +140,7 @@ namespace NadekoBot
|
||||
|
||||
private async void PotentialGuess(object sender, MessageEventArgs e)
|
||||
{
|
||||
if (e.Server == null || e.Channel == null) return;
|
||||
if (e.Server.Id != _serverId || !active)
|
||||
return;
|
||||
|
||||
|
@ -274,8 +274,22 @@ namespace NadekoBot.Modules
|
||||
var time = (DateTime.Now - Process.GetCurrentProcess().StartTime);
|
||||
string uptime = " " + time.Days + " days, " + time.Hours + " hours, and " + time.Minutes + " minutes.";
|
||||
|
||||
await e.Send( String.Format("```Servers: {0}\nUnique Users: {1}\nUptime: {2}\nMy id is: {3}```", serverCount, uniqueUserCount, uptime, client.CurrentUser.Id));
|
||||
await e.Send($"```Servers: {serverCount}\nUnique Users: {uniqueUserCount}\nUptime: {uptime}\nMy id is: {client.CurrentUser.Id}```");
|
||||
});
|
||||
cgb.CreateCommand(".prune")
|
||||
.Parameter("num", Discord.Commands.ParameterType.Required)
|
||||
.Do(async e => {
|
||||
int num;
|
||||
|
||||
if (!Int32.TryParse(e.GetArg("num"), out num) || num < 1) {
|
||||
await e.Send("Incorrect amount.");
|
||||
return;
|
||||
}
|
||||
|
||||
(await e.Channel.DownloadMessages(num)).ForEach(async m => await m.Delete());
|
||||
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
}
|
||||
|
@ -111,7 +111,8 @@ namespace NadekoBot.Modules {
|
||||
|
||||
if (video?.Uri != "" && video.Uri != null) {
|
||||
SongQueue.Add(video);
|
||||
await e.Send("**Queued** " + video.FullName);
|
||||
if(SongQueue.Count > 1)
|
||||
await e.Send("**Queued** " + video.FullName);
|
||||
}
|
||||
});
|
||||
|
||||
@ -171,7 +172,6 @@ namespace NadekoBot.Modules {
|
||||
var msg = await e.Send("Playing " + Music.CurrentSong.FullName + " [00:00]");
|
||||
int counter = 0;
|
||||
int byteCount;
|
||||
var m = await e.Send("Downloading song...");
|
||||
|
||||
while ((byteCount = streamer.PCMOutput.Read(buffer, 0, blockSize)) > 0) {
|
||||
Voice.Send(buffer, byteCount);
|
||||
|
@ -12,20 +12,24 @@
|
||||
<TargetFrameworkVersion>v4.5.2</TargetFrameworkVersion>
|
||||
<FileAlignment>512</FileAlignment>
|
||||
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
|
||||
<PublishUrl>publish\</PublishUrl>
|
||||
<IsWebBootstrapper>true</IsWebBootstrapper>
|
||||
<PublishUrl>C:\Users\Master\Desktop\NadekoBot\</PublishUrl>
|
||||
<Install>true</Install>
|
||||
<InstallFrom>Disk</InstallFrom>
|
||||
<UpdateEnabled>false</UpdateEnabled>
|
||||
<InstallFrom>Web</InstallFrom>
|
||||
<UpdateEnabled>true</UpdateEnabled>
|
||||
<UpdateMode>Foreground</UpdateMode>
|
||||
<UpdateInterval>7</UpdateInterval>
|
||||
<UpdateIntervalUnits>Days</UpdateIntervalUnits>
|
||||
<UpdatePeriodically>false</UpdatePeriodically>
|
||||
<UpdateRequired>false</UpdateRequired>
|
||||
<MapFileExtensions>true</MapFileExtensions>
|
||||
<ApplicationRevision>0</ApplicationRevision>
|
||||
<InstallUrl>http://www.github.com/Kwoth/NadekoBot/</InstallUrl>
|
||||
<CreateWebPageOnPublish>true</CreateWebPageOnPublish>
|
||||
<WebPage>publish.htm</WebPage>
|
||||
<ApplicationRevision>1</ApplicationRevision>
|
||||
<ApplicationVersion>1.0.0.%2a</ApplicationVersion>
|
||||
<IsWebBootstrapper>false</IsWebBootstrapper>
|
||||
<UseApplicationTrust>false</UseApplicationTrust>
|
||||
<PublishWizardCompleted>true</PublishWizardCompleted>
|
||||
<BootstrapperEnabled>true</BootstrapperEnabled>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||
@ -47,6 +51,18 @@
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<ManifestCertificateThumbprint>0BE5B9F3B97B52FC5776E3D046AE0C7F708D2ED5</ManifestCertificateThumbprint>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<ManifestKeyFile>NadekoBot_TemporaryKey.pfx</ManifestKeyFile>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<GenerateManifests>true</GenerateManifests>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<SignManifests>true</SignManifests>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="libvideo, Version=1.0.0.0, Culture=neutral, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\VideoLibrary.1.3.1\lib\portable-net45+win+wpa81+MonoAndroid10+xamarinios10+MonoTouch10\libvideo.dll</HintPath>
|
||||
@ -112,6 +128,7 @@
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="App.config" />
|
||||
<None Include="NadekoBot_TemporaryKey.pfx" />
|
||||
<None Include="packages.config" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
|
Loading…
Reference in New Issue
Block a user