Remove !checkem
This commit is contained in:
parent
656393cc7b
commit
2e501008df
5 changed files with 2 additions and 213 deletions
|
@ -1,71 +0,0 @@
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
using Discord.Commands;
|
|
||||||
using Geekbot.net.Lib.ErrorHandling;
|
|
||||||
using Geekbot.net.Lib.Media;
|
|
||||||
|
|
||||||
namespace Geekbot.net.Commands.Randomness
|
|
||||||
{
|
|
||||||
public class CheckEm : ModuleBase
|
|
||||||
{
|
|
||||||
private readonly IMediaProvider _checkEmImages;
|
|
||||||
private readonly IErrorHandler _errorHandler;
|
|
||||||
|
|
||||||
public CheckEm(IMediaProvider mediaProvider, IErrorHandler errorHandler)
|
|
||||||
{
|
|
||||||
_checkEmImages = mediaProvider;
|
|
||||||
_errorHandler = errorHandler;
|
|
||||||
}
|
|
||||||
|
|
||||||
[Command("checkem", RunMode = RunMode.Async)]
|
|
||||||
[Summary("Check for dubs")]
|
|
||||||
public async Task MuhDubs()
|
|
||||||
{
|
|
||||||
try
|
|
||||||
{
|
|
||||||
var number = new Random().Next(10000000, 99999999);
|
|
||||||
var dubtriqua = "";
|
|
||||||
|
|
||||||
var ns = GetIntArray(number);
|
|
||||||
if (ns[7] == ns[6])
|
|
||||||
{
|
|
||||||
dubtriqua = "DUBS";
|
|
||||||
if (ns[6] == ns[5])
|
|
||||||
{
|
|
||||||
dubtriqua = "TRIPS";
|
|
||||||
if (ns[5] == ns[4])
|
|
||||||
dubtriqua = "QUADS";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
var sb = new StringBuilder();
|
|
||||||
sb.AppendLine($"Check em {Context.User.Mention}");
|
|
||||||
sb.AppendLine($"**{number}**");
|
|
||||||
if (!string.IsNullOrEmpty(dubtriqua))
|
|
||||||
sb.AppendLine($":tada: {dubtriqua} :tada:");
|
|
||||||
sb.AppendLine(_checkEmImages.GetCheckem());
|
|
||||||
|
|
||||||
await ReplyAsync(sb.ToString());
|
|
||||||
}
|
|
||||||
catch (Exception e)
|
|
||||||
{
|
|
||||||
await _errorHandler.HandleCommandException(e, Context);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
private int[] GetIntArray(int num)
|
|
||||||
{
|
|
||||||
var listOfInts = new List<int>();
|
|
||||||
while (num > 0)
|
|
||||||
{
|
|
||||||
listOfInts.Add(num % 10);
|
|
||||||
num /= 10;
|
|
||||||
}
|
|
||||||
|
|
||||||
listOfInts.Reverse();
|
|
||||||
return listOfInts.ToArray();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
|
@ -59,9 +59,6 @@
|
||||||
<PackageReference Include="YamlDotNet" Version="6.0.0" />
|
<PackageReference Include="YamlDotNet" Version="6.0.0" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<None Update="Storage\checkEmPics">
|
|
||||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
|
||||||
</None>
|
|
||||||
<None Update="Storage\croissant">
|
<None Update="Storage\croissant">
|
||||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||||
</None>
|
</None>
|
||||||
|
|
|
@ -2,7 +2,6 @@
|
||||||
{
|
{
|
||||||
public interface IMediaProvider
|
public interface IMediaProvider
|
||||||
{
|
{
|
||||||
string GetCheckem();
|
|
||||||
string GetPanda();
|
string GetPanda();
|
||||||
string GetCrossant();
|
string GetCrossant();
|
||||||
string GetSquirrel();
|
string GetSquirrel();
|
||||||
|
|
|
@ -8,7 +8,6 @@ namespace Geekbot.net.Lib.Media
|
||||||
{
|
{
|
||||||
private readonly Random _random;
|
private readonly Random _random;
|
||||||
private readonly IGeekbotLogger _logger;
|
private readonly IGeekbotLogger _logger;
|
||||||
private string[] _checkemImages;
|
|
||||||
private string[] _pandaImages;
|
private string[] _pandaImages;
|
||||||
private string[] _croissantImages;
|
private string[] _croissantImages;
|
||||||
private string[] _squirrelImages;
|
private string[] _squirrelImages;
|
||||||
|
@ -24,8 +23,7 @@ namespace Geekbot.net.Lib.Media
|
||||||
_logger = logger;
|
_logger = logger;
|
||||||
|
|
||||||
logger.Information(LogSource.Geekbot, "Loading Media Files");
|
logger.Information(LogSource.Geekbot, "Loading Media Files");
|
||||||
|
;
|
||||||
LoadCheckem();
|
|
||||||
LoadPandas();
|
LoadPandas();
|
||||||
BakeCroissants();
|
BakeCroissants();
|
||||||
LoadSquirrels();
|
LoadSquirrels();
|
||||||
|
@ -36,13 +34,6 @@ namespace Geekbot.net.Lib.Media
|
||||||
LoadDab();
|
LoadDab();
|
||||||
}
|
}
|
||||||
|
|
||||||
private void LoadCheckem()
|
|
||||||
{
|
|
||||||
var rawLinks = File.ReadAllText(Path.GetFullPath("./Storage/checkEmPics"));
|
|
||||||
_checkemImages = rawLinks.Split("\n");
|
|
||||||
_logger.Trace(LogSource.Geekbot, $"Loaded {_checkemImages.Length} CheckEm Images");
|
|
||||||
}
|
|
||||||
|
|
||||||
private void LoadPandas()
|
private void LoadPandas()
|
||||||
{
|
{
|
||||||
var rawLinks = File.ReadAllText(Path.GetFullPath("./Storage/pandas"));
|
var rawLinks = File.ReadAllText(Path.GetFullPath("./Storage/pandas"));
|
||||||
|
@ -99,11 +90,6 @@ namespace Geekbot.net.Lib.Media
|
||||||
_logger.Trace(LogSource.Geekbot, $"Loaded {_dabImages.Length} Dab Images");
|
_logger.Trace(LogSource.Geekbot, $"Loaded {_dabImages.Length} Dab Images");
|
||||||
}
|
}
|
||||||
|
|
||||||
public string GetCheckem()
|
|
||||||
{
|
|
||||||
return _checkemImages[_random.Next(0, _checkemImages.Length)];
|
|
||||||
}
|
|
||||||
|
|
||||||
public string GetPanda()
|
public string GetPanda()
|
||||||
{
|
{
|
||||||
return _pandaImages[_random.Next(0, _pandaImages.Length)];
|
return _pandaImages[_random.Next(0, _pandaImages.Length)];
|
||||||
|
|
|
@ -1,122 +0,0 @@
|
||||||
http://s19.postimg.org/pcq2kwzoj/4cb.png
|
|
||||||
http://s19.postimg.org/cvetk0f4z/5_Dim_Dy6p.jpg
|
|
||||||
http://s19.postimg.org/5hzfl1v37/1310151998600.jpg
|
|
||||||
http://s19.postimg.org/53y3lgazn/1324181141954.jpg
|
|
||||||
http://s19.postimg.org/724rjg3hf/1392512742365.png
|
|
||||||
http://s19.postimg.org/3rgejkdk3/1393501296733.png
|
|
||||||
http://s19.postimg.org/a6ffg8k9v/1401667341503.jpg
|
|
||||||
http://s19.postimg.org/qiph5yylf/1419231572452.jpg
|
|
||||||
http://s19.postimg.org/fqwi4m8ir/1427600681401.png
|
|
||||||
http://s19.postimg.org/4c00zzw6b/1447813628974.png
|
|
||||||
http://s19.postimg.org/uuio8puw3/b5_3q_ycaaavxtf.jpg
|
|
||||||
http://s19.postimg.org/bghu913fn/check_em_by_boyboy99100_d57xp3y.png
|
|
||||||
http://s19.postimg.org/s1pgooujn/l_Hkppjs.jpg
|
|
||||||
http://s19.postimg.org/m08itft0j/checkem.jpg
|
|
||||||
https://old.postimg.org/image/6vx33rb1b/
|
|
||||||
https://old.postimg.org/image/wxiaz1mov/
|
|
||||||
https://old.postimg.org/image/azqfizx27/
|
|
||||||
https://old.postimg.org/image/6iy2kbiu7/
|
|
||||||
https://old.postimg.org/image/k8slt45y7/
|
|
||||||
https://old.postimg.org/image/t7ruxmplr/
|
|
||||||
https://old.postimg.org/image/ssbzqvean/
|
|
||||||
https://old.postimg.org/image/kbchfy9lr/
|
|
||||||
https://old.postimg.org/image/dl0lk9btr/
|
|
||||||
https://old.postimg.org/image/e5k80oufz/
|
|
||||||
https://old.postimg.org/image/er005baqn/
|
|
||||||
https://old.postimg.org/image/bfk2uzcin/
|
|
||||||
https://old.postimg.org/image/556fp0jkv/
|
|
||||||
https://old.postimg.org/image/i0efbryu7/
|
|
||||||
https://old.postimg.org/image/943n7u87z/
|
|
||||||
https://old.postimg.org/image/xn5op5cm7/
|
|
||||||
https://old.postimg.org/image/3l5p4d0kf/
|
|
||||||
https://old.postimg.org/image/5boq5ui3j/
|
|
||||||
https://old.postimg.org/image/ru082bqcf/
|
|
||||||
https://old.postimg.org/image/ytea1oqan/
|
|
||||||
https://old.postimg.org/image/vu7dekgtb/
|
|
||||||
https://old.postimg.org/image/hl7qwi2an/
|
|
||||||
https://old.postimg.org/image/5aescfg9r/
|
|
||||||
https://old.postimg.org/image/9gzmrrfvj/
|
|
||||||
https://old.postimg.org/image/50bv6tr1b/
|
|
||||||
https://old.postimg.org/image/afkl7silb/
|
|
||||||
https://old.postimg.org/image/nrdsgzllr/
|
|
||||||
https://old.postimg.org/image/s32e5zsin/
|
|
||||||
https://old.postimg.org/image/5sej60v8f/
|
|
||||||
https://old.postimg.org/image/lgfqctau7/
|
|
||||||
https://old.postimg.org/image/tn7q4e0wv/
|
|
||||||
https://old.postimg.org/image/8612arz1b/
|
|
||||||
https://old.postimg.org/image/w5tf52mn3/
|
|
||||||
https://old.postimg.org/image/zdxwi48wv/
|
|
||||||
https://old.postimg.org/image/lphwghd0f/
|
|
||||||
https://old.postimg.org/image/uzu0k0nq7/
|
|
||||||
https://old.postimg.org/image/3vqzsxjbz/
|
|
||||||
https://old.postimg.org/image/5d7uqqyov/
|
|
||||||
https://old.postimg.org/image/dntnyku8v/
|
|
||||||
https://old.postimg.org/image/dsxf891jz/
|
|
||||||
https://old.postimg.org/image/3nyrioizj/
|
|
||||||
https://old.postimg.org/image/6zx2bzaqn/
|
|
||||||
https://old.postimg.org/image/wu6v1raqn/
|
|
||||||
https://old.postimg.org/image/hb9f4n2fz/
|
|
||||||
https://old.postimg.org/image/p7yhqm3a7/
|
|
||||||
https://old.postimg.org/image/oelvxzx9b/
|
|
||||||
https://old.postimg.org/image/vcq03xvdr/
|
|
||||||
https://old.postimg.org/image/b08t1yqlb/
|
|
||||||
https://old.postimg.org/image/6yrpwayan/
|
|
||||||
https://old.postimg.org/image/btleukwm7/
|
|
||||||
https://old.postimg.org/image/62ztuldzz/
|
|
||||||
https://old.postimg.org/image/w3iq9pxr3/
|
|
||||||
https://old.postimg.org/image/byp6493xb/
|
|
||||||
https://old.postimg.org/image/xp2lf9xcv/
|
|
||||||
https://old.postimg.org/image/j9p9u49pb/
|
|
||||||
https://old.postimg.org/image/hvxmytafz/
|
|
||||||
https://old.postimg.org/image/5eqzbnfa7/
|
|
||||||
https://old.postimg.org/image/do2uq290f/
|
|
||||||
https://old.postimg.org/image/54o261q1r/
|
|
||||||
https://old.postimg.org/image/94qm4jr4v/
|
|
||||||
https://old.postimg.org/image/lee88y0pr/
|
|
||||||
https://old.postimg.org/image/bncb58cv3/
|
|
||||||
https://old.postimg.org/image/5246j7me7/
|
|
||||||
https://old.postimg.org/image/4uby8ym1r/
|
|
||||||
https://old.postimg.org/image/qn996tj4v/
|
|
||||||
https://old.postimg.org/image/c1dn4twyn/
|
|
||||||
https://old.postimg.org/image/6rd9ra23j/
|
|
||||||
https://lehcark14.files.wordpress.com/2008/08/botan16.jpg
|
|
||||||
http://i.imgur.com/p9vALew.jpg
|
|
||||||
http://i.imgur.com/4a9l2Rm.png
|
|
||||||
http://i.imgur.com/RNtixMQ.jpg
|
|
||||||
https://pbs.twimg.com/media/Cro9aIGUEAAkXCP.jpg
|
|
||||||
http://s16.postimg.org/empvloimd/Check_em_Guts.png
|
|
||||||
https://s18.postimg.io/qgbhe7u09/1424491645996.gif
|
|
||||||
http://s19.postimg.org/hhemlt7xf/3eb.jpg
|
|
||||||
http://s19.postimg.org/cwsg6vo83/8aa.png
|
|
||||||
http://s19.postimg.org/rh9j1pj6r/28mohl4.png
|
|
||||||
http://s19.postimg.org/zba4n3qzn/86d.jpg
|
|
||||||
http://s19.postimg.org/cb3hart5v/2016_09_16_08_58_45.png
|
|
||||||
http://s19.postimg.org/m9ofx92lf/bb1.jpg
|
|
||||||
http://s19.postimg.org/maydqo4f7/e8b.jpg
|
|
||||||
http://s19.postimg.org/yqzoy5n4z/fbe.png
|
|
||||||
http://s19.postimg.org/xd822unvn/giphy.gif
|
|
||||||
http://s19.postimg.org/c4udlf9er/l_TU3eup.jpg
|
|
||||||
https://66.media.tumblr.com/cc893a0ee40d73d083da3df4bdaf45cc/tumblr_mx8psiFduG1t1g1k8o1_500.gif
|
|
||||||
http://i.imgur.com/swbXHSy.gif
|
|
||||||
http://img1.reactor.cc/pics/post/full/Anime-Touhou-Project-Yakumo-Yukari-%D0%A0%D0%B5%D0%BA%D1%83%D1%80%D1%81%D0%B8%D1%8F-1303807.jpeg
|
|
||||||
http://i.imgur.com/ftGLHE0.png
|
|
||||||
http://i.imgur.com/JELDhKQ.png
|
|
||||||
http://imgur.com/yBJound
|
|
||||||
http://i.imgur.com/f7gAVPJ.png
|
|
||||||
http://i.imgur.com/HxWyo2Z.jpg
|
|
||||||
http://i.imgur.com/8Eb9CxQ.png
|
|
||||||
http://i.imgur.com/kOECcjz.png
|
|
||||||
http://i.imgur.com/MJLu7oJ.jpg
|
|
||||||
http://i.imgur.com/itG3rPM.jpg
|
|
||||||
http://i.imgur.com/G83Go9t.jpg
|
|
||||||
http://i.imgur.com/jI2dBnU.jpg
|
|
||||||
http://i.imgur.com/FtALzg0.jpg
|
|
||||||
http://i.imgur.com/GwZpJEv.gif
|
|
||||||
http://i.imgur.com/TYGRD3B.gif
|
|
||||||
http://i.imgur.com/P6TxLS3.png
|
|
||||||
http://i.imgur.com/phTVTdn.jpg
|
|
||||||
http://i.imgur.com/thhR6UE.jpg
|
|
||||||
http://i.imgur.com/KbROufx.jpg
|
|
||||||
http://i.imgur.com/sQqWbcm.jpg
|
|
||||||
http://i.imgur.com/YYpis53.png
|
|
||||||
http://i.imgur.com/kwaRd54.gif
|
|
Loading…
Reference in a new issue