#development
1 messages · Page 1389 of 1
You don't have to specify the argument type because it's an event @vapid rock
Of course I dont have to, but this enables automatic suggestions in IDE
ok
Oh I see
i did the meme command do i have a error
my coded
if(message.content.startsWith(prefix + "meme" )){
let msg = await message.channel.send("Fetching a meme, please wait a second!");
fetch('https://meme-api.herokuapp.com/gimme')
.then(res => res.json())
.then(json => {
let embed = new Discord.RichEmbed()
.setTitle(json.title)
.setImage(json.url)
.setFooter(`Link: ${json.postLink} | Subreddit: ${json.subreddit}`)
msg.edit(embed)
});
}
my error
let msg = await message.channel.send("Fetching a meme, please wait a second!");
^^^^^
SyntaxError: await is only valid in async function
you need to make the function this is in be async
The error is self-explanatory: You used await in a non-async function.
So make the function you're in async.
you can make the function async
how i do that
nvm
like this
bot.on("message", async message => {
if(message.author.bot) return;
if(message.content.indexOf(prefix) !== 0) return;
const args = message.content.slice(prefix.length).trim().split(/ +/g);
const command = args.shift().toLowerCase();
Try it out and see
here my error
UnhandledPromiseRejectionWarning: TypeError: Discord.RichEmbed is not a constructor
at C:\Users\love\Documents\New folder\index.js:17:29
at processTicksAndRejections (internal/process/task_queues.js:97:5)
(node:11484) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 1)
(node:11484) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
and it did not send the meme
@solemn latch
richembed doesnt exist
so do i have to go here https://discord.com/developers/applications/774198333899800607/rich-presence/assets
Integrate your service with Discord — whether it's a bot or a game or whatever your wildest imagination can come up with.
rich presence isnt rich embed
no, you have to go here
this one
rich presence is not richembed
see how richEmbed and richPresence are diffrent words? 🤔
they are not the same thing
ok
isnt embed type gonna be deprecated soon?
you mean richembed?
embed type
the entire thing 
Integrate your service with Discord — whether it's a bot or a game or whatever your wildest imagination can come up with.
you mean richembed?
@solemn latch it's called MessageEmbed now
was that Discord?
click the link i sent
understood
dunno, i just know that i need some testers to give feedback for my bot
its flawless, zero bugs did indepth testing. now pay me!
what

...wat
how does eval help you with that
dont think eval does anything you cant do with normal code.
nbr .d
you want to make a user premium through eval? sure you can do that, i do that myself
🤔
but you have to build a system for that
make a database, put users in the database, make a field or column to enable or disable premium, then use eval to switch it on or off for a given user
then build your features around this database, and check if users are premium or not when they use commands
if a bot is missing say manage_roles permission how would you have it send an error message if it is?
I know it's like:
return message.channel.send('missing manage_roles');```
what would you put before .hasPermission?
make a database, put users in the database, make a field or column to enable or disable premium, then use eval to switch it on or off for a given user
@/Tim#2373 Would this work with quick.db?
Ok so
@/Tim#2373 Would this work with quick.db?
@agile lance any db can work, as long as you know how to use it
When you complete the action
Add a .catch(err => message.reply(“Missing permissions”))
After you trigger the action
I'm trying to integrate a webhook to my bot so I can send a message to a channel when someone votes, is there anything I should use to decide our port and path? like how do I determine what port to use
?? thats not even what they're asking @agile lance
I'm on a home network
I misread it
I apologize
Put message.member before .hasPermission
@vocal sluice ^
?? thats not even what they're asking @agile lance
@hollow sedge I apologize I read it wrong.
yeah i see
@solemn latch dev senpai i have a question?
can anyone tell me what is the best discord bot hosting website?
- OVH: https://www.ovh.com/us/vps/
Starting at $3.35/mo for 1 core, 2GB RAM, 20GB SSD - DigitalOcean: https://www.digitalocean.com/
Starting at $5/mo for 1 core, 1GB RAM, 25GB SSD - Linode: https://www.linode.com/
Starting at $5/mo for 1 core, 1GB RAM, 25GB SSD - Vultr: https://www.vultr.com/
Starting at $2.50/mo for 1 core, 512MB RAM, 10GB SSD - Amazon(AWS) Lightsail: https://amazonlightsail.com/
Starting at $3.50/mo (first month free) for 1 core, 512MB RAM, 20GB SSD - Time4VPS: https://www.time4vps.eu/
Starting at €3.99/month for 1 core, 2GB RAM, 20GB SSD - VIRMACH: https://virmach.com/
Full Windows and Linux Desktop VPS starting at $7/mo and $1/mo respectively
ℹ️ This is a list of hosting providers, not a backing/support for them. You will need to make your own decision. All $dollar prices are in USD.
@robust blade
<3
Not really a free option
I use Heroku @robust blade but you'll have no more than 440h/month
it's like from day 1 to 26 each month
there is no free hosts for discord bots
it's like the world's telling me to shut down my bot forever
Reasons why you shouldn't use Heroku for your bot:
- Bots are not what the platform is designed for. Heroku is designed to provide web servers (like Django, Flask, etc). This is why they give you a domain name and open a port on their local emulator.
- Heroku's environment is heavily containerized, making it significantly underpowered for a standard use case.
- Heroku's environment is volatile. In order to handle the insane amount of users trying to use it for their own applications, Heroku will dispose your environment every time your application dies unless you pay.
- And due to a lot of other issues....
const member = message.guild.members.cache.get("721088412077129760")
member.roles.add(message.guild.roles.cache.get(r => r.name == "Head Manager"))
Error: Cannot read property of “roles” of undefined
aside from the limited hours
@agile lance member is undefined
Doesn't matter if you defined member
Then how is undefined?
message.guild.members.cache.get() is undefined
He is inside the guild
Thats a user
<GuildManager>.members.fetch()
copy the id again
@agile lance do console.log(client.users.cache.get(`userid`))
Alright
and show me what it logs
All it logged was “undefined”
Then that ID is not found
So copy his ID again and try again?
I am telling you, that you have the incorrect ID. Right click on the users username and click copy ID
It found him after he talked in chat now
try tagging the user in the chat
because he was cached
ok cool
Ok so it cached him
Now try?
Sure
TypeError: message.guild.members.get is not a function
cache
Cache
also pls tell me u using the id and not <@numbers>
[v12] Methods accessing cached data are now found on the cache
- guild.roles.get("id")
+ guild.roles.cache.get("id")
This is the case for any structure relying on cached data, the most likely affected parts of your code are the Collection methods and properties (.size, .has(), .get(), .filter(), .map(), .find(), .forEach(), .reduce(), .sort(), .some())
https://discordjs.guide/additional-info/changes-in-v12.html#managers-cache
@opal plank they aren't
k good
From the code snippets they gave us atleast
Promise {
<rejected> TypeError [INVALID_TYPE]: Supplied roles is not a Role, Snowflake or Array.
Show code snippet
Should I attempt adding it by ID not by role name?
yeah
No show code snippet
should be better idk
Incorrect.
const member = message.guild.members.cache.get("721088412077129760")
member.roles.add(message.guild.roles.cache.get(r => r.name == "Head Manager"))
Stop trying to give info that won't fix the problem plz <3
I'd use the id
you'll end up betting in the way rather than helping
We aren't asking what you would use. They are asking for what would fix it
const member = message.guild.members.cache.get("721088412077129760")
member.roles.add(message.guild.roles.cache.get(r => r.name == "Head Manager"))
@agile lance use .find() when searching for name not .get()
it would fix, but in another way
use .find() when searching for name not .get()
true
No need for the useless comments
You can only pass a ID in .get(), in .find() you can provide what you are searching by
No problem, cheers!
You can only pass a ID in .get(), in .find() you can provide what you are searching by
well, I forgot that
it would be just .get('ID')
🤦♂️
How can I have 2 forms In the same page and have 2 submit buttons but have them not interact with eachother?
Html lmao
Can't you name each button so you know what button it is
Then just listen to them seperately
cant you onClick() => document.getElement(button_1) => do stuffs ?
(node:13912) UnhandledPromiseRejectionWarning: ReferenceError: ms is not defined
🤕
how do i fix this
ReferenceError: args is not defined
@earnest phoenix you do notice you also gave the answer for your own problem, right?
djs
how do I get the number of reactions on a message?
message.reactions.size iirc
ok I'll try thanks
@lucid prawn By creating args
I suggest you don't use code taken off the internet
@earnest phoenix that is incorrect on how to define args btw
you have to define it from where you are executing the file and pass it when running it
didn't work, i'll try looking at the documentation again
@upper elm Try <message>.reactions.cache.size
@earnest phoenix you do notice you also gave the answer for your own problem, right?
@opal plank Q
XD!
but
how i can
define
ms
const ms = value
Suggest you learn basic js before attempting to develop a discord bot
Then why did you ask what you knew the answer to
oh
Ok let me show you
read the ms library docs
I suggest you don't use code taken off the internet @blissful coral
i didnt just take code off the internet i have args defind
do it saying it not defing
lol
and we cannot help you define something if you do not show us how you pass the function in the first place
yeah if your error is as generic as that A. we need the code B. its probably pretty apparent what the error is
here my coded
if(message.content.startsWith(prefix + "say" )){
const saySomething = args.join(' ')
if (!args.length){
return message.channel.send('You must include an argument, ' + message.author.toString())
}
message.delete()
message.channel.send(saySomething)
}
if(message.content.startsWith(prefix + "meme" )){
const embed = new Discord.MessageEmbed()
got('https://www.reddit.com/r/memes/random/.json').then(response => {
let content = JSON.parse(response.body);
let permalink = content[0].data.children[0].data.permalink;
let memeUrl = `https://reddit.com${permalink}`;
let memeImage = content[0].data.children[0].data.url;
let memeTitle = content[0].data.children[0].data.title;
let memeUpvotes = content[0].data.children[0].data.ups;
let memeDownvotes = content[0].data.children[0].data.downs;
let memeNumComments = content[0].data.children[0].data.num_comments;
embed.setTitle(`${memeTitle}`)
embed.setURL(`${memeUrl}`)
embed.setImage(memeImage)
embed.setColor('RANDOM')
embed.setFooter(`👍 ${memeUpvotes} 👎 ${memeDownvotes} 💬 ${memeNumComments}`)
message.channel.send(embed);
})
}
yeah posting a picture of someone holding a gun in their mouth seems pretty lively and not joking about suicide
but
anyways
Suggest you talk to a professional if you are not joking.
const agrs = message.mentions.users.first()
def not how you define args lol
let args = message.content.slice(prefix.length).trim().split(/ +/g);
let command = args.shift().toLowerCase();
it work for my last command
your code basically only defines args if its a mention
in any other circumstance its not defined
should I do something about the prefix working in upper case?
like, if someone writes Gp! or gP! or even GP! the bot still answers?
or should I restrict it to only when someone writes gp!?
thats up to you as the developer, although if did want to do that, its fairly simple as you should just set the content to lowercase and just check for a lowecase value
^
thats up to you as the developer, although if did want to do that, its fairly simple as you should just set the content to lowercase and just check for a lowecase value
@prisma oriole I perfectly know how to do
I just wanted an opinion on 'should I'?
as i said in the first parts, its up to you, I personally would in case someone accidentally types Gp!
since some ppl on mobile have auto case
my error @blissful coral
ReferenceError: Cannot access 'args' before initialization
Then you define args after you call upon it
@outer perch Pretty simple actually, you can just do a .toLowerCase() when you are checking if the message is the prefix
Like this #development message
Hi
let args = message.content.slice(prefix.length).trim().split(/ +/g);
let command = args.shift().toLowerCase();
@blissful coral how to send code like this ??
Hey
How can i add a timeout
not .setTimeout
How can I remove something from mongo db after some time
say 12 hours
How can I remove something from mongo db after some time
@delicate shore
I used a separate piece of code to check every data and remove the expired every 5 minutes
I sorted and then started removing from the top to the one valid
@blissful coral how to send code like this ??
@sweet abyss
use 3 `
@delicate shore
I used a separate piece of code to check every data and remove the expired every 5 minutes
@near stratus Which method?
yo, anyone familiar with calling in objects to guildMemberAdd? keep getting missing permission errors on that event only, and it has all permissions (and yes operates without an integration, that has been updated and attempted already). could this be in relation to instead invite object, or in relation that the server is partnered/discoverable?
the object i'm calling is the invite on that event btw, thanks :) (discord.js)
@sweet abyss
```
code
```
@near stratus Which method?
@delicate shore
Just create a code with your desired language
Then create a col named EXPIRED
Set the data to TIMESTAMP+2days or whatever
Then sort it and keep removing them from the top until you find one which haven't reached the time limit.
Call the function after a certain time
@sweet abyss
```
code
```
@hollow sedge thankx
@hollow sedge thankx
@sweet abyss np
2020-11-16T04:26:30.055729+00:00: (node:4) UnhandledPromiseRejectionWarning: DiscordAPIError: Missing Permissions
2020-11-16T04:26:30.055742+00:00: at RequestHandler.execute (/app/node_modules/discord.js/src/rest/RequestHandler.js:170:25)
2020-11-16T04:26:30.055742+00:00: at processTicksAndRejections (internal/process/task_queues.js:97:5)
2020-11-16T04:26:30.055830+00:00: (node:4) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag --unhandled-rejections=strict (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 11)
(edit, error message might help)
for those who are interested, it works in guilds that are not in discovery, but the guild it is having issues with MissingPermissions is discovery enabled. is this a potential api error/bug itself? it works in other servers perfectly but not the discoverable one. just a bit irritating :/
Thanks
@analog imp That means the bot is missing permissions in that said server when trying to complete the action
right, but it has admin permissions in that server, and same with the server where it's working as intended.
here is where i am absolutely stumped:
i can confirm both servers have the exact same permissions as well
hallo
how to send small codes like only (g!help ) will be shown as code the the text
g!help
g!help
@sweet abyss in this it is takin whole line pls help
`Example`
@hasty mulch this is also taking whole line
ohh
o got it
g!help
nice
There you go
i wnt to add it in my bot help embed so thts why i ask this
lmao all the devs are offline
code
@clever vector show the full error and the code that's causing it
We won't be able to help you otherwise
its full
That's not the entire error
const canvacord = require("canvacord");
const { MessageAttachment } = require("discord.js");
module.exports.run = async (client, message, args) => {
let user = message.mentions.users.first() || client.users.cache.get(args[0]) || message.author;
let triggered = await canvacord.Canvas.trigger(user.displayAvatarURL({ format: "png", dynamic: false }));
let attachment = new MessageAttachment(triggered, "triggered.gif");
return message.channel.send(attachment);
That's only a part of the stacktrace
Make sure you're using the latest version
don't copy paste either
Because the new syntax is new Canvacord.Canvacord().trigger(<image>);
@clever vector const canvas = Canvacord
or something like that
Canacord canvas isnt a thing so you can make it Canvas
Ok let me try
or something like that
I guess js const { Canvacord } = require("canvacord"); const image = await new Canvacord().trigger(user.displayAvatarURL());
how to make the bot show the in-server nickname?
i tried member.user.nickname, it doesn't work
What library?
If you want the bot's nickname, grab the bot as the guild member using guild.me and get the nickname property; guild.me.nickname
oh, so it's like guild.member.nickname?
Do you want the member's nickname or the bot's nickname?
do i have to do it from const guild = message.guild.id
Do you want the member's nickname or the bot's nickname?
@pale vessel member's nickname
Ah, the author?
the mentioned user
uh
Show the full error
nicknameis a member property, not User
@pale vessel thank you, works now
i'm making a css bot desciption
You need to use inspect element on your browser to get the class names for different parts of the website
Then use those class names in your CSS code and change their colors/background or whatever
Some properties require you to put !important in order to actually overwrite the style
do i like reverse markdown voodoo it
Some properties require you to put
!importantin order to actually overwrite the style
@pale vessel yeah to overwrite it
so it knows to put it over certain things
You just use those CSS classnames in your css script and give it different properties
Nothing?
funny ques
Uhh what for? If you're going to write both I'd recommend keeping them together but sure you could write them apart/standalone
will it be added
@unborn ridge Sure, they don't have a minimum server count requirement
halo
Uhh what for? If you're going to write both I'd recommend keeping them together but sure you could write them apart/standalone
@weak parrot oh
but when the pokemon evolves using a stone
the short one
What are you trying to change?
its name randomly changes to null in the json file
You can style anything inside the page using the <style> tag
does anyone know what the problem might be
You can change the entire page's CSS from longdescription
if (message.member.presence.status === 'dnd') message.member.presence.status = ':dnd: Do Not Disturb';
You can change the entire page's CSS from longdescription
@weak parrot ah
bet
and thanks
You shouldn't modify variables like that
it says: TypeError: Cannot read preperty 'presence' of undefined
Create another variable or store it somewhere else
it works for mentions but doesn't on message.member
Right
What exactly I need to do a dashboard for a discord.js bot?
error
What exactly I need to do a dashboard for a discord.js bot?
@halcyon linden You need to know how to work with OAuth
That is not the full error
throw err;
^
Error: Cannot find module 'discord.js'
Require stack:
- /app/index.js
at Function.Module._resolveFilename (internal/modules/cjs/loader.js:610:15)
at Function.Module._load (internal/modules/cjs/loader.js:526:27)
at Module.require (internal/modules/cjs/loader.js:666:19)
at require (internal/modules/cjs/helpers.js:16:16)
at Object.<anonymous> (/app/index.js:1:32)
at Module._compile (internal/modules/cjs/loader.js:759:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:770:10)
at Module.load (internal/modules/cjs/loader.js:628:32)
at Function.Module._load (internal/modules/cjs/loader.js:555:12)
at Function.Module.runMain (internal/modules/cjs/loader.js:826:10)```
@pale vessel
Did you include discord.js inside your package.json?
My bot crashing
@halcyon linden You need to know how to work with OAuth
@pale vessel Where can I read about that?
Did you include
discord.jsinside yourpackage.json?
@pale vessel yes
p
You also need to learn templating language like EJS or learn React/Vue/others
const fs = require("fs");
const player = require("./modules/Music");
const app = require("express")();
const http = require("http");
const server = http.createServer(app);
app.listen(process.env.PORT);
setInterval(() => {
http.get(`http://${process.env.PROJECT_DOMAIN}.glitch.me/`);
}, 280000);
app.get("/", (rq, rs) => {
return rs.status(200).send("pong?");
});
class P74Y extends Client {
/**
* @constructor
* @param {options} options options
*/
constructor(options) {
super(options);
this.commands = new Collection();
this.aliases = new Collection();
this.wait = require("util").promisify(setTimeout);
this.logger = require("./modules/Logger");
this.config = require("./config");
this.admin = this.config.admin;
this.db = require("quick.db");
this.queue = new Map();
this.player = new player(this);
}```
EJS is nice and simple for beginners
index.js
"name": "happy",
"version": "0.0.0",
"description": "happy!",
"main": "index.js",
"scripts": {
"test": "node index.js",
"start": "node index.js"
},
"repository": {
"type": "git",
"url": "git+https://github.com/happy55573/happy.git"
},
"keywords": [
"happy",
"discord",
"discord.js",
"musicbot"
],
"author": "happy55573",
"license": "MIT",
"bugs": {
"url": "https://github.com/happy55573/happy/issues"
},
"homepage": "https://github.com/happy55573/happy#readme",
"devDependencies": {
"@types/node": "^13.7.0"
},
"dependencies": {
"discord.js": "^12.4.1",
"@discordjs/opus": "^0.3.2",
"chalk": "^4.1.0",
"discord-ytdl-core": "^4.1.5",
"express": "^4.17.1",
"hastebin-gen": "^2.0.5",
"moment": "^2.29.1",
"moment-duration-format": "^2.3.2",
"node-fetch": "^2.6.1",
"simple-youtube-api": "^5.2.1",
"snekfetch": "^4.0.4",
"quick.db": "^7.1.2"
},
"engines": {
"node": "12.x"
}
}```
@pale vessel
module?
Have you tried redeploying your app?
yes
css?
Seems like you just need to wait
hallo
so this would work?
@earnest phoenix no
i'm not done yet doe
i want to change my discription of my bot
because i added some features so i want to edit my bots discrip plas help me
i dont have css code
wich
@young flame Where are you writing it?
which*
long description
You're rewriting the whole page inside the description?
i'm writing it in the long desciption
You're rewriting the whole page inside the description?
@pale vessel basically lol
Why
All the content only show inside the description
idk
It would be bot page-ception
Hmm?
You can change background?
i want to change my discription of my bot
because i added some features so i want to edit my bots discrip plas help me
You can add content inside the description, but not outside (CSS can do that on some element though). Any style you add inside the description (using the <style> tag) applies to elements outside the description
can i ask a ques
to create dashboard we need to code on glitch.com?
anybody help me my upper question (pls mention only)
hslhelp
anybody help me my upper question (pls mention only)
@sweet abyss You can edit your bot description by going to your bot page
i go but there is no option to edit it
@sweet abyss You can edit your bot description by going to your bot page
@pale vessel
Can you see this?
lol
Can anyone help me
i want to do like Current prefix for Discord Bot List
How to do that
our bot prefix
anybody whould help mee ??
What is the problem
anybody whould help mee ??
@sweet abyss problem?
Not really
or i shoult delete it
You need to explain what your bot does and document its commands, if possible
Remove your bot's code, it shouldn't be there
means (ABCD)<these are 4 characters ?? i am right ??
i wouldn't write acbcs i that to pass the requirments
Yes
ohk
UHHH
Yes
What is your OS?
What's that
Windows/Linux
Windows
can you go to your command prompt and type python --version
Oh ok
This will tell you what version you are using and tell me that
hmm not here
What
Click the start button then type cmd and press enter
Then type pip install discord.py
Which start button
I mean the windows button
i need help pls
i want to play audio file in vc
i have that audio file in vs code
module.exports.run = async (client, message, args) => {
if (!message.member.voice.channel) {
return message.channel.send(`join vc`);
} else {
message.member.voice.channel.join().then(connection => {
console.log(`[${message.guild}] ${message.author.username} has issued the ${module.exports.help.name} command.`)
const dispatcher = connection.play('../gab.mp3');
dispatcher.on('end', end => {
message.member.voice.channel.leave();
});
})
}
};
module.exports.help = {
name: 'nahi'
};```
it joins but no sound
<Guild>.createdAt
thank u
Showing your could would be helpful
module.exports.run = async (client, message, args) => { if (!message.member.voice.channel) { return message.channel.send(`join vc`); } else { message.member.voice.channel.join().then(connection => { console.log(`[${message.guild}] ${message.author.username} has issued the ${module.exports.help.name} command.`) const dispatcher = connection.play('../gab.mp3'); dispatcher.on('end', end => { message.member.voice.channel.leave(); }); }) } }; module.exports.help = { name: 'nahi' };```
@unborn ridge
@twilit rapids
please
Oh I'm not able to help you now, at work
You could try asking in the djs server if no one is responding
link?
mmmh... try to use ytdl-core https://www.npmjs.com/package/ytdl-core
Should be on their docs website
name: "slowmode",
description: "Lets you set slowmode on the channel.",
execute: (client, message, args) => {
const amount = parseInt(args[0])
if(isNaN(amount)) return message.channel.send("It doesn't seem to be valid number")
if(args[0] === amount + "s") {
message.channel.setRateLimitPerUser(amount)
if(amount > 1) {
message.channel.send("slowmode is now " + amount + " seconds")
return
}
else {message.channel.send("slowmode is now " + amount + " second")
return }
} if(args[0] === amount + "min") {
message.channel.setRateLimitPerUser(amount * 60)
if(amount > 1) {
message.channel.send("slowmode is now " + amount + " minutes")
return
} else {
message.channel.send("slowmode is now " + amount + " minute")
return }
} if(args[0] === amount + "h") {
message.channel.setRateLimitPerUser(amount * 60 * 60)
if(amount > 1) {
message.channel.send("slowmode is now " + amount + " hours")
return
} else {
message.channel.send("slowmode is now " + amount + " hour")
return}
} else {
message.channel.send("You can only set seconds(s), minutes(min) and hours(h)")
}
}
}
how can i see who invited a bot?
i have seen https://discordjs.guide/popular-topics/audit-logs.html#some-quick-background but it is not clear how to do it
this dosent work on a channel that has it in the name
message.channel.send("test")
}```
read the error lol
it's so hard for people to read ¯_(ツ)_/¯
also @weary quiver I hope i am not seeing this

Does anyone know if there is a bot where if you click on a reaction it kicks you from the server? Similar to reaction roles
^

Think like a matrix themed server where opt in is red pill / blue pill. Blue pill kicks you
what the fuck
also @weary quiver I hope i am not seeing this
@earnest phoenix concerning indeed
The film The Matrix
Just check reaction then member.ban
Most likely a Hard request then
well i dont know of a bot made to kick people for reacting to a message 😂
kick =/= ban doe 
@weary quiver install Microsoft Visual C++ 14.0
How to add this in our bot page?
Server count?
yes
ok
(ytdl-core) sometimes when i try and play a song it returns "video stream unavailable", can someone give me advice
im not sure if i have to proxy or what
yes
mm
I assume copyrights could be the cause
sounds like region lock tbh
Does it work with other videos?
(ytdl-core) sometimes when i try and play a song it returns "video stream unavailable", can someone give me advice
@pure lion use discord-ytdl-core or ytdl-core-discord
dont use discord-ytdl-core its shit
is it plug and play?
im using ytdl-core for get url and discord-ytdl-core for play song
nothing wrong with ytdl-core
dont use discord-ytdl-core its shit
@red hollow why?
because it is shit lmao
wth
but that error sounds like region lock dice
u can try doing getInfo and checking if info.formats is(nt) empty


Doesn't work as in?
can you show your embed code?
.nickname is not a function
when i tried to play not if you were the last junkie on earth:
Error: input stream: Video unavailable
Passing in audioonly got a few more videos to work though
its just that one that ive found
how do you do a Server Count on a java bot tagg my
how do you do a Server Count on a java bot tagg my
@white mesa try this https://top.gg/api/docs ??
.nickname is not a function
@rustic nova whats the rest of the string?
@tribal siren nickname is most likely a string and not something that ends with ()
oh don't worry i fixed it :)
good
Bot website?
You're talking about a dashboard
You will require html, css and potentially js or php to be able to get started
Look into oauth2.0 if you wish that your users can change settings for each Servers and have their settings stored
@unborn ridge
Making the actual website, probably not. You might find some tutorials though on how you can make the background stuff, like oauth as i mentioned
So you want just a static website or?
yes
take a painkiller
Yeah you will need to have html/css knowledge
How to add this in our bot page?
https://cdn.discordapp.com/attachments/272764566411149314/777835047768031262/ooooookkkkkkkkkk.jpg
In order to get started, there's a bunch of tutorials
where
@lyric lynx #topgg-api, read the topic of that channel
where
@unborn ridge google is your friend
Sure, what is it?
@lyric lynx #topgg-api, read the topic of that channel
@rustic nova means?
Topgg of course
But sooner or later, you receive some from votes
@lyric lynx there's a link to the top.gg api
this is my dashboard for example
atleast part of it
ive spent like a crapton of time on this
just a random thught like who gets revenue of ads displayed on bot page on top.gg
@unborn ridge Bot owners will be able to withdraw the rewards from what I know
I gave up with oauth2.0 after realising you have to refresh your token
The user tokens 
@rustic nova can u help me out rq with forms:
Forms?
Oh no clue lmao
i only partially know html
Separating ?
like i have it so u have to submit certain forms, so how can i make like the submit button submit a specific form?
is git clone wring
You just put the form tags around each form and put a submit button into.
Having multiple forms requires unique names for each element.
wrong
You just put the form tags around each form and put a submit button into.
Having multiple forms requires unique names for each element.
@boreal iron submit button in the forms?
like i have it in a separate form
is git clone wring
@unborn ridge @rustic nova
and is dashboard made in vs code
pls
tho i did make it in atom
but thats just cuz my vsc doesnt like flask
dunno why
I don’t know what you wanna do.
Using POST or GET methods requires to actually send ur form. But your submit button actually is not inside the form tags?
i just want to show stats commands
i prefer vsc > flask
I don’t know what you wanna do.
Using POST or GET methods requires to actually send ur form. But your submit button actually is not inside the form tags?
@boreal iron 1 sec
<form action = "../guild" method = "POST">
<input class="input-group-text" aria-describedby="basic-addon1" name="prefix" value="{{ serverprefix }}" type="text">
</form>
</div>
<div class="form-group">
<label class="form-control-label" for="basic-url" style="color:black">Nickname</label>
<form action = "../guild" method = "POST">
<input class="input-group-text" aria-describedby="basic-addon1" name="botname" value="Arch" type="text">
</form>
</div>
<form method = "POST">
<input type="submit" class="btn btn-success">
</form>```
so like i have 2 forms for text
and 1 form for submit
should i just make it in 1 form tag
First of all HTML tags don’t allow spaces, not method = " - use method="... instead
Secondly if the endpoint is the same use one form tag
Yeah working doesn’t mean it’s the right syntax
Like a basic app?
yes
I mean, you can use Wix....
(╯°□°)╯︵ ┻━┻
there we go
__
fixed
I made my own, but that's just because I find that easier.
Aye and remember all contents inside form tags belong to the form
so like all in 1 form?
Yes
lmao yes
as u can tell
If you want, you can take a look at this.
div containers have nothing to do with the form elements at all
huh ok
Well just had back to me if so later
Gonna be at PC next time I guess and may have a better look than on mobile
alr ty
so like if its all in 1 tag
itll work?
how will flask know the difference doe?
they all start with this: <form action="../guild" method="POST">
they both
Well I actually don’t know what your form does yet so I can guess only
Reading the value names makes me think of changing the prefix?
ye
also how can i change the text of the submit button>
?
like it just says submit
value="name"
The name tag is the identifier of your POST method
OO I Added invite bot button on webpage
name="prefix" would be send as POST method and can be fetched with $_POST['prefix'] (in PHP for example)
trump is gone
@earnest phoenix #rules-and-info
It needs to be online to get verified
name="prefix" would be send as POST method and can be fetched with $_POST['prefix'] (in PHP for example)
@boreal iron ye i got that
but gtg sry
bb
I'm looking for an easy way to create a transcript file with messages inside it.. I fetched the messages but I'm not quite sure how to do the file part.. using fs? If I use fs it would take a lot of space in my VPS so whats the best way to do so?
Well if you wanna keep the transcript a long time it will indeed need place no matter using a database or the filesystem directly
how to stop command
@fickle sapphire if its just text messages, it wont take much space
Just return the command
like i want to make bingo starts in 2 minutes and if someone wants to cancel it to type &bingoStop
Oh nvm
Store your bingo game somewhere and implement something that stops it (cancels for interval for example)
if (message.content.includes(stop)) return process.end()
so with process.end() function?
Yes
thank you
well it isn't defined
How do I define it?
pass by reference or create it if you don't have one
I don't have one.
client = discord.commands.Bot(command_prefix="#prefix")
im assuming you're using djs
Yes djs
see their docs
this is in python
@pseudo raptor it's best to learn a language most "Discord bot makers" can't really compete with someting hand crafted
they have a simple bot app
What docs?
I use python but the majority use javascript
also could've found it with a google search
const client = new Discord.Client()
Discord is not defined
lmao
Helppp
holleesheet
First you need to define what is discord
How?
then you need to define client
stop trolling
const Discord = require('discord.js')
lmfao

