Coder Social home page Coder Social logo

nikbrandt / arthur Goto Github PK

View Code? Open in Web Editor NEW
42.0 5.0 12.0 1.41 MB

I dunno, another Discord bot that's unique n' stuff

Home Page: https://discordbots.org/bot/329085343800229889

License: MIT License

JavaScript 100.00%
discord-bot discord discord-js discord-js-bot bot

arthur's Introduction

Arthur

Support Server . TOS . Invite . Trello Discord Bots Discord Bots Discord Bots


Arthur - Another one of those bots that does things. It has an active developer, at least for now. He'll probably respond to anything you ask him within a short amount of time.

Arthur does have some hot features that other bots don't, but not that many. To list a few, mp3 which downloads and converts YouTube videos to mp3, and webshot which takes a full-length shot of a website. And I think the leveling system is pretty damn nice, but who knows. More features are always being added, just wait a while because the developer is very slow to add things.

I guess the overall point of this is that Arthur is like a nice multipurpose bot. Yeah.

Eh, we're going back to using an MIT license, I feel weird having contributors but still being under copyright. To get this bot up and running, you'll probably need to add quite a lot of files to a ../media directory, and since I'm not really trying to decentralize this bot, that challenge is up to you.

PRs, issues, complaints, whatever, all welcome. You can also complain in the support server above.

Nik Brandt

arthur's People

Contributors

dependabot[bot] avatar icreatedthistodeletemyaccounts avatar idutchy avatar itscryptic avatar nikbrandt avatar sn8to avatar techno-coder avatar waspothegreat avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

arthur's Issues

(node:366) UnhandledPromiseRejectionWarning: TypeError: client.broadcastEval is not a function

I'm using your blacklist command, and when I try to blacklist my alt, in my console, it sends (node:366) UnhandledPromiseRejectionWarning: TypeError: client.broadcastEval is not a function

My code is

module.exports = {
  name: "blacklist",
  run: async(client, message, args) => {
	if (!args[0]) return message.channel.send('I uh.. I need an ID');
	if (args[0] === message.author.id) return message.channel.send('no, bad');
	
	let user;
	try {
		user = await client.users.fetch(args[0]) || (await client.broadcastEval(`this.users.fetch('${args[0]}')`)).filter(item => !!item)[0];
	} catch (e) { 
		user = undefined;
	}
	
	let guild = client.guilds.cache.get(args[0]) || (await client.broadcastEval(`this.guilds.cache.get('${args[0]}')`)).filter(item => !!item)[0];
	
	if (!user && !guild) return message.channel.send('Could not find user or guild by that ID. rip');
	
	let deleteEntry = false;
	let result = await sql.get('SELECT * FROM hardBlacklist WHERE id = ?', [ args[0] ]);
	if (result) deleteEntry = true;
	
	if (user) {
		deleteEntry ? await sql.run('DELETE FROM hardBlacklist WHERE id = ?', [ args[0] ]) : await sql.run('INSERT INTO hardBlacklist (id, type) VALUES (?, ?)', [ args[0], 'user' ]);
		message.channel.send(deleteEntry ? `Removed \`${user.tag}\` from blacklist. But did they really learn their lesson?` : `Added \`${user.tag}\` to blacklist. *May they never bother you again*.`);
	}
	
	if (guild) {
		deleteEntry ? await sql.run('DELETE FROM hardBlacklist WHERE id = ?', [ args[0] ]) : await sql.run('INSERT INTO hardBlacklist (id, type) VALUES (?, ?)', [ args[0], 'guild' ]);
		message.channel.send(deleteEntry ? `Guild \`${guild.name}\` removed from blacklist. Anti-uf.` : `Guild \`${guild.name}\` added to blacklist. ***Uf***.`);
	}

	client.hardBlacklist = undefined;
}
};```

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.