#development
1 messages · Page 416 of 1
How do you make your let the user invite it to your own server?
give them the oauth link
the bot invite link
In the Invite URL?
what invite do you even want?
Ok
"ok" is not an answer to my question
Which bot invite link!
tf does that mean
!?
@shy verge hai
Ok, I want users able to invite the bot to their own servers. Right now, it only directes to the support server
Where do I put the Ouath2 link in the add bots page?
https://discordapp.com/api/oauth2/authorize?client_id=[botd]&scope=bot&permissions=[pemrs] put this in the bot invite box
you're overcomplicating things with OAuth
and replace botid with your bots id and perms with your perms
@shy verge its the link you use to invite bots u weeb
no u
Why cant I edit it?
I did generate it
then what are you trying to do with it
do you mean the listing on DBL?
they have a box for you to paste invite url
Thank you
Question:
How to get epoch / unix time
Language:
D.py (Python)
Extra
Im basically trying to get the epoch / unix time of when a user with created using user.created_at
user.created_at is a datetime.datetime object
How come my bot can't run multiple commands at the same time
Like I mean
I can't say two commands that are 3 seconds apart
I have to wait a while
Suggestions?
How are we supposed to know? :P
It could be anything, faulty logic, threading, ...
The only option you have is to pin point certain parts in your code that could potentially be responsible for it and show us or debug it yourself
its hard to tell without more info on how he handles the commands or the lang
What
"??
Ah ha, it says a recivemessage handler is blocking the task
@shy verge
ah so you're using d.net
it means whatever you're processing is taking longer than 3 seconds
might be code-spaget issue
or shiternet
can someone give me assistence
o.0
https://github.com/SebBot-Discord My bot will say "Seb Bot is typing..." forever even though there are no loops. Can anyone tell me what I'm doing wrong?
Node.js (discord.js)
you habe to end the typing
can you point us to the code where you stop it
about line lemme seee
reeee you aren't using lambdas
so when you say Seb, crazyimg it won't stop typing? xD
yep
does the command execute without any issues?
logs?
meanwhile i can do other commands
it will start typing for those commands, then stop for like 2 seconds, then it will just start typing forever again
if a function fucks midway through then you never get to the stopTyping() line
we need to know why the function dies before that line
it cant be discord.js's fault
does djs really have a safeguard for that?
YES!
huh
https://media.turtle-bot.com/f/phyuU.png tried passing true into it?
So, @shy verge, how do I make it not delay 3 seconds?
Internet is good
I just checked it
try running in release mode
Release mode?
it could be hardware
Im using Microsoft Visual Studios
change your build configuration to Release
debug mode has a bunch of boilerplate that fucks performance
yeah
Ok so how to change to release?
I only have Build, Build Order, Debug, Intellisense, and Package Manager
you should also catch promise errors inside callback functions @lament reef
It is
👀
But only Build, Build Order, Debug, Intellisense, and Package Manager options are available
Is there supposed to be a released option?
Remember, Im using Microsoft Visual Studios
nah, i had the same issue
in debug mode, things like WebClient.DownloadString() would take fucking ages
I played just a little bit with d.net the only thing I remember regarding this was RunMode
could be, I tried it like a year ago or so
@earnest phoenix what vs version are you using?
hi help
code https://hastebin.com/efapokijul.cs
error https://hastebin.com/udutobilig.rb
stats.getInfo is not a function
What is the solution?
read the docs
not using stats.getInfo 
😅
how should i do to make a simpliest timer in C++?
wait is there a discord lib for c++?
How do you put the time next to a ping?
wdym
Like Pong! (189ms)
ping! ?
How do you calculate the time?
ooh well you calculate or retrieve ping from your lib
timer start and after a minite the timer stops
😫
in python it's datetime1 - datetime2
(each variable is a separate instance of datetime.datetime.now(), one at the start and one at the end, BUT not the best solution, consult your library's docs)
Or set timeout to do with functions
Does anyone have a code solution?
like t.setTimeout in javascript
What is the code for Microsoft Visual Studio?
I am a coding nub
@earnest phoenix do u know what coding language you are using
did u have to do something like npm install discord.js ???????
or pip install discord
In Disord.Net is a member with the name Latency under IDiscordSocketClient (I think)
or telk pls install my meme
https://s.put.re/zbYdtun.png wasn't IDiscordSocketClient, but in the abstract class is one 🤔
umm in python there is exec so maybe
Basically an eval command @austere meadow without.. eval?
im not making an eval command
What's your end goal?
what you exactly mean with "dynamic" calling a function
https://please.zbot.me/QHoOjEVz.png
i have these default values in a model, but they are stored as a function
i want to loop over all of these values so i can compare them against a user in my database and if they are missing any values, i can add them
so i'd want to do something like
for (let i in Object.keys(User._defaultValues)) {
Object.assign(this.defaultValues[i], profile.get(i))
}
why you use a in with .keys()
says "object[value] is not a function"
does .userID() work?
well u could do
for (const thing of User._defaultValues) {
thing(); // should work IIRC
}
oh fuck you guys are geniuses ok i got it going
oh
That doesn't solve your specific problem, but software engineering wise it also sounds like a lot of mutability is involved.
Maybe an approach with immutable data objects might help you out in other ways.
thank you 
np
i think changing in to of fixed it
its a collection isn't it? (or a map?)
honestly
after all this time ive used javascript i dont really know the difference between in and of
most of the time i just use in and it works
pretty sure in only gets the indexes and of actually grabs the object
for/of is way faster than for/in and in your case you already used .keys() to get an array and for/in would give you the index of that array and not the actuall value
thats how i see it lmao
Js is weird yo 👀
ah okay
no u
thanks again 

https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/for...of
some good examples here
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/for...in
and here
The for...of statement creates a loop iterating over iterable objects (including the built-in String, Array, e.g. the Array-like arguments or NodeList objects, TypedArray, Map and Set, and user-defined iterables), invoking a custom iteration hoo...
dang it, now i wanna do some JS but im doin design 
Why is my server count N/A
because you haven't posted it
^
Request the guild
oh no
i got a strange erron in my log....
ERROR net.dv8tion.jda.core.requests.WebSocketClient - Encountered exception on lifecycle level
ideas?
probably discord had a minor outage
Shit happens
You'd have a different error mate
Check the docs again, the command you are trying to run isn't a function. (stats.getInfo(username, platform).then(data => {)
French - Vérifiez à nouveau les docs, la commande que vous essayez d'exécuter n'est pas une fonction
Quelle est la solution à ce problème
@abstract mango Thanks for the help
np :p
this is probably dumb.. but how do i set up shards?
What lib?
discord.js
Oof sorry I never used d.js
😕
I need to learn sharding in c#
Sharding in C# really isn't that hard ;P
I hope not :) once i get time to sit down and work on stuff again, ill need to get it done.. need my bot back on track.. Almost 100 servers a day for the first 3 days.. then rip by discord, should have learned sharding before
Idk.. they said i need to do sharding once over 100 servers.. atleast thats what the email said in response to why i got rate limited
I actually thought its more than 1k its just a safe place to start
yeah what trixter said
i'm sitting on 8900 servers and 4 shards and i'm just fine
They told me 100.. idk
what trixter said it's the recommended one
usually music bots require more shards
because of how discord handles VC join/leave/move
Maybe was a typo. I didnt write them back
does anyone here know how to write to a file on heroku? yes, yes, i know heroku is bad, but still.
i feel the same way when i have to tell people i wrote a bot in javascript
"i know javascript is lazy but still"
not helpful
why would you want to write a file on heroku 
heroku doesn't even save databases, so what do you think?
its a temp file anyway
does anyone here have any experience with gm for node.js? if so, i need help.
(mention me)
how to do you get the guildcount in python?
You mean, post the server count to DBL?
Just get it from bot's page?
Thanks
len(bot.servers) in async.
Im on rewrite 👌🏼
Wanna hate me forever?
Yeah sure.
without using discord.ext.commands :3
Nah jk love ya.
I am totally not lazy to check it out.
im waiting for someone to send a PR to fix it all inline with d.ext xD
I can see someone doing that

