#development
1 messages · Page 1279 of 1
Use the docs.
ReferenceError: guild is not defined at Object.module.exports.run (C:\Users\admin\apemodicus\commands\warn.js:35:27) at Client.<anonymous> (C:\Users\admin\apemodicus\index.js:40:34) at Client.emit (events.js:315:20) at MessageCreateAction.handle (C:\Users\admin\apemodicus\node_modules\discord.js\src\client\actions\MessageCreate.js:31:14) at Object.module.exports [as MESSAGE_CREATE] (C:\Users\admin\apemodicus\node_modules\discord.js\src\client\websocket\handlers\MESSAGE_CREATE.js:4:32) at WebSocketManager.handlePacket (C:\Users\admin\apemodicus\node_modules\discord.js\src\client\websocket\WebSocketManager.js:384:31) at WebSocketShard.onPacket (C:\Users\admin\apemodicus\node_modules\discord.js\src\client\websocket\WebSocketShard.js:444:22) at WebSocketShard.onMessage (C:\Users\admin\apemodicus\node_modules\discord.js\src\client\websocket\WebSocketShard.js:301:10) at WebSocket.onMessage (C:\Users\admin\apemodicus\node_modules\ws\lib\event-target.js:125:16) at WebSocket.emit (events.js:315:20)@earnest phoenix it didnt work either
@autumn aspen how can i do this😅
Please stop posting walls of text.
I'm not going to spoonfeed him code, if you want to know how to do it learn how to do it.
The code was literally posted above.
OMFG @earnest phoenix STILL DONT WORK
Error?
ReferenceError: msg is not defined
at Object.module.exports.run (C:\Users\admin\apemodicus\commands\warn.js:35:27)
at Client.<anonymous> (C:\Users\admin\apemodicus\index.js:40:34)
at Client.emit (events.js:315:20)
at MessageCreateAction.handle (C:\Users\admin\apemodicus\node_modules\discord.js\src\client\actions\MessageCreate.js:31:14)
at Object.module.exports [as MESSAGE_CREATE] (C:\Users\admin\apemodicus\node_modules\discord.js\src\client\websocket\handlers\MESSAGE_CREATE.js:4:32)
at WebSocketManager.handlePacket (C:\Users\admin\apemodicus\node_modules\discord.js\src\client\websocket\WebSocketManager.js:384:31)
at WebSocketShard.onPacket (C:\Users\admin\apemodicus\node_modules\discord.js\src\client\websocket\WebSocketShard.js:444:22)
at WebSocketShard.onMessage (C:\Users\admin\apemodicus\node_modules\discord.js\src\client\websocket\WebSocketShard.js:301:10)
at WebSocket.onMessage (C:\Users\admin\apemodicus\node_modules\ws\lib\event-target.js:125:16)
at WebSocket.emit (events.js:315:20)
@earnest phoenix
wtf
STOP SPAm bruh
-__-
dudes....
what tim
dudes....
@quartz kindle its MoHa
Do msg.content.split()[0] for title then msg.content.split()[1] for description @cobalt spruce
@earnest phoenix help me
@autumn aspen What's your message defined as
Try message.guild.iconURL()
ok
if you have message => { then its message. if you have msg => { then its msg
@quartz kindle 
Try message.guild.iconURL()
@earnest phoenix lmao I forgot mine is defined as "message"
🤡
you always have to use the names you give to them
@earnest phoenix lmao I forgot mine is defined as "message"
I read that, stop tagging me please
oh sorry
I need to go do stuff, if you require help join discord.js' official server.
lol poor discord.js
They made the library 🤷♂️
you interpreted that message wrong
I don't think i did
I meant they made the library so they should deal with the consequences of them having to offer support
astro i think u Oofed it up
Why are you not slicing the command at the start?
Okay i'm getting carried away, im gonna go.
Someone help them please.
woops
hai, in sql im trying to get a user id using cur.execute("SELECT userid FROM quicktest " f"WHERE (userid = {id});")
the table looks like userid | info --------+------
but it only returns none- ive definitely added the id into the correct column, any ideas why it doesnt work?
``` if (message.content.startsWith(${prefix}embed)){
if(!message.member.hasPermission("MANAGE_MESSAGES")) return message.reply('Sorry, you do not have permission!');
var title = message.content.split()[0]
var saymessage = message.content.split()[1]
var sayembed = new Discord.MessageEmbed()
.setTitle(${title})
.setDescription(${saymessage})
message.channel.send(sayembed);
}```
@quartz kindle
can u help
Do you not have an args array?
no
...
@cobalt spruce you're not splitting by anything
you need to specify by what do you want to split
by space? by comma?
var title = obj[1];
var msg = obj[2];```
then do it
wait
const [blah, title, msg] = message.content.split(" ");
where can i send my code
var obj = message.content.split("");
in a bin service, like pastebin, or hastebin, or others @earnest phoenix
then you post here the link to it
var obj = message.content.split(" "); splits your content by it's spaces
obj[0] = //embed
obj[1] = title
obj[2] = y
Regarding to the picture above.
Pastebin.pl is a website where you can store code/text online for a set period of time and share to anybody on earth
xDDDD
my doesent work :c
Your obj is merged into 3 fields only
//embed title text another space
will not work
//embed title text
well, let him figure it out
oh
the bot dont write anything
the bot is online and ready and when i someone muted the bot dont write anything
sry for my english😅
if i should have heard the bot doesn't want to write
first of all the class is wrong
lol
async run(message,args) {
not
run = async (message,args) => {
var title = obj[1];
var msg;
for(var i = 2; i < obj.length; i++ )
{
msg.concat(obj[i] + " ");
}
.setDescription(`${msg}`)```
@cobalt spruce
@earnest phoenix
xDDD

This might be a really easy and basic question but...
How can I use a discord bot (using discord.js) to execute a command in its own console from discord?
I'm using Nodemon.JS and I want to run a !restart command in discord, that makes the bot execute rs in its own console
what do I use in code? console.log() or console.error() or...?
.log and .error both send the command as data and not as an actual executable, OR I might be doing it wrong cause I couldn't find any other functions for console
@boreal iron wats dat?
Your code to catch all fields into the msg var
.replace the commas?
uhhh
Or .join(" ")
Yes
No
.split(' ').join(' ')?
cuz it didnt work with
has anyone here used elasticsearch on their bot server?
too smooth @boreal iron thanks for help
i would like set prefix a word how to set? example musti musti help
i set prefix but not working musti help
working mustihelp
send code
in hastebin or something
const {prefix} = require ('./config.json');
if(message.content.startsWith(`${prefix}command`))```
in config.json
do
```{
"prefix": "musti "
}
@livid otter
@proven lantern just post here. Don't DM me
like this or something
.reduce((acc, keyword) =>
acc.where(`keywords.${keyword}`, "==", true),
db.firestore().collection('matchmaking-queue')
).get();```
that's my current search
// = space?
it has to match exactly
no
i can set prefix but
i set prefix musti command working mustihelp
i would like musti help
not working
i feel like elastic search will grow too fast
im in mobile can u add me firend? i send you after
man
10-20 minutes
just send here when you can
and why would u even use musti as prefix
because it's his bot
no?
What a prefix is, is irrelevant
Ok
@faint prism @cobalt spruce
config { "prefix": "-", "sahip": "636811597410598922", "token": "token" }
command
exports.run = async(client, message, args) => {
message.channel.send(`test`)
}
exports.conf = {
enabled: true,
guildOnly: false,
aliases: [],
permLevel: 0
};
exports.help = {
name: 'test',
description: '',
usage: ''
};```
token leak
You gotta regen the token
that's the old token
nvm u need to generate new token
no problem
nah token is old
So I used
const { exec } = require("child_process");
if(command === `${prefix}rs`) {
message.delete();
if(!message.member.hasPermission("ADMINISTRATOR")) return message.channel.send(":no_entry_sign: **Sorry!** I can't let you do that.");
exec("rs", (error, stdout, stderr) => {
if(error) {
console.log(`error: ${error.message}`)
return;
}
if(stderr) {
console.log(`stderr: ${stderr}`)
return;
}
console.log(`stdout: ${stdout}`);
});
}
but when I use ${prefix}rs , the output is: rs is not recognized as an internal or external command. So I looked into it and found this:
https://stackoverflow.com/questions/33879896/how-to-execute-the-start-script-with-nodemon
but I'm not sure if that is what I'm looking for?
exec("rs",
that's literally like typing rs into terminal
of course it is going to show an error
unless you have a program or alias under that name
so how do I do it?
too smooth thanks for help
@cobalt spruce
Np can’t go on... imma driving
Ok
i how to set prefix?
so how do I do it?
@junior turtle by parsing the message content
instead of just "rs"
I can reproduce your issue like this lol
because you're sending the string "rs" instead of the message content
oh okay
just don't forget to parse the message content otherwise you'll just get:
!rs someCommand is not recognized as an internal or external command.
i have this weird problem
for some reason when i start my bot, it connects with the wrong bot account regardless of what i put as API key
i'm using discord.js
i did copy code from that bot but changed the api key obviously, but it still connects with the old one
it logged the key and it is the key for the new bot
does anyone know if this is a known bug?
check the token smh
check the token smh
@dire obsidian i did
change the world, my final message, goodbye
i did a console.log and it returned the correct token
why do you think it;s the other bot?
just make in the ready event: bot.client.tag
well this bot sets a status and that status appears on that bot
the id of the bot
no
client.user.id is it not?
because that would be client.user.id
bot that i want to use: offline when i start it
old other bot: is online and has that status that i entered in the bot code
tr yetkili varmı
How to check if an args is a mention or a user or id?
message.guild.member(message.mentions.first());
Insert: 10,680 ops/s
Find: 43,290 ops/s
Update: 8,000 ops/s
Remove: 11,750 ops/s
How good is this for db

@silver lintel You could use the above method, but that will only work for user IDs and user/guild member objects (since it's the first mention, IDs won't work either).
If you wanted to check if one argument is a mention or user ID, you could use regular expressions. In fact, if you're using Discord.js, you can use MessageMentions.USERS_PATTERN if you only want to match user IDs.
If you wanted to match both mentions and user IDs, you'd do something like /<@!?(\d{17,})>|(\d{17,})/g, in which the first group will be the user ID.
ID regex:
/(\d{17,19})/```
Mention regex:
```js
/<@!?(\d{17,19})>/```
Tag regex:
```js
/(.*)#(\d{4})/```
ok thanks
can't a snowflake be as long as it wants (aka it's not constrained to 19 characters long)?
I know, just for know 19 max
snowflakes are unsigned longs (64 bit numbers)
I have not seen a single user with id length of 20 so, 19 is what i go for now
How would I use the regexp tho?
@earnest phoenix nah snowflakes are Twitter users
(ok I'm gone again)
this is your snowflake limit
so like ~21 characters?
@placid iron unironically the concept of snowflakes (the ids) originated and was created by twitter
yeah
under the right settings the system can generate thousands of unique ids within a second
i made a system that implemented it once
I just wanna make a quick comment,
An better alternate for quick db is nedb
I would highly recommend, recommending people nedb instead of quick db as their starter database. This db is much better, and reliable then quick db. It is fairly easy.
I just don't want people to struggle like me ):
Erwin I am totally with you on that
But right now as back up I need to use something like this for my server
Eventually I'll use postgress or something else but right now I just want to move to something better then json file
The last code change (not counting readmes/no feature updates) was 4 years ago on the github repository.
yikes

Thats what i mean. You dont want to struggle. Then why start everything on a low tier database? Why setup everything so that in 2 or 3 weeks you start to realize you are going to have to port everything and turn all the work futile? Trasfering data manually, compatibility, you might lose a bunch of data transfering from databases if they arent compatible. Its much better to start already at a decent one rather than having to move 3 or 4 databases along the way. While it may not sound like you it, your laziness now will have consequences down the line, moving databases isnt as easy as you think
Right now in my json file i only have around 20 user information (id, balance)
json db be glitching so i wanna move to something easier
then figure out those better dbs (I don't get lot of time to work on it)
You dont need a lot of work
I am not smart
If you want the bare bones, you just need 3 queries. Select, update, insert, thats jt
Dont give me that, just put effort into it
You don't know how hard i have worked
I do
Cuz im a dev too
Think i started knowing all of it?
Dont bring pitty into this dude
We all started from scratch
okay well
i use sqlite so i can change the db format quickly and easily and once i stop needing to do that i will move it all to postgresql. i have a script that handles all DB transactions anyway so i just need to basically change 4 variables
And u also dont have 3$ for a vps?
And u dont have a computer?
client.commands.get('addrole').execute(message, args); is giving me issues. TypeError: Cannot read property 'execute' of undefined anyone able to help its late and im lazy
the command was not found
Hard to explain --> Student using school's mac book
Clint****

someone cant find their clint

F
you should be noting your own issues when recommending something
hm?
you are recommending something thats mac compatible
ok give me a break XD its spelt correct in the code
cuz it fits your needs
like i said, you arent chose postgres because its hard, its because of compatibility
I just wanna make a quick comment,
An better alternate for quick db is nedb
I would highly recommend, recommending people nedb instead of quick db as their starter database. This db is much better, and reliable then quick db. It is fairly easy.
I just don't want people to struggle like me ):
which doesnt match with what you are saying this
its not a starter lib

its a lib for those who cant install another db
How do I make my bot have 1 or 2 commands vote locked?
INSERT INTO table (collumns) (values)
SELECT (SOMETHING) FROM table (OPTIONAL WHERE/LIMIT/ORDER)
UPDATE table SET (QUERY)
thats all you need to get working on postgres/sql
i shit you not
calm down
update 
im trying to explain to you why your logic doesnt make any sense
the caps is how we write in SQL
commands are UPPERCASE and the rest lowercase
Are you saying postgres isn't compatible with mac?
How do I make my bot have 1 or 2 commands vote locked?
@supple oriole
im saying you should TRY postgres before you call it 'hard'
rather than relying on worse db's that dont even dent the functionality of postgres
I looked up a video to download it, it was messy 
okay i will soon™️
i mean, its pretty messy imo but if you make your own functions then its poggers https://img.rovi.me/S3pbWoHPqD.png
which is a UI
^ that isnt postgres but it ports with like 1 change
Jeez I swear erwin in love with postgres 
How do I make certain guulds be able to do certain commands?
https://ptb.discordapp.com/channels/264445053596991498/272764566411149314/758274946148335620
https://ptb.discordapp.com/channels/264445053596991498/272764566411149314/757284441818398822
https://ptb.discordapp.com/channels/264445053596991498/272764566411149314/756992325321883700
https://ptb.discordapp.com/channels/264445053596991498/272764566411149314/755935293647093813
https://ptb.discordapp.com/channels/264445053596991498/272764566411149314/755931408731472034
this should be enough

development anime only

https://img.rovi.me/FJqkv66OyT.png oh i even started on my port
anime girls holding programming books
code geass is
ngl

@placid iron hey
Can I help me with database stuf
Bc im trying to make a currency system
Sorry, I just got into bed
Legit it hasn't been respond to commands
It works at one time and the second time it doesn't work
Wdym?
Check console 😂
ACKKKKKKKKKKKE
Sa
@earnest phoenix did the person adding them disable it? also did you enable admin on the invite link?
No and If im not wrong doesnt 8 mean its admin
this is the link tell me if its wrong
so confused
that doesn't look like an 8
what's with all the chars after it
No idea.. thats what im wondering
should be just 8
its in 891 servers so I went to add a guildCreate event so it sends a welcome message but it was missing acc so im trying to fix this now
so just 8?
omg im so dumb
thank you
it works now 😦
My apologies for asking such a dumb thing
@earnest phoenix gimme a sec to start my beta branch rq
?
I realized i fixed it for some reason it had like 69%30
after it
thank you guys ❤️
thats not the issue though
this big number in the middle is where the permissions are calculated
that 69% in the end has nothing to do with it @earnest phoenix
ah okay
so the issue is the middle
wait no the big number is the client id..
isnt it?
wait
wtf
oh yeah you right
ignore me
permissions= is where the permissions are at

my bad

hey, so how did some of you guys who develop larger discord bots decide between implementing premium features into just one bot vs supporting an entirely separate premium-only bot?
well there is no way i could put my premiums in a separate bot
its tightly coupled to its main features
how do you detect if the bot has this (ex. READ_MESSAGE) permission on the message channel?
discordjs
permissions
like this can be SEND_MESSAGE
you using the wrong syntax btw
this refers to obejct
yoiu just want permissions
no need to call it this
that returns yourself
instead of message.guild.me.hasPermission()
then?
im questioning if there is something like message.guild.me.hasChannelPermission()
guild.permissionsIn(channel) => coninue
actually
i think its <member>
not guild
yeah its <member>.permissionsIn(channel)
hm ok
use member
not author ok
well yeah authors dont have permissions
ikr i alr figured
since permissions are inherited in guilds
i feel like theres an easier method message.guild.members.cache.get(client.bot.user.id)
.me im assuming like u said before
message.guild.me.permissionsIn(message.channel)
message.guild.me.permissionsIn(message.channel).hasPermission()
would this work?
Hi``
whichever suits your needs.
app development
in js what defines an object as null?
Hi
opengraph tags
Ok I'll study about them thanks 🙂
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! evobot@0.7.0 start: node index.js
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the evobot@0.7.0 start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /home/runner/.npm/_logs/2020-09-29T02_10_43_206Z-debug.log
exit status 1
your app exited with code 1, which means it wasn't a clean exit
that's as much info as you gave us
-bots
-bots
discord probably won't let you
there a way to have it so Yes this has a line break turns to ```
Yes this has a line break
how i can delete messages more 100?
@main chasm
You can easily
?
Just break each into pieces of 100
Like if person says to delete 500
Delete 100 then 100 then 100 then 100
And so on....
there a way to have it so
Yes this has a line breakturns to ```
Yes this has a line break
@karmic compass You can do something like this:
<string>.replace(/[\r\n]+/gm, " ")
very cool thanks
Thanks @quartz kindle

-bots
This user has no bots
-bots
This user has no bots
-bots
O
i think as my bot is not connected to discord bot lists so it is not showing it
-bots
@oak cliff
-bots
-testing @granite trout @earnest phoenix @earnest phoenix
@granite trout @earnest phoenix @earnest phoenix
Please use #commands or #265156322012561408 to test/use bots.
okie
Continued use of luca outside testing channels will result in a mute.
&^^^^
My bot is not here
@oak cliff but you uae luca command outside testing channel
I'm special

@granite trout your bot isnt approved yet and we dont invite bots anymore
Special boye let move to #general-int
But luca counts as a bot and needs to be used in bot channels thanks
Yes.
MongoDB vs. SQL vs. Firebase Firestore vs. CouchDB who will win
The one that's the most appropriate for the task you need a database for
Every database is different, there is no one true database.
Every database is different, there is no one true database.
@umbral zealot are you telling me all these databases are fake
smh

Databases aren't generic and need to be applied in proper use cases
Watch someone come in and recommend PostgreSQL
If you're making a mobile app you might use firebase, but if you're doing an offline game, you wouldn't, you'd use maybe sqlite.
Databases aren't generic and need to be applied in proper use cases
@slender thistle so probably firestore and couchdb won't make it for a botum
If you need nosql storage you go with a nosql database, if you need relationships, you go with SQL.
node12, supports which version of ecmascript?
If I need relationships, I go outside smh Evie
but for a website that's literally hosting on Firebase? It would be dumb to host on Firebase and not use their own databases
I just go on Tinder but ok.
well firebase hosting isn't even the best free host 
node12, supports which version of ecmascript?
@rocky hearth 3.4 - 6 iirc
vercel and netlify are the kings rn
we're talking databases, not hosts
but for a website that's literally hosting on Firebase? It would be dumb to host on Firebase and not use their own databases
literally hosting on Firebase
Point being, you use the database that actually is right for your current task.
You analyze what you need and which one is appropriate. So no one database wins. They all do, for their own purpose.
then i should probably go with Firebase's Realtime Database cuz I need to sync shit
Bruh stop everyone knows to use json for every database

If that's what you need, then yeah, sure fine! 
lmao only noobs use JSON
Okay but
chads use insert db
let's actually think objectively and stop with the hate on JSON db
If you need sync between devices, we certainly won't be suggesting to sqlite, right?
no
well json in db isn't that bad (ex. mongoose/mongodb)
Unless you make an API for your SQLite database
but json as the db is awful
Define awful
And yet I got a million downloads on my enmap module which directly relies on sqlite, because it's mostly small-ish bots made by beginners. Again, purpose is everything 😄
@compact oriole And yet, NEDB is a great database.
Really bad practice, should be avoided as much as possible
What should be avoided is to directly read and write json files. That's bad, it's horrible, don't fucking do it.
async i/o goes brrrr
guys i want to make a ai which can make humans extinct i need some help pls
We're like: I hate directly using JSON databases but I love stuff like MongoDB which still store stuff in JSON-like documents
@hazy sparrow go help with the skynet@home project 😂
I store JSON strings in SQLite and it's awesome.
This is my code
if(humans = exist) {
extinction = true
}
¯_(ツ)_/¯
lol
oh yes
guys i want to make a ai which can make humans extinct i need some help pls
@hazy sparrow make a gofundme i'll fund it with my less-than-a-dollar pocket money
mutating humans in an if statement

Will it work?
galaxy brain
logically, no
SyntaxError: Cannot use lefthand assignment in condition
Will it work?
technically, yes (check the calendar which year it is there is way too much weirdass shit happening in 2020)
@hazy sparrow if it's 2012 how the fuck are you using Discord
hey @umbral zealot just wanted to say you're the goat and thank you for being apart of my early days of getting into bot development 👏
Its 2020 in the international calendar
time travel
🐐
I don't even remember who got me into bot-dev
we're getting off topic
York/Evie were for me
but I remember Tonkku from those times
in early 2017
I'm going to take "you're the goat" as a weird colloquial compliment 😂
then I expanded into web dev 
I don't even remember who got me into bot-dev
i remember tho
it was danku mehmerh
I'm going there next, August.
nice
I was already somewhat experienced before coming into botdev...
been learning React and Vue for a while now, it's pretty good but bloated xP
so it was a fast start for me
reactjs+razzle+chakra-ui with an express backend to make a blog.
lmao @sick cloud you're born on my sister's butt day happy butt day boi
nextjs+postcss+tailwind+graphql with serverless backend = a lot of services
nice
ah yes, serverless backend
I'm going into graphql next actually. new job, new tech
some madlads starred my not-meant-as-a-joke message but ok
I'm going into graphql next actually. new job, new tech
@umbral zealot good luck to ya
depends on the data/project
some madlads starred my not-meant-as-a-joke message but ok
i was the first to star it lul
SQL stands for sequelize?
Structured Query Language
good luck to ya :Salute:
Thanks ^_^
guys is making tictactoe ai easier or minesweeper ai
@hazy sparrow making the core game is easier than the AI part
ye but which is easier to make ai
ye but which is easier to make ai
@hazy sparrownull
Because i want to make 3d minecraft in discord
Are you feeling alright?
oh no
@earnest phoenix just saying, es6 is ancient stuff already
node implements the latest ecma as long as you are using the latest version
so node 12 has es10/es2019
Api spam with decent framerate, bad commands, slow response, rendering images is expensive, if you use emojis is even worse, controls are janky
the whole premise of making minecraft in discord is stupid
doable? if you are a good developer, peobably
else its a waste of time
sorry to give it to you
you'd need a relay with a vm or instance of minecraft running and take screenshots of it or render your own minecraft-ish engine
just in case you were ACTUALLY unironically planning on doing it
so node 12 has es10/es2019
@fluid basini'm deprecated...
u can only get 5 frames per second if u make smthn on discord
can't you read 
still bad
@compact oriole
I said it would still be bad
but less bad
u can only get 5 frames per second if u make smthn on discord
@lament meteor You can get more than that
Have a back-end SUPERCOMPUTER calculating a fuckton of game shit then generating images for every single frame then send it to the client's computer instead of discord why the fuck would you play a shit version of minecraft on discord anyways
r/wooosh actually r/comedycemetery
you can't even get 4 fps
and fuck off redditor
as Discord kinda slows you down on edits
and fuck off redditor
@compact oriole I haven't been on reddit for many months
as Discord kinda slows you down on edits
@compact orioleI'm both deprecated and rate-limited
How do you make your server "public"?
m
m
@carmine summit thanks for the awesome help
you wouldn't get good fps
@compact oriole by the way that's actually how a Minecraft server works
1 FPS
My bot was deleted by one of my devs so now I need to reapply ._.
If editing the message every second
@compact oriole @slender thistle I'm talking about actual real minecraft servers not the discord shit bow pro said
you can literally host a Minecraft server on a host as bad as repl.it and it will be fine for normal users
no shit mc runs at 20tps
Does domain cause this
like dyno.gg comes
when we search
but my website is .gq
is this due to domain extension
Does domain cause this
@delicate shoreDoes domain.cause(this)is not a function
||find the joke here||
No, Google search results are personalized
oh
Domain Ltd doesn't matter
Then why doesn't my website show up
Of my bot
Google probably doesn't deem your website "important" enough
How to make google deem it "important" enough
Then why doesn't my website show up
Of my bot
@delicate shore because it either isn't indexed or the search queries aren't related enough to your website or it's because your website didn't make it through google's non-existent safe search filter or PROBABLY because it sucks
My only bet is to have people search for it
But even when people search it doesn't come up
all they get is top.gg - Black sheep discord bot
your site probably doesn't have seo
Oh yeah that
But even when people search it doesn't come up
@delicate shore read my message again
because it either isn't indexed or the search queries aren't related enough to your website or it's because your website didn't make it through google's non-existent safe search filter or PROBABLY because it sucks
maybe not indexed
all they get is top.gg - Black sheep discord bot
@delicate shore everytime i see that name i am back in kindergarden
your site probably doesn't have seo
This might be a viable option too, search it
ok
@delicate shore everytime i see that name i am back in kindergarden
@earnest phoenix You probably search Black sheep
search Black sheep bot
what do you mean by indexed
@delicate shore do you think if you edit a single file on a running node process it will automatically load in the changes? same happens for goggle if you just make a domain and expect goggle to index it into their MASSIVE list of domains it's pretty much a dumb idea wait up a few hours or so
fix me if i'm wrong i'm not into goggle shit
my sites SEO audit after using a day to make it good lul
@delicate shore you said search for Blek ship discord botum i did and nothing shows up
wtf when did I say that
I am indexed @slender thistle
I just doesn't show up in top
well ur site probs has bad seo
Does Go make things go faster like discord.go is discord but it "go"es faster
or none
Or like ??
faster in programming languages means strictly typed and compiled
I mean like
Responds quicker
Like discord.js takes 100ms, discord.go takes 1ms?
@karmic compass https://tryitands.ee
@compact oriole what website are you using to check your SEO score?
thx
Does bot.owner_name get the owner's name/username?
Yes
me discord.js guy ask @slender thistle he knows discord.py
afaik bot client don't have an owner attribute in the api
just make it say your username and your ID ig
But what if I change my username?
@delicate shore oof my website is ten times worse than your website but my SEO score is higher
@earnest phoenix what I do is on ready I save bot.owner as the my account which I fetched

Fetching from my id
How?
https://media.discordapp.net/attachments/734483510013984799/760293984026624000/where-is-the-context.png if anyone wants this please use it I spent maybe 16 minutes on it I can't remember it was a blur
Completely unrelated btw
Perfect
I would like help. Not memes.
With what
@earnest phoenix I explained it in small steps. Next would be to literally give you the code. Use the documentation and Google now
For all those people who find it more convenient to bother you with their question rather than search it for themselves.
Or I can just screenshot
Oh
retesting SEO score after doing some weird-ass shit on goggle search console
So I use await fetch_user(bot.owner_id)?
@earnest phoenix did you even try to google the question or atleast read the docs when we told you to? I am 99% sure you can't fetch the bot owner id
I don't know how bot.owner_is set so it's safer to just put your actual Id in
If you use bot.owner_id you have to set it manually basically
Use https://lmgtfy.com
@karmic compass its full of ads nowdays
they ruined it
so dont use it
whats the char limit on reason on the kick command?
whats the char limit on reason on the kick command?
@ionic shard 256
thank you
oops it's actually 512 @ionic shard
okay
Wait, could I use bot.owner_id in a string like await fetch_user(f"{bot.owner_id}")?
you can use 733751374465990726 too (your id)
await fetch_user(${bot.owner_id})
Censored my domain name cuz rules but LOOK AT THAT BEAUTIFUL SCORE
umm
Wait, but I need to make it an F string
codeco-discord-bot.code913.repl.co@earnest phoenix
How do I do that?
u odnt need to make it fstring
Proof?
fetch_user("733751374465990726") works
Wait, but I need to make it an F string
@earnest phoenix lmao python goes F at template strings
Oh
Ok
But no need to laugh in my face
@earnest phoenix your username and tag can be changed but your ID cannot be changed even if you delete your account
I already know that.
Proof?
I already knew that.
@earnest phoenix wow
@earnest phoenix no
you dont use strings for that
its an int
bruh
i already explaind this
So, should I just use fetch_user(id)
Why can't we use fetch_user({bot.owner_id})?
i said
its because bot.owner_id is only set if you manually set it
its the same as
bot.owner_id = 733751374465990726
bot.owner = await bot.fetch_user(bot.owner_id)
Oh ok
Wait, so I have put that on my on_ready event, and I am going to get the username for myself/the owner for the information command, do I use bot.owner_name or bot.owner.name?
where the fuck are those extra scripts coming from i only have three scripts for every webpage
php ?
when adding meta data to HTML do you type <meta/> or <meta></meta> or just <meta> without a closing tag
php ?
@ionic shard express.js in node.js and all files are HTML
maybe ur calling a page which has scripts and the page u called in also has the same scripts
so double call?
@earnest phoenix
also some of those fails are dumb
like not using Google Analytics
and not serving images from cnd, when im actually doing it
maybe ur calling a page which has scripts and the page u called in also has the same scripts
@ionic shard nvm figured it out it was my CDN making everything organized by a single javascript requesting for the CDN stuff files from the CDN provider (so 1 script on each page + the number of scripts my CDN uses)
what do you guys think of this
@earnest phoenix I prefer not to be pinged or DM'd for Python questions, thanks
the best description i can get after getting 75 on my grammar test:
<meta name="description" content="An easy to use fun multi-purpose bot with a plethora of stuff to keep you happy!">
do u guys put ur messages/error msgs in a json file and call them? like is it a good way of doing it?
do u guys put ur messages/error msgs in a json file and call them? like is it a good way of doing it?
@ionic shard JSON is good enough for that but i'll prefer.logfiles because it's better than storing a big-ass long string in a JSON file
I don't store any error messages and they're hardcoded in my code
humm
I don't store any error messages and they're hardcoded in my code
@slender thistlehardcoded error messages
Wait, so I have put that on my
on_readyevent, and I am going to get the username for myself/the owner for the information command, do I usebot.owner_nameorbot.owner.name?
@placid iron @earnest phoenix
Also yeah, you could just append your error string prepended with a newline
@earnest phoenix
applicationinfo has an owner property
You could also just get_user(bot.owner_id)
also repl
@compact oriole i'm switching to GCP in a few days as i said repl was a temporary host
but super pricy
@compact oriole when you hear me saying the name of a host the first thing that should come to your mind isthis guy's gonna try to get everything for free
how do you add google analytics to a website that is not hosted on google shit
It's script tag with src set to some Google link
is this a prefered way for kick command?
https://github.com/discordjs/discord.js/blob/v12/docs/examples/moderation.md
official example 
google analytics gave me this script after i created the property:
<!-- Global site tag (gtag.js) - Google Analytics -->
<script async src="https://www.googletagmanager.com/gtag/js?id=UA-178782277-1"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
gtag('config', 'UA-178782277-1');
</script>
do i just add it to every single webpage's <head> tag?
yes but the examples are meant to show you how they would do it with the bare minimum
wtf is script async
i think its a complete example only thing that is missing is perm check
nvm they are not using kickable
@valid frigate Script async tells the browser to download the script asynchronously, so that the page load is bot blocked while it is downloading. (the script is then executed as soon as its downloaded)
Yeah I was shocked when I first saw that's possible
real talk wtf is this
i just did a google search and nothing comes up is it like a beta thing
Fwiw, there is also defer, which can be used just like async, instead it downloads the script asynchronously and then executes after the page load is complete.

Which "this" are you talking about? Async?
so i saw in the example they are using this
// Now we get the member from the user
const member = message.guild.member(user);
// If the member is in the guild```
I am using
```if (!member) return message.reply('Please mention a valid member of this server');```
which one is more prefered?
what a useful CDN so fast
the 0 ms ones are my own browser's cache
the really high ones are the CDN's cache
No, I'm pretty sure async/defer is standardized html stuff. All major browsers support it (see here https://caniuse.com/script-async)
w3schools explains how it works here https://www.w3schools.com/tags/att_script_async.asp
wait what cdn are you using?
Oh, no experience w/ them, can't help ya
You can make money with it but the cdn is trash
@compact oriole just realized i am in an area with trash internet my friend is able to load the website fine
wait if i have meta data in my webpages they should display on discord link embeds right?
test: https://codeco-discord-bot.code913.repl.co/index.html
An easy to use multi-purpose bot with a plethora of fun stuff to make your server better!

Yes but does yours have a dashboard
ask him and he says same

what language is it in 
his is more for personal performance
@compact oriole you mean personal preference?
no
I think they mean like playing against yourself
@valid frigate english, brains is multilingual
owo 2 active users on site
I think they mean like playing against yourself
ye
including me
singleplayer type ting
you know what i meant 
and me :P
playing snake on my own site
i18n is that thing ill never get over
I should whip up a tic-tac-toe game too (without copying code from stackoverflow and codepen)
link to original creator
my trivia questions are from api (good api keep in mind)

so that's why no multilingual
but I could scrape all of them and store them myself
did you get lazy on making the question mark in the logo
my trivia questions are from api (good api keep in mind)
@compact oriole

there are 3700 hand made questions
yea
3 people now
one on mobile on the homepage
two guys playing snake
IMMA STEAL YOUR DATA HAHAHA
that's the word
I cba tracking that stuff
wdym
Extra work
:O

wdym stealing
:P
i have noscript enabled
there is an opt-out option
and nobody gives consent for ads
Doesn't ha have a bitcoin miner
it it automatically on
code also has crypto mining on their site

wtf

HAAHHAHAA
LOL
this is the reason why i use noscript
maybe
check my site

is code idiot??
@compact oriole always has been
I’d rather have ads
no trackers, no ads, no bullshit

Same @compact oriole 😩
i am gone
This emoji is from a server that is either private or unavailable.
but i can send the emojismh
I'd rather have ads and know my CPU isn't being used up for whatever the fuck the site owner wanted
um how can i check if the bot has permissions to send a message in a channel ? 🤔
shivaco, I wan't your opinion
well atleast the webpage will load fast cuz your pc is now a part of the CDN and isn't eating away at your resources enough to lag out your whole computer
would you rather have ads or your bandwith being used to serve data as a cdn?









i'm deprecated...



hardcoded error messages



smh