Categories > Coding > C# >

[Release/Source] C# Discord Bot

Posts: 1479

Threads: 95

Joined: Oct, 2019

Reputation: 103

Posted

Idk I Wrote This While Being Extremely Bored Using Discord.Net

Its Commented So Maybe People Can Learn From It Or Something Idk I'll Post Screenshots Of Some Stuff Working

 

Has

Ban
Kick
Purge
Download
User

These Small Commands Can Be Changed Do Whatever It May Not Be Written The Best But It Works

Can Handle Custom Emotes And Stuff Added That In Before

https://cdn.discordapp.com/attachments/876535645990977549/907793143649407036/unknown.png

https://cdn.discordapp.com/attachments/876535645990977549/907793214826766356/unknown.png

 

Edit: I Wrote Exception Handling And Errors Into A Embed So Its Cool Any Unhandled Exceptions Will Be Posted In An Embed Same As Bot Errors Such As Unknown Command Etc

 

P.S I Removed Most Of My Assets Such As Token Images Etc

https://cdn.discordapp.com/attachments/876535645990977549/907792631772381214/Nihon_Bot.zip

  • 0

SnowyWaves

Hentai Connoisseur

vip

Posts: 156

Threads: 2

Joined: Nov, 2020

Reputation: 16

Replied

Hot

/charsssssssss

  • 0

simp for immune 

SkieHackerYT

Panda Development Team

vip

Posts: 367

Threads: 88

Joined: Apr, 2019

Reputation: 33

Replied

Vouch, sadly i use Discord.py so imma start with Discord.NET ooof

  • 0

https://media.discordapp.net/attachments/996322272547704845/1016492646820233246/standard.gif

https://cdn.discordapp.com/attachments/1074291934501290087/1085354909609754775/PelicanDevelopment.gif

Posts: 190

Threads: 19

Joined: Jul, 2021

Reputation: 6

Replied

@SkieHackerYT https://cdn.discordapp.com/attachments/906159018739925012/907857591844077588/unknown.png mmm ah yes

  • 0

10 years ago

Posts: 197

Threads: 10

Joined: Feb, 2021

Reputation: 9

Replied

@child1010 LOL that was a nice expose, child

  • 0

Im netral, not evil, not too kind either.

Posts: 31

Threads: 7

Joined: Sep, 2020

Reputation: 8

Replied

The code could be improoved , But the important part is that you know what your doing logically, Examples of where your code c an be improoved 

I saw in mutiple if cases your doing:

if(scenario ==true)

you do not need to do that, when using if , it will automatically check if its true so you would do something like this:

if(scenario)

when returning a new object, you do not need to use a variable, for example:

 public EmbedBuilder ErrorEmbed(string Error)
        {
            return  new EmbedBuilder()
            {
                Timestamp = DateTimeOffset.Now,
                ThumbnailUrl = null,
                Title = $"❌ Bot Error",
                Description = $"```csharp\n{Error}\n```",
                Color = new Color(205, 50, 85)
            };
        }

This is more of a presence here, but I recommend u do ((SocketTextChannel)Context.Channel) instead of doing Context.Channel as SocketTextChannel 

 

That is it from me ( dont take this offensively lol, just trying to help )

  • 0

Posts: 1479

Threads: 95

Joined: Oct, 2019

Reputation: 103

Replied

@JustPareX Thanks For The Comment It Helps I'll Keep In Mind Everything You Said

  • 0

Posts: 2014

Threads: 198

Joined: Apr, 2021

Reputation: 16

Replied

veri hot thans u

 

  • 0

Random quote here...

SkieHackerYT

Panda Development Team

vip

Posts: 367

Threads: 88

Joined: Apr, 2019

Reputation: 33

Replied

@child1010 Heck nahh... i didn't use Nihon Bot 

so no CW for mehhh

  • 0

https://media.discordapp.net/attachments/996322272547704845/1016492646820233246/standard.gif

https://cdn.discordapp.com/attachments/1074291934501290087/1085354909609754775/PelicanDevelopment.gif

Users viewing this thread:

( Members: 0, Guests: 1, Total: 1 )