#development
1 messages ยท Page 504 of 1
if you do when its autocompleting it shows a list of them
wait actually
what is your warnings.json supposed to do
one
use hastebin
or
what do you actually need help with
do you know how to make a json file
use a database
I need help
Discord.js
Where?
@frank forge send me a link to your code i might be able to help'
in the on message
add if (msg.author.bot) return;
@earnest phoenix inside the .json file put {}
and next time
just learn to code
and use a database
^
since you don't know how to do this
I'm going to assume your stealing code
yes
200%
yes you are
yes
just admit it
is it that person who you're paying $50 a week
whats the friends name
also
lmfao
you pay $50 a week for that garbage?
nope
if your friend even exist why can't he make the json file for you
jonny
this guy
you are paying $50 a week for not even a bot with a database?
yeah and

sir
ok pays $50 a week for a json run bot
you are getting scammed
im not being a dick
lmfao
i would pay $1 max a week
I shall abstain for the time being

i can redirect to you to an JavaScript tutorial
im breaking
of the rules

Its just that
tfw the hoister is saying others are being dicks 
nope @earnest phoenix i use sublimetext, but thanks for the list
now let's not discriminate
$50 seems steep
honestly if you want a bot make it yourself
$1 a week is what i would pay max
i like because plugins and auto sftp uploads
sure hope so
wait
also bet he's hosting on glitch.com
Surely you aren't making anything back though if it's $50 a week
but like
ohdear

I work for Oliy yet recieve no pay 
um
what are you good at in website @earnest phoenix
you both work for him and pay him
ew

there are things I want to say but my status does not permit it
Hey guys i don't know what event for update avatar in discord.js
but
$200 A WEEK FOR A DISCORD BOT
ohmy
that's not even worth it unless he's paying you back more than that
200 a week for hosting? wtf
very
lool
don't think that's a good thing
which is enough for 40 bots
even more, because you can easily run multiple bots in a single 5$ vps
I'm running 5 bots on my pc
double doubt
"i have 20 more bots"
doesn't know how to make a json file
stand back boys
k
our little HTML hero is on the case
I should think so
it'd be a travesty otherwise
thats still html
what am I even reading anymore
how good are you at html
lmao
There are lot html of coding guys
what do these elements do:
- pre
- details
- summary
- picture
- link
- script
- main
no searching
@earnest phoenix your website must look really basic then
summary offence is the least serious offence in UK law and is a type of case heard in the Magistrates' court
no its not @earnest phoenix
no
no
Who needs css when you can do a ton of 1 pixel img tags to get the look you want
whats the a tag
what is the style tag
thats not even proper html
<link>dhdjdjdj<link> guys I'm an hipper text markdown language programmer
Lmao
u r idiot
@earnest phoenix I'm gonna have to ask you to calm down once more
Lelelel
stop claiming to know html lmao
yes, you are the face of cool and aloof
are text tags a thing
nope
i dont think so
i googled it
ohmy
its not
and thats not even how you use link
it's headers and paragraphs right
yeah
where's text coming from???
isnt it <a href=""></a>
<p>
"i'm really good at html"
not even proper html
lol
theres not any text or link right
doesnt even know basic html
<p>hey nice text</p>
wait no
link is an element but completely unrelated to "links"
link is for stylesheet
yea
Link pills in a stylesheet lol
yeah
<link rel ="stylesheet" href="">
^
@earnest phoenix do you have a website?
and <a href="lmaorekt"> is for actual links right
Yeah
@earnest phoenix spam my dms pls
I mean
Ffs