I PR's my weird code to DBLPY lib, waiting for any comments on it. 😂
At least, it works properly for me.
Damn asyncio. 

To handle the commands the way you like. 
Why can I not write to the /temp/ directory in heroku?
?
Because you don't @lament reef
wdym
I think it will work
or BinaryIO
Relative
but
if it's short lived
If it's image processing then heroku probably won't be good
then what do i use?
proper vps
i need a good free host
free hosts are never good
like do (see pins)
Sorry
Use SkySilk.
use GalaxyGate
Free hosts cannot handle image manipulation
It's at least any reliable. The free plans are not quite bad.
SkySilk is an actual VPS. :p
ok
@slender thistle so is galaxy gate
It's free or just cheap?
$5 for 1 core cpu, 2gb ram, 30gb disk, 500mbps net, unlim bandwith
Well, I am a poor kid. 
i use the $10 one tho
It's great
Scaleway (2.99)
Okay, that's quite interesting.
but i actually use DO
ovh uptime is shit
hoi
network performance *laughs*
how can you not control ur shit
oh ok
nor the uptime of the bot, you must set it yourself
👍🏼
Hello
I have this problem:
Traceback (most recent call last):
File "/usr/local/lib/python3.5/dist-packages/discord/ext/commands/bot.py", line 846, in process_commands
yield from command.invoke(ctx)
File "/usr/local/lib/python3.5/dist-packages/discord/ext/commands/core.py", line 374, in invoke
yield from injected(*ctx.args, **ctx.kwargs)
File "/usr/local/lib/python3.5/dist-packages/discord/ext/commands/core.py", line 54, in wrapped
raise CommandInvokeError(e) from e
discord.ext.commands.errors.CommandInvokeError: Command raised an exception: HTTPException: UNAUTHORIZED (status code: 401): 401: Unauthorized
Mindfuck
How can i authorize?
I have this code
@commands.command()
async def cacazip(ctx):
embed = discord.Embed(title="Commands", description="All commands list", color=0x7cedd9)
embed.add_field(name="help", value="Show this menu", inline=False)
embed.add_field(name="$multiply X Y", value="pil", inline=False)
embed.add_field(name="$greet", value="Gives a nice greet message", inline=False)
embed.add_field(name="$cat", value="Gives a cute cat gif to lighten up the mood.", inline=False)
embed.add_field(name="$info", value="Gives a little info about the bot", inline=False)
embed.add_field(name="$help", value="Gives this message", inline=False)
await bot.say(embed=embed)```
What is wrong?
I just try from await bot.say to edit in await ctx.send
But again, error
unauthorized to edit a message? never seen this before 🤔
are you sure you are trying to edit own message?
@tardy hatch We first, you forgot to indent after async def cacazip(ctx):
or is it
I can't tell
i was just gonna change the token afterwards
you are overestimating strangers on the internet smh
/:
tbh its my bot, if something happens, its my fault. thank you though
anyways
Traceback (most recent call last):
File "C:\Users\---\AppData\Local\Programs\Python\Python36-32\lib\site-packages\discord\ext\commands\bot.py", line 846, in process_commands
yield from command.invoke(ctx)
File "C:\Users\---\AppData\Local\Programs\Python\Python36-32\lib\site-packages\discord\ext\commands\core.py", line 367, in invoke
yield from self.prepare(ctx)
File "C:\Users\--\AppData\Local\Programs\Python\Python36-32\lib\site-packages\discord\ext\commands\core.py", line 345, in prepare
yield from self._parse_arguments(ctx)
File "C:\Users\---\AppData\Local\Programs\Python\Python36-32\lib\site-packages\discord\ext\commands\core.py", line 304, in _parse_arguments
transformed = yield from self.transform(ctx, param)
File "C:\Users\---\AppData\Local\Programs\Python\Python36-32\lib\site-packages\discord\ext\commands\core.py", line 212, in transform
raise MissingRequiredArgument('{0.name} is a required argument that is missing.'.format(param))
discord.ext.commands.errors.MissingRequiredArgument: self is a required argument that is missing.```
i get that error
2018-05-20T00:46:27.305074+00:00 app[worker.1]: { Error: ENOENT: no such file or directory, stat '/tmp/output-299708692129906692.PNG'
2018-05-20T00:46:27.305077+00:00 app[worker.1]: errno: -2,
2018-05-20T00:46:27.305080+00:00 app[worker.1]: code: 'ENOENT',
2018-05-20T00:46:27.305082+00:00 app[worker.1]: syscall: 'stat',
2018-05-20T00:46:27.305085+00:00 app[worker.1]: path: '/tmp/output-299708692129906692.PNG' }
gm(request(img))
.flip()
.magnify()
.rotate('green', 45)
.blur(7, 3)
.crop(300, 300, 150, 130)
.edge(3)
.toBuffer('PNG',function (err, buffer) {
if (err) console.log("!!!!!!!!!!!!!!! " + err); return;
process.env['output-' + message.author.id + '.buf'] = buffer.toString('utf-8');
fs.writeFileSync('/tmp/' + name, buffer, function(err) {
if(err) {
return console.log(err);
}
message.reply("Success, reading file contents...");
});
});
Any help?
ye
so?
i need help with discord.js
@ruby dust if you've sent a message in a channel and no longer have permission to send messages to that channel, you won't be able to edit any of your messages there
and @dusty shuttle whats your problem
if you dont state what you're having trouble with, we wont be able to help
Oh I totally forgot about that too
@verbal night aware
why my python had stopped and BOT offlined when my computer is idle for several minutes?
any errors ¯_(ツ)_/¯
does it go to blank screen too? or did you turn that off
Is there a lib for a thing that you can restart your code like a boot manager for code in Java
maybe this
Java
oh sorry idk
wdym restart your code
easiest way is killing the process and starting a new one
but that needs something else to start the process after it exits
Yeah that's what I am looking for
is it possible to use a for loop, but exclude a specific object in the list?
If x {continue}
That's python-related.
Ah.
oh yeah
/* Remove div height if user is using an adblock */
#cdm-zone-01:empty {
height:0px !important;
}
^ CSS code to hide the div when the user is blocking ads
this does not remove the ads, just the div when it's empty (meaning the ad is blocked by an adblocker)
excuse me for the question: i have my own server, powered by my own bot, and said server has 30 members. is it against ToS to send a DM to everyone in there containing a google form for server feedback?
it's not against the ToS to send a DM to everyone, but it is against the ToS to spam the API. For example if you send a message every few seconds you are fine, but if you are sending in 5 times a second is no ok.
Maybe doing @everyone would be better
Or a role ping, because people tend to suppress @everyone mentions.
Gl with users who have DMs off. :^)
Use a userbot instead. 
i won't
myselfbot
30 is not that many
if it was only 30 members i'd do it with my bot, but wait 1 second between messages
👌
just don't mess up and end up DMing everyone in general
DM everyone from here.
hola
if(message.author.id !== '256460316660072448') return;
for (i = 0; i <= message.guild.members.size; i++) {
setTimeout(function(){
message.guild.members[i].send('blah blah');
}, 1000);
}```
(node:19077) UnhandledPromiseRejectionWarning: TypeError: Cannot read property 'toLowerCase' of undefined
warning.js:18
at new User (/media/shon/01D371210ADE0BE0/fs.js/node_modules/fortnite/src/User.js:13:73)
at /media/shon/01D371210ADE0BE0/fs.js/node_modules/fortnite/src/Client.js:61:24
at <anonymous>
at process._tickCallback (internal/process/next_tick.js:188:7)
(node:19077) 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(). (rejection id: 1)
warning.js:18
(node:19077) [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.
Wouldn't that just schedule all of them to run after 1 second, and since the loop would complete quickly (since it doesn't wait for the timeout to complete before continuing on the code), they'd all happen at about the same time?
@spring mesa
how do I get a link of an image embedded by a link in the message?
🤔
Yeah, but from what I recall, when you call settimeout it doesn't wait for the timeout to complete first. It will just set the inner function to run after 1 second, and continue with the loop not waiting that 1 second before continuing.
right
still it doesn't send
setInterval(function(){
var i = 0;
for (; i <= message.guild.members.size; i++) {
console.log(message.guild.members[i]);
}}, 1000);```
returns a lot of undefined
Is message in the scope of the inner function?
What do you get if you console log only message?
let me see
nothing seem to happen
not even an undefined
wait
i added a return to stop the madness
but the object is in fact present
As far as I know you can't change a a variable
So it has to be let I = 0;
@spring mesa
Try let i = 0;
i give up
Ok
i have no idea of how to do that wihout spamming the api
You can change a variable, that's why it's called a variable. var has been around forever, let is the new thing.
double neuron::eta = 0.15; // net learning rate
double neuron::alpha = 0.5; // momentum
neuron::neuron(unsigned numOutputs, unsigned myIndex)
{
for (unsigned c = 0; c < numOutputs; ++c) {
outputWeights.push_back(Connection());
outputWeights.back().weight = randomWeight();
}
m_myIndex = myIndex;
}
void neuron::updateInputWeights(Layer &prevLayer)
{
for (unsigned n = 0; n < prevLayer.size(); ++n)
{
neuron &neuron = prevLayer[n];
double oldDeltaWeight = neuron.outputWeights[m_myIndex].deltaWeight;
double newDeltaWeight = eta * neuron.getOutputVal() * gradient + alpha * oldDeltaWeight;
neuron.outputWeights[m_myIndex].deltaWeight = newDeltaWeight;
neuron.outputWeights[m_myIndex].weight += newDeltaWeight;
}
}
double neuron::sumDOW(const Layer &nextLayer) const
{
double sum = 0.0;
for (unsigned n = 0; n < nextLayer.size() - 1; ++n)
{
sum += outputWeights[n].weight * nextLayer[n].gradient;
}
return sum;
}
void neuron::calcHiddenGradients(const Layer &nextLayer)
{
double dow = sumDOW(nextLayer);
gradient = dow * neuron::activationFunctionDerivative(outputVal);
}
void neuron::calcOutputGradients(double targetVals)
{
double delta = targetVals - outputVal;
gradient = delta * neuron::activationFunctionDerivative(outputVal);
}
double neuron::activationFunction(double x)
{
//output range [-1.0..1.0]
return tanh(x);
}
double neuron::activationFunctionDerivative(double x)
{
return 1.0 - x * x;
}
void neuron::feedForward(const Layer &prevLayer)
{
double sum = 0.0;
for (unsigned n = 0; n < prevLayer.size(); ++n)
{
sum += prevLayer[n].getOutputVal() *
prevLayer[n].outputWeights[m_myIndex].weight;
}
outputVal = neuron::activationFunction(sum);
}
@jolly mist whats the problem
could someone help me with my discord.js bot, im trying to get the bot to do something when someone clicks a reaction on the msg
Hey, I need help with customizable prefix command (discord.js)
Please DM me if you can help
@spring mesa message.guild.members is a collection, not an, array
maybe that'd be of use
@abstract mango how would tha tbe used
do you have a on ready handler in your code?
like whenever your bot starts up you get a message in your console that says 'ready' or similar
yeah like that
bot.on lets you handle events that the d.js client emits
the messageReactionAdd event is one of them
i'm not sure if it's reactions for all messages
why u need it to be async tho 
you should probably use samuraistacks's solution :p
Anyone know howda do a customizable prefix for diff servers?
messageReactionAdd is only for cached messages
database
i use json for now :v
@knotty steeple could u explain awaitreactions to me
^ up there
there's a example here :^)
thanks guys
PM me if ya like
np
np
although there are examples on Docs
Rip me I guess
guys im a little confused as to how its used can i pm someone to tell themn my exact predicament
nou
click PresenceData, then click ActivityType
ok ty
http://prntscr.com/jkbcf2 @knotty steeple
@abstract mango see the number, in the collection that is, is that milliseconds, seconds, minutes?
isn't type 3?
uhh the collection in what? :p
yeah if you're referring to type that's just a number
oh
that time is ms
probably timestamp
dsa
it doesnt seem to work tho
i doubt you can react that fast
I usually do 20s in these scenarios
oh ok
it doesnt appear to be working
author is undefined
did I do it right
Hello there
Anyone have a code for shutting down python bot from a command?
For example.. stop or shutdown
I believe there's a method in the sys module that gracefully kills the process
Just call that in a kill command and there you go
sys.exit() I think
Yup
wew
Thanks
or you can use bot.logout like
await bot.logout()
it should exit that way as well
does it kill the process though?
Ok, you know the 8 ball command?
I need the parameters to make the bot read what you're saying
maybe
language?
are you using discord.net?
Yeah
are you using the CommandService?
Yep
You can use the Remainder attribute
so like in the method signature
public async Task EightBall([Remainder]string question)
So, like [Remainder] string text
yes
Ok, thanks
:D
Hello
hi
oof
Hello. Does anyone know how I would be able to make the image overlap the other content? My animation keeps bieng cut off by the container above it
mm
relevant code:
.bot-img img {
border-radius: 50%;
overflow: visible;
animation: float 4s infinite alternate;
animation-timing-function: ease-in-out;
}
@keyframes float {
0% {
transform: translateY(0);
}
50% {
transform: translateY(-15px);
}
100% {
transform: translateY(5px);
}
}
move it below where you're trying to place it?!
is it possible to use any databases with python, I'm more use to python and would like to see if I can get a DB for my bot
I wanna set like server prefixes and i wanna know how to do that
sure, there's tons of databases you can use with python
it's hard to recommend one database for you without knowing what your preference is or what you find simple, but googling gets you a long way
if it's a small bot or you can just use a .json file or something
medium bot maybe use sqlite
large bot postgres, mongodb, mysql, cassandra
but yeah, google and do your own research
I would advise against using json files as a database no matter the scenario, it's a pretty bad practice
I only use a .json for my bot's blacklist db
which is only updated like once every other week
You have to check on guild available / join though right?
Which means you need to constantly read the file (which is inefficient)
the blacklist? that's only for users
and there's only 12 users blacklisted so far
I thought only excessive writes caused locking
reading a static file without writing shouldn't be that bad
on another note
is it just me or is the https://qriusity.com/ not working
just returns an empty array for me
Reading/Writing is both locking/has problems
Databases don't always read from files
So don't confuse it being how databases work. There's a reason databases exist instead of just purely reading/writing to a file
lol, i hope everyone uses queries properly too. sql injection is a real thing.. even the top guy in Bot Developers role being funny, which reminded me of it
i dont understand this https://gyazo.com/bd53fa9d00c37a3f2d82dee037374c0a
image y u so small
im getting better at discord.js
ok is that development-related
development of coding skills
Please Dm me the answer, like this (age, sex, answer). What would you rather, be deaf or blind?
or just tag me
@earnest phoenix not development related at all, and asking for age is just weird. keep that shit out of here unless you are conducting a proper survey (for whatever reason) and go to #memes-and-media
-> #memes-and-media <-
Hmm my bot got declined because glitch.com suddenly made my bot go offline
Any fix?
^
What should I use then @spring ember
do using require on every command used is bad?
require?
why is it bad 
if its repeated then get a proper command handler
because guys on some discord server said that I should load the commands in memory first
why not require it on the file rather than every command
but Im having troubles because what exactly this load the commands in memory first
How do I send a DM to a specific user using their ID with Discord.js?
Fetch the user
@shell blade javascript bot.users.get('mylittleID').send('Hallo');
lol
I'm not really familiar with .get(), so I should probably learn that.
Actually surprised your bot has auto levelup messages xD
And it doesn't work as well
anyways
Huh?
no not u
I searched through it and couldn't find anything 😕
https://discord.js.org/#/docs/main/stable/class/User?scrollTo=send this is how to DMs
https://discord.js.org/#/docs/main/stable/class/Client?scrollTo=users this returns collection which has the get method to lookup by id
Basically a collection is an array with its ids mapped
@sinful lotus requiring when an user type a command can potentially do unintended stuff like $../random_file
In best cases bots crash
@halcyon abyss yep I already fixed that
I did a require on boot of my bot
then put them in ram
then just get them from ram
So I dont need to do a require every command ran
@fluid basin I'm getting this error when I try DMing myself:
- TypeError: Cannot read property of 'user' of undefined
what ur code?
One sec, I'll get it.
Sounds like user is not set
const prefix = process.env.PREFIX,
Discord = require('discord.js');
module.exports = {
name: 'suggest',
description: 'Suggest a feature for Translator directly to the developers!',
aliases: ['sugg','s'],
usage: `\`c>suggest <any ideas>\``,
cooldown: 300,
execute(message, args, bot) {
args = message.content.slice(prefix.length).split(/ +/).splice(1).join(' ');
if (message.author.id != '250811963334983683') return;
return bot.users.get('250811963334983683').send(args);
}
};
can the bot dm you?
Do you mean does it have permission?
permission to dm you?
Yeah
so does it
Yes, it does.
I just tried logging bot and it said undefined.
Ohh, I hadn't declared bot yet lol.
@fluid basin I understand the php in the name. I'm looking for a server client like phpmyadmin but with flask rather then a desktop client.
or a hacky way to use phpmyadmin with flask
Phpmyadmin probably is not the way with flask
then what is?
Umm you want a manager type of program for flask?
It's just an SQL manager
Use MySQL client for windows
Umm you can host phpmyadmin server probably
I tried doing it on another port via nginx but php just won't work
I wouldn't be here if it was working
cooldown on command.. hmm
how do I do that?
like the way I can fix it in like 10 min*
Pretty easy just use datetime and compare it
there is an example on an idiots guide ;p
but yea what builder said
oh, wheres that idiot guide @knotty steeple ? XD
thx mate 😃
anyone know why READ_MESSAGES is deprecated?
use VIEW_CHANNEL instead
thank you
could someone hmu with some help via dms, Discord.JS bot please and thank yous
Ask the question here and someone will help you
how can i make my bot do an event when a reaction is added to a msg
so ah need halp
https://developer.mozilla.org/en-US/docs/Web/CSS/border
https://developer.mozilla.org/en-US/docs/Web/HTML/Element/hr
The border CSS property is a shorthand for setting all individual border property values in a single declaration: border-width, border-style, and border-color.
The top is for doing it with css and the bottom is for doing it with html @earnest phoenix
I don't think there is a way without iterating over the map, but you shouldn't fetch by name
Okay how do you create a reaction collector (discord.js)? This code doesn't work:
var msg = null;
message.reply("Hello").then(m => msg = m);
setTimeout(function(){
msg.react("❌");
message.createReactionCollector((reaction, user) => reaction.emoji.name === '❌' && user.id !== client.user.id, { time: 60000 }).on('collect', console.log);
}, 1000);
(Not real code, just for test purposes but still, it doesn't work.)
node.js (discord.js)
if(bot) return
depends on the language
does anyone know?
@bot.event
async def on_message(message):
if message.author.bot:
return
await bot.process_commands(message)
add this peace of code into your main file
thanks deivedux
on discord?
for anime @earnest phoenix?
weebhook 
@lament reef did you got it to work? I can help you if not
bot reacts but nothing happens when you react?
yes
send code
you are creating the collector on the received message
but you are reacting on the reply
xD
anyway I'd suggest you drop timeout because its not proper way to handle promises, either use then nesting or better await
@spring bone
you can set the background color as transparent?
;-;
body {
background-repeat: no-repeat;
background-size: cover !important;
background-attachment: fixed !important;
background-image: url("link") !important;
}
</style>```
use that
@spring bone
👍
If i want a color hexadecimal i set background-color yeah?
@earnest phoenix
(sorry for the ping)
yes
yes
ty
👍
Mascu, idk which buttons youre having issues with, but you can set them to have transparent backgrounds
@mental solstice sad
?
im not sure what youre saying lol
what to change the color to white
The background is done, what is missing is that I want to change the color of the letters to white
.bot-stats {
color: white;
}
ok
might have to put !important
#bot-stats
Inspect element is always a thing :^)
yeah
np
#ffffff > white
@elder rapids ur #fff
No u
https://letters-of-the-alphabet-are.xyz/fmd3uBfa.png Can this be changed?
You're #ff0000
or no?
why would ya want to
```check: (message) => message.channel.type === "text" ? (message.guild.owner.user.id === message.author.id ? true : false) : false````this crashes my bot on this server ONLY???
wtf
Idk why not give error
? true : false pls no
Also wtf
@earnest phoenix u cant change the color of an image with css.. but you can change the color of the text below it
So much embeded if else
how should I do then?
@mental solstice https://letters-of-the-alphabet-are.xyz/nehhyRp6.png this?
.titleandvote {
color: white !important;
}
@earnest phoenix you can do message.guild.ownerID
To find the owners id
But that's besides the point
https://letters-of-the-alphabet-are.xyz/sc0Ny1Fi.png @mental solstice this?
inspect the webpage
The only way to change the icon is to manually change the image color
whats the problem with? true : falsewhat should I use instead?
see what class/id it is then ask for help on css here
what browser are u using Mascu?
gae
(no homo lmao) XD
chill yo I aint gay XD
Ye
It fixad 15 problems and errors lmao
whipping out the big XDS
lmao
@earnest phoenix if you think about it, ? true : false adds absolutely nothing
instead of condition ? true : false you can just do condition
if you really need a boolean out of it, you can Boolean(condition), but you probably don't
ternary operators 
ternary operators are good if you aren't a retard about them
@earnest phoenix I see why .user of owner is undefined
It's because the guild owner isn't cached
yes
now it finds guild oner
which it didnt befor
(meme == true ? true : false)
ultimate meme
oh yes