you're annoying, not funny
Check the guide .-.
hes trolling xD
xD
XD
require is not a function
Helpp plzzzzzzz
pain
in js
How do you have a badge XD
Imagine not using a lib and writing anything yourself
@arctic hare custom status lol
Using a modified lib is still a lib
I'm stuckkk
large bots have their own private libraries / big mods of public ones
@earnest phoenix gotta make my lib, brb
require is not a function
Helpp plzzzzzzz
@carmine summit show me the code
Oh ****
@drifting wedge :blobsweat: i was thinking of dominating bots like dyno etc
i need my nitro ree
discord.gift/poop
haha
hi does anyone know how the datetime package works
im new to py btw
lol
datetime.datetime.now().hour is what i printed and i am getting 12 even tho it is 5 pm here
Anybody know how can I know which discord client the user is using? (mobile, web etc) in js (something for userinfo command)
iirc you can only get status but im not sure
yes
yes
So that if the other one dies, you still have another instance running
lmao
So that if the other one dies, you still have another instance running
@carmine summit but it'll answer 2x
Its better than nothing
No.
Shards r confusing
unless you're lucky
Never used sharding (fuck you gboard) because it's confusing
Better to have two instances running than sharding the bot
rip
i have 4 ids
is it maybe returning in GMT+0
usually it would be utcnow() then, but I assume that the machine had its timezone set to UTC
So I have to code somthing like activeness.{guildID}
Then when it reaches 90+ servers
It will leave servers
I don't have gov. ID
@carmine summit you have 3 ways to verify
That has the lowest activeness points
@carmine summit you have 3 ways to verify
@outer perch I don't have Gov. ID, Birth Cert, or Passport
how??
I'm 13?
you have a birth cert
^
I'm 13?
@carmine summit Birth Cert.
Nah birth cert go brrrr
your mom has it
you can also ring up your hospital and ask for a copy of it, at least here you can
if she lost it, you can request a new one in the city where you were born
I live at the Philippines. The system doesn't accept birth certs from us
wat
Discord would though
Ive tried it
@carmine summit send an email to Discord Support
lol rip
discord support is completely useless
chances of getting to a real human is like 1/1000
but you can get a gov id if you request one no?
my ID has expired, and I can't renew it cuz of Covid-19 and had to be delayed to December
but you can get a gov id if you request one no?
@quartz kindle FUCK YOU COVID
lmfao
how did u i do the bot sent the 15 first roles?
let rolemap = message.guild.roles
.sort((a, b) => b.position - a.position)
.map(r => r)
.join(",")
thats what i type
ask a friend to verify for you
ask a friend to verify for you
@quartz kindle Can you be my friend?
I can be the friend if needed
UwU double ping
just pocket one of your parents' / guardians' ID while they're not looking 😏
@carmine summit nope sry :^)

but seriously just ask your parent/guardian
getting the birth cert is not a problem, stripe doesn't accept the birth cert lol
I can be that friend though
@regal saddle
sad
cough Darkweb

Yes?
i am getting problem with emojiinfo
pls
i have all other commands
just emojiinfo
Whats the problem?
My way is also bad
plsss help
I split the emoji:123456890
😭
like to get role from message
stop command doesnt exist
I meaned shovel
i am using discord.py