we can actually code unlock u lol
@earnest phoenix that might count as ads, I'd hide it quick ๐
big
i deleted it
Pls
is that even proper html
Meme
well the paragraph tags are for text
lmao did u copy that from the internet
ez clap
that's on par with
<BigText></BigText>
<SmallerText></SmallerText>
<EndOfPage>```
Ew
Yes
yes
Very much
@earnest phoenix
show me some work you've done
moose i thot your gif was a toggle for a sec
goes offline
blew my mind
till it repeated
what
BOILERPLATE
Ffs
yes
No
its not needed
He's a pro guys, he's using Boilerplate code
Shitty boilerplate at that
like give me a link of a site you've made @earnest phoenix
handlebars & a node BE > raw hmtl
goes offline
my site is best site
2018
im starting to learn some react
My site is shit
Hmm
im just used to angular
Really
Do you even know how to sign a contract
so you're not a master coder
@earnest phoenix OI
ree discird us glitching soo much
yes
ow my eyes
thank you kindly
gonna cmd r
@queen sentinel convince oliy to add a grammar nazi bot
there its fixed now
lamo
Lol
hold on
Lol
so you code ONLY in html
what kinda pages are made then? ๐ค
Nice.
Run it through some tests before you add your bot to the list.
gonna get into webdevelopment if it's that easy to make money
Most important thing is make sure your help command works.
I'm 14 and now I'm ashamed to have something in common with you
If not, back to the drawing table.
yes ping
same lmfao
imma go onto fiver
150 a week for raw html? imagine what i could be making with a socketio, express, handlebars setup
charge $150 a week
millions
ez
Ilr
And now, time for me to do what I generally never want to do:
Use Visual Studio.
wait
Lol
vim is nice but ok
LOL
no
I need to learn more vim stuff
don't tell me you can
no you can't
you cannot
you really cant
even I know that
You can also code a Discord bot in C++.
But that's if you want to make your head explode.
but html is markup
mhm
bots are not pages
html isn't a programming language you can code a bot in
Anyone who says otherwise does not know what a programming language is.
isnt there d.js web
nor a programming language at all
if you can make a call to an external page
you can make a bot
It's not a programming language, it's a markup language
Or they're new to the scene.
So learn it
Lmfao
No
paying money for some guy to make it for you !== learning js
Don't leave
How old are you?
Because then you can't add your bot to DBL.
he did it
Youngsters these days (in America) would crash if they went to school in Vietnam.
noe
What a hero

clap and a half for this man
To who?
Go follow me on Instagram @idgafrasheed
to whom* @grim elk
gross
Lol
that's something that belongs in #memes-and-media ๐ค

Probably not.
i also
@earnest phoenix did u use discord bot maker
loool DBM
There's a bot maker too?
a program on steam that makes a bot for u
So are most of us the only people who made a bot the old-fashioned way?
DBM on discord store whenโข
$10?
Yes
Seems like a scam.
yep
no
its for basic bots
have fun adding a database
$50 a week sounds like a scam
lol
$200 a week sounds like a scam
indeed it is
getting paid $150 for basic html sounds like a scam
I'll pull up Visual Studio on Dingus 10 and make one in C++ because at least then I'll have something that probably won't suck
Wait this is #development?
$5 a week sounds like a scam
lol
I really need to pay attention to what channel I'm in.
alright kids
it really is because of these people who cant 
you've had your fun can we go back on topic kthanks
K
hey if you dont call it shitpost im not going
rip shitpost
Ok
i dont know where to go anymore
haha yes
i made my own discord client with a hardcoded button for shitpost
Quick question: Does DBL have an API in C#?
@grim elk its a HTTP API, but there is a C# library for it
Now to do something that will teach me a lot of C# (and give me a headache):
osu!lazer on mobile.
Getting the shard (JS)
(guild_id >> 22) % shard_count
correct?
Oh alright can't do that
How is that not js tho
guild_id bitshift 22 modulo shard_count
@sick cloud
that looked like python
Nah. I'm trying to get a shard for another bot based on the guild id provided
That code can be used in many languages and you will most likely get the same output.
where do i report bugs
Yeah I can't use the eval. I've seen multiple people say the shard can be calculated like that
o nvm
What library are you using? @visual surge
There's this bug in the discordapp login
it keeps logging me as this different Xevious yet on my phone it logs me as me
logout in browser
i did tho
https://discordapp.com/channels/@me -> settings -> log out
thanks fam im dum
If a bot's status on dbl is ???, does that mean that the bot is not in this server?
Ah got it thanks
i found another cat api http://www.catapi.co.uk just sharing because idk im bored and why not lol its also UK xD
@sick cloud
Are someone using enmap for economy database ?
= God
:(
Helpme @uncut delta
What help you need
leveling system in event message
Like the xp grow
And level up
Im forgot about all that stuff because json lmao
Hmm
So level up system
There is already an example in the an idiot guide and it's easy
You just need to set data then getProp the current data + random xp growth
Then setProp
enma points 
The set level + 1 when your xp reaches at certain number
sad when somebody on another shard tries to get their points
yes
@earnest phoenix i use enmap-mongo
why not just use a database instead of enmap aka scuffed sqlite wrapper
Give me the link from anidiots guides
No shit sharding problems
Im will learn it
yeah except if somebody wants points on 2 shards, it will store it on each shard ant not update, unless you .fetch() every time
in which case there is no point in enmap


Shards just make everything more complex
its actually is exclusively since enmap 4 iirc

they dropped other providers cos evie couldnt be bothered
really
so now its just old versions which are mostly broken
especially enmap mongo (only one worth using)
so u have to fork it
Im not really know about english language
because evie is smartโข
My english so bad
Practice.
Always do that

โข

Just some easy english language i can
enmap mongo with changefeeds 
@uncut delta where the links ?
thanks
ya enmap with changefeeds was the shit
but then again, you should be fine with internal sharding
"no issues with version 3"
"you know nothing"
fetch(key) {
return this.db.get(key);
}
fetch doesnt even work 
and you can use internal sharding until around 10 shards sooo
are u dumb
Well i don't use shading yet
no shit
Huh ok
works 100% very gud

In evie tutorial she using enmap.ensure
Huh whatever
Im really don't know about that
tho it should probably work at small scale such as yours
Or try real database
Humm iwill try it soon
Make sure to put it in message event
is there a known workaround for reaction events not firing on messages that aren't cached
yeah, give me a sec to find it back
client.on("raw", packet => {
if (packet.t === "MESSAGE_REACTION_ADD") {
//ur code baka
}
});```
listen for raw
there
or that lol
tu log le truc, ya l'id du message dedans mais je sait plus c'est quoi le truc exact
raw not documented anymore lul
rip
it is
Hi, I have a question on putting my bot online
For some reason it doesnt want to find my file? even tho its there
(sorry if this is the wrong channel, im new)
Make sure that path is correct
it is
Also it's the right place
C:\Users\ziggy\Desktop\DiscordBot
thats literally the place where the file isi
and as u see in my cmd its the same
You do not have bot.js
It's json
You have bot.json

? isnt it the same?
json != js
json and js aren't same
so I should save my json file as a .js instead?
I say you learn how to code
๐๐๐
haha laughing with people who are trying to learn internetheroes
What
U wot
is MESSAGE_REACTION_REMOVE_ALL valid
Lemme see
I could just console log and test but eh
Fuck all my bots are down
it is
guys
this is important
how
instead of showing this
how can i make it show this
Apache 
.htaccess
Restrict access to files and directories using .htaccess. Disable directory browsing and prevent access to certain files or filetypes
Are someone know how to make when some user update their avatar i can log it ? In discord.js
Anyone know how to fix this error?
- UnhandledPromiseRejectionWarning: TypeError [ERR_INVALID_ARG_TYPE]: The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type object
const { Util, RichEmbed } = require('discord.js'),
{ get } = require('snekfetch'),
{ Canvas } = require('canvas-constructor');
module.exports = {
name: 'emote',
description: 'Make the bot say anything!',
aliases: ['None.'],
usage: '{prefix}emote <server name> | <invite link> | <description> | <emojis>',
cooldown: { time: 3, users: [] },
async execute(message, args, bot, prefix) {
if (args == '') return message.channel.send(':info: Command usage:``' + prefix + this.usage.slice(8) + '``');
args = args.join(' ').split(' | ');
if (!args[1]) return message.channel.send('You need to give me an invite link to the server.');
if (!args[2]) return message.channel.send('You need to give me a description of the server (or "none").');
if (!args[3]) return message.channel.send('You need to give me at leasat 1 global emoji.');
var emotes = args[3].slice(1).split(' '), urls = [];
for (let i = 0; i < emotes.length; i++) {
emotes[i] = emotes[i].replace(/</g,'').replace(/>/g,'').replace(/ /g,'');
await urls.push(`https://cdn.discordapp.com/emojis/${await Util.parseEmoji(String(emotes[i])).id}.png`);
}
var ems = await new Canvas(Number(250*urls.length), 250), width = 0, emoji;
for (let i = 0; i < urls.length; i++) {
emoji = await get(urls[i]).then(res => res.body);
ems.addImage(emoji, 0, 0, 250, 250);
}
ems.toBufferAsync();
message.channel.send(new RichEmbed().addField('Guild Name', args[0], true).addField('Invite Link', args[1], true).addField('Description', '``' + args[2] + '``').setColor());
message.channel.send('', { files: [{ attachment: Buffer(ems), name: 'emojis.jpg' }] });
}
};
This is the code I'm using.
@wicked summit use the userUpdate event
Can anyone tell me please how to add a command to my bot so I can see what servers invited him and also on the website to show me how many servers my bot is on?
To show server count on the website, use the dbl api
To find what servers your bot is in, check your libs docs
For server count: https://discordbots.org/api/docs
why this not woring :(:(
const discord = require('discord.js')
const Discord = require('discord.js')
const {prefix, PREFIX, footer, owner, ownerID} = require('../../settings/config.json')
exports.run = async (message, args) => {
const client = new Discord.Client({disableEveryone: false, autoReconnect: true});
if (message.author.id !== ownerID) return message.channel.send("You are not authorized to use this command.");
message.delete();
let announce = new discord.RichEmbed()
.setAuthor("Announcement From ")
.setTitle("Callumok2004")
.setDescription(args.join(" "))
.setFooter(footer)
client.guilds.get("497153287779516417").channels.get("501467078172082176").send("@everyone", { embed: announce })
message.delete();
}
error
(node:16) UnhandledPromiseRejectionWarning: TypeError: Cannot read property 'id' of undefined
hmmm
error occurs wehn command is run
Client, message, args
Seems like a case of not properly passing the message object into the command
That is what i was thinking about
but it was working until i added client to a const instead of async
and added this
client.guilds.get("497153287779516417").channels.get("501467078172082176").send("@everyone", { embed: announce })
ye, it didnt work outside of it either
You use command handler?
ye
i have my reasons
Show me code where you run command in message event
it is set for client in async but for a reason i aint doing that
im not sayin y
@earnest phoenix please don't tell me you're creating a new client on each command
no, im npt
just dis 1
But why god?
Still why
You only need to create it once
meh, i was testing something, doesnt matter
Lol. It does matter
Creating two clients will give unexpected behavior
Also if you're making new client in command
You need to .login
It too
And you need to have smth like this
}```
cause message in code you sent is actually client
i had new client so the bot could ping @everyone but it cant
@fierce thorn
how can i make that work^^
- it needs to have permission
- const client = new Discord.Client({disableEveryone: false});
i could always ping everyone before
Well he needs administrator permission if everyone ping is disabled
yes i know that dad

Giving bots admin permission is stupid
no
Hey i have a problem with my code , it make an error like this : ```TypeError: Cannot read property 'name' of undefined
my code:
if(message.content.startsWith(prefix + "userinfo")) {
const user = message.mentions.users.first() || message.author;
const embed = new Discord.RichEmbed()
.setTitle(`Informations about`)
.setDescription(`${user.username}` + "#" + `${user.discriminator}`)
.setThumbnail(user.displayAvatarURL)
.setColor('RANDOM')
.addField('ID', user.id, true)
.addField('Username', user.username, true)
.addField('Discrim', user.discriminator, true)
.addField('Status', user.presence.status, true)
.addField('Bot', user.bot, true)
.addField('Game', user.presence.activity.name, true)
message.channel.send(embed)
}
What's the all the files contents
wich files
The file this code to gave is in
It's the thing with presence (Game)
yes
Oh
Yea
that's the problem
It's its undefined just display no game
ik
but all file not work bcs of this
all code*
On master it is
Oh
Huh
because isn't rich embed for stable? @west raptor
somebody make it
@earnest phoenix pls refer to this https://discord.js.org/#/docs/main/stable/class/User?scrollTo=presence as .activity.name is not a function
ik
but how
do you know how to eead the docs?
yes
then whay would you say how
if you know how
oh lord, that embed.
"but how"
to make good code to see the game
..
๐
5 sec later
yes
..
ok so are you saying you do know how to make game thing
learn javascript
lol
I'd improve the embed before trying to make it work.
@earnest phoenix if you're not going to learn what's the point of even addressing the problem
this
user.presence.activity.name
That embed has too many characters in it that if someone with a lot of roles or a long name will return an error and won't send cause it excess the 1024 charatecer mark
so
what i can make for don't have the error
and don't excess 1024
charatecer
and make my code work
Well one you don't need a ton of information in a single embed
Then why have this much information on that embed?
1024
for make good userinfo
so
its not really good if you put all the same info teice
how this guy make this
code
ik
but how make better embed?
You don't need to know if that person is a bot if the person will have a bot tag on their name in the member list
You have two joined servers field, which could mean that you copied and pasted it
not my bot
You don't need created at field
Status isn't need cause you will know if you look in the member list
Guild based in isn't need
ye
User info isn't needed either
i want only that
.setTitle(`Informations about`)
.setDescription(`${user.username}` + "#" + `${user.discriminator}`)
.setThumbnail(user.displayAvatarURL)
.setColor('RANDOM')
.addField('ID', user.id, true)
.addField('Username', user.username, true)
.addField('Discrim', user.discriminator, true)
.addField('Status', user.presence.status, true)
.addField('Bot', user.bot, true)
.addField('Game', user.presence.activity.name, true)```
but
name is undefined
Why would you include a person I'd?
Well yeah, cause it can't read an undefined function
It only works if the user is doing something
Your embed isn't a good embed, I would encourage you to make a new one using less information, I bet everyone here would agree with me on that
not me
i want to have this info and not less
so
how to make superior embed
better embed*
i rly need
https://hastebin.com/upimumibok.cs does this actually work?
if its not stolen why are you asking if it works
also just because its from the souce code doesn't mean your not stealing it
why wont my iframe thing work
<iframe src="http://www.donohook.com/" width="100%" height="100%"></iframe>
The most advanced and customizable donation bot for your Discord server. Easy to setup and 100% free. Start now before you miss donations!
ew
i don't believe the long desc supports iframe tbh
that bothers me so much
also that stolen code dream
RIP
CloudFlare ๐
@topaz fjord k thx
So with my bot when I try to run my commands it says it needs to be at the top of the server role but yet it already is
did you code it to check that?
Yes
then maybe your code is the problem
does anyone know how to fix this
prolly delete the sqlite module and then reinstall
ill check sec
probably reinstall
its annoying cause it worked like 20 mins ago
i just restarted my box
omfg this is so annoying
now its saying fucking permission denied even with sudo
debian 9
oof
Can someone explain this error? discord.errors.HTTPException: BAD REQUEST (status code: 400)
Idk
Are there any tutorials that tells me how I may connect my bot to my website and get like server stats?
@waxen quest you can get the server stats from discord bot list
Bro
And put it in your html
"you can" does not really tell me how to do it
what language is your website in?
html, css, js
does your bot have a database you can get the stats from?
I want to connect my bot to my website too so that it shows the state
you can open your database to external connections, or you can code a simple api inside your bot
and have your website get data from it with php
Thanks I'll take a look at it later today
@waxen quest if you fine anything let me know , I will let you know if I find anything
Alright ๐ค
websocket to ur bot

or write stats to db and display on website
i need help
in python i want to add command help
but it is already registered so how am i gonna add it?
What u using?
Hey
hey
host ur own hastebin
rippers
https://ghostbin.com/paste/5harq
If anyone has suggestions for this setup feel free to say something
Java - 11.1 - JDA
How i make Website for my bot to add it "Discord Bots"











