#development
1 messages · Page 591 of 1
1 ⃣
lol im confused
How did you even type the one before the keycap if the keycap came first
And how the hell did you even type the keycap
by using my brain
go to the website, copy the keycap emoji, paste it into the chat, press left arrow key and enter a number
Jaylon did you ever solve that?
Today's Big Mistake
Writing my bots with Discord.js, but writing the portal for them in Flask, which is python. 🙃
It worked @earnest phoenix
But it looks so fucked up
Thanks a lot
it looks different from the gif i posted above because i modified windows to have a twemoji font for emoji rendering so i can use twemoji in browser
hy. Im pasted the discordbotsapi python code and edited the dbl token, but its does not updating the server count
still says N/A
im creating a bot list . i need help with something
when someone submits their app how can it automactially post to bots page?
you're not getting help here for your own bot list
what are you even thinking? LMAO
xDDD
figure it out yourself
but me
if you ask again itll be a lengthy mute
Appending a ? to my URL, for example: mydomain.com/?code=lol redirects me to my 404 page
Why?
provide more information
Ok
So I am using discord OAuth2 thing
when it redirects me back to my site...
domain.com/?code=8324mxj4ithnfm
it redirects me to 404 page
http.createServer(function (req, res) {
let responseCode = 404
let content = fs.readFileSync('./page-not-found.html')
if (req.url === '/' || req.url === '/home') {
responseCode = 200
content = fs.readFileSync('./views/index.html')
}
if (req.url === '/login') {
responseCode = 200
content = fs.readFileSync('./views/login.html')
}
res.writeHead(responseCode, {
'content-type': 'text/html;charset=utf-8',
})
res.write(content)
res.end()
}).listen(8080)```
Im tried to change the asyncio timer but still not posts the bot server count
you're matching with the exact string
im think im a noob lol
yes
Okayyy thx
so how can i post my server count to the bot list? I tried everything. But the Discordbotsapi code doesn't work.
try some #312614469819826177
Ok
if (req.url === '/') {
}```
I want the user to be redirected to `/home` directory if he/she comes to `/`.. what should I put inside that ^?
I guess req.send('/home')?
I changed my idea and I am trying something else now
res.redirect('/home'); @vague chasm iirc
Ok
i'm having issues with my website could anyone help please?
dont ask to ask
just ask your question
My website is like...... i'm not very intelligent um i think it's like not working i don't know why sorry i'm not smart
provide more info
idk what the issue is though
is there any errors
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta property="og:title" content="DoneBot">
<meta property="og:site_name" content="Discord DoneBot">
<meta property="og:image" content="https://cdn.discordapp.com/avatars/553909681949507585/a6248662bedb805cdf817e8e48399caf.png?size=256">
<meta property="og:description" content="A discord bot trying to connect people through communities they love. Fun, featureful, and fantastic at what it does!">
<meta name="theme-color" content="#7289DA">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>GiveawayBot</title>
<!-- Bootstrap Core CSS -->
<link href="css/bootstrap.min.css" rel="stylesheet">
<!-- Custom CSS: You can use this stylesheet to override any Bootstrap styles and/or apply your own styles -->
<link href="css/custom.css" rel="stylesheet">
<!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries -->
<!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
<!--[if lt IE 9]>
<script src="https://oss.maxcdn.com/libs/html5shiv/3.7.0/html5shiv.js"></script>
<script src="https://oss.maxcdn.com/libs/respond.js/1.4.2/respond.min.js"></script>
<![endif]-->
<!-- Custom Fonts from Google -->
<link href='https://fonts.googleapis.com/css?family=Open+Sans:300italic,400italic,600italic,700italic,800italic,400,300,600,700,800' rel='stylesheet' type='text/css'>
</head>
<body>
<!-- Navigation -->
<nav id="siteNav" class="navbar navbar-default navbar-fixed-top" role="navigation">
<div class="container">
<!-- Logo and responsive toggle -->
<div class="navbar-header">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#navbar">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="navbar-brand" href="#">
<span class="glyphicon glyphicon"></span>
GiveawayBot
</a>
</div>
<!-- Navbar links -->
<div class="collapse navbar-collapse" id="navbar">
<ul class="nav navbar-nav navbar-right">
<li>
<a href="/invite">Invite</a>
</li>
<li>
<a href="https://www.instagram.com/arda_tiryaki1/">Instagram</a>
</li>
<li>
<a href="/support">Support</a>
</li>
<li>
<a href="https://paypal.me/OverdoneisHOT">Donate</a>
</li>
</ul>
what are you doing
what is the error
how can we help
i'm not smart
just explain the issue you're having omfg
can you paste the code into hastebin and not in chat, you're cluttering for no reason
I DON'T KNOW ANYTHING IM STUPID 😭
eh
@earnest phoenix it doesn't take a genius to tell us why you're asking for help
all you have to do is 1. tell us what isn't working
thats it
it says /login was not found
where are you getting that error
where are you logging in
of course it won't work
😢 i'm trying my best
you literally just copy pasted https://giveawaybot.party/ 's DOM
there's more than just surface html
well i tryed editing
so basically all you did was copy HTML and thought it would work on it's own
that's not how websites work
well i can't do anything
i either pay people or try learn it just won't stick in
please don't waste our time if you're not going to actually try
in all fairness it doesn't take a genius to learn how to do something
copying other peoples code is just not fair, especially if you weren't given permission
well to me i struggle with somethings so eh
unless giveawaybot's code is public (which i doubt)
and i just want a website
there are many free templates you can try out
^
why cant anyone ever google
google is scary
you have the internet at your finger tips
and plagiarism is your way to make up for that scam lol
maybe could one of you maybe try teach me or no....
no
we're not here to teach you
there are many free learning resources
there are services that do that, we're here to help existing problems on already existing projects
literally thousands, all it takes is a quick google search
google is scary
there
.-.
do you even own the domain
no its not a search engine
was referring to hot-dog
you have to buy the domain @earnest phoenix
mind if i ask how old you are? @earnest phoenix
15
visible confusion
^
ublock origin and greasemonkey anti adblock killer script = clean site
also
if you don't want to write all css yourself
just use a framework
like materialize
or even better use a SPA framework like react
and use something like material-ui
in english please
google.
it.
oh my god
if you keep going on and asking to be spoon fed about website stuff im taking action
when you say " im taking action" what do you mean?
mute, ban, etc etc
that they'll take action 🙃
o
yeh, imma stop now
anyways, i suggest picking up react
no
react?
you're wasting your time suggesting something like that to someone who doesn't know how to buy a domain or even setup backend
what is your bot even made in?
inb4css
the shit you dont see
js
better
so you wrote your bot with backend/frontend code but you dont know what backend is
😩
???????????????????
i wrote 60%
this is so stupid
yup
60%
im new to making bots, and i was wondering if there is any free service that run your bot for you, 24/7. id rather not have my computer on all day
Free or good take your pick
I believe Amazon AWS has a 12 month trial
thanks ill check it out
google and amazon are the best free hosts, but its free only for 12 months (google is still super cheap after the free trial is over)
other than that, heroku and glitch are completely free but they have certain annoying limits, like shutting down your bot after a while, which can be overcome with a few tricks and scripts
but they're still very limited in resources, google and amazon are far better, even with low amounts of ram
]]ping
ty
did it work? whatever you're trying to do lmao
lul
If bot has manage channels, does it necessarily mean it can read all categories? If not...?
passport oauth google help pls
@west spoke sorry, i mean category
Apparently it's not, though.
I still get missing access for category even when bot has manage channels
bots can always view all channels. they cant see the content in the channels unless they have read message perms
Im very sure no, putting into account channel overrides
But im not so sure for category
@fiery stream you mean google authenticator
passport google auth
yeee
No
ohh rip
huh
const { Command } = require('klasa');
module.exports = class extends Command {
constructor(...args) {
super(...args, {
requiredPermissions: ['MANAGE_CHANNELS'],
runIn: ['text'],
description: 'Add involved user to a ticket.',
usage: '<member:user>',
usageDelim: ' '
});
}
async run(msg, [member]) {
msg.channel.overwritePermissions({
permissionOverwrites: [
{
id: member.id,
allow: ['VIEW_CHANNEL', 'SEND_MESSAGE', 'READ_MESSAGE'],
}
],
});
}
};
hi i am trying to add user to private channel
it edits the private channel
and goes pubhlic
@simple bluff make so everyone role cant read it
So you assume everyone role is guild id?
I own a bot with over 2000+ votes a month, I work as a software developer irl and my bot has over 5500 lines of code after clean up.
So if you tell me I don't know what I'm doing, take a look in the mirror since you are asking for help.
yeah you don't know what your doing
i can take a look in the mirror
because i am not ugly
looking at your pic
make me sick
someone's ego was hurt lol
HAHAHA
LMAO
@simple bluff why are you being toxic?
@earnest phoenix if you dont stop ill be muting you, throwing fuel on the fire isn't helping.
I didn't do anything
Deftones, next time approach me with a threat of mute wen you finished your sentence
to anyone else who wants to talk back to me or talk shit in this channel
it's for development
not for having petty arguments
It's even more funny because he's right
The everyone role has the same id as the guild
Learnt from tonku my master
uwu
What would be an efficient way of getting an array with all member ids
Wait it is?
Yeh
Damn didn’t know that
What would be an efficient way of getting an array with all member ids.
I mean I can just use a for loop to go through all members and push their id into an array but I'm questioning if there's a better way perhaps.
Eris wink
But if guild.id works as the @everyone Id why didn’t his code work? The code looks correct to me
(Yes I was aware that I can’t ping, otherwise I wouldn’t do it)
everyone is the guild id
try doing msg.content on a message that has everyone mention
Isn't it plain @everyone?
Nope
the mentions are plain, you are thinking of the role which has the same id as the guild
Free vs good
heruko i dont like, glitch not 24/7
Amazon AWS has a 12 month trial
mate just buy a fucking vps instead of asking almost every day for an alternative that doesnt exist
glitch can be 24/7 if you set up some kind of pinging process every 5min if I understood correctly
i setup it
but he off every 12 hours if it working nonstip
know somebody enything else
without heruko, glitch, google, amazon
no
those are the only free hosts
or you go for something very sketchy
just buy a fucking vps
or settle with what you have
what error
well discord does have a message limit of 2000 characters
no, post it here so if i cant, someone else can help you
(node:17810) 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: 7)
(node:17810) UnhandledPromiseRejectionWarning: Error: SetLevel function parameter toSet needs to be a number!
at Object._SetLevel (/rbd/pnpm-volume/7e364553-725c-442a-a4fa-8e5336d9620c/node_modules/.registry.npmjs.org/discord-leveling/1.0.3/node_modules/discord-leveling/index.js:90:47)
at Queuing._executeQueue (/rbd/pnpm-volume/7e364553-725c-442a-a4fa-8e5336d9620c/node_modules/.registry.npmjs.org/discord-leveling/1.0.3/node_modules/discord-leveling/queue.js:41:41)
at Timeout.setTimeout [as _onTimeout] (/rbd/pnpm-volume/7e364553-725c-442a-a4fa-8e5336d9620c/node_modules/.registry.npmjs.org/discord-leveling/1.0.3/node_modules/discord-leveling/queue.js:86:22)
at ontimeout (timers.js:436:11)
at tryOnTimeout (timers.js:300:5)
at listOnTimeout (timers.js:263:5)
at Timer.processTimers (timers.js:223:10)
(node:17810) 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: 8)
here
ohhh god
in a code block pls
also if you read the error you would know what the issue is
Idk js XD
setLevel need umber
ik python
then dont use js
number
if you dont know it
I did put 20 as a number
could you send the code?
can show code?
Ok
if (command === 'setlevel') {
var amount = args[0]
var user = msg.mentions.users.first() || msg.author
var output = await dl.SetLevel(user.id, amount)
msg.channel.send(`Hey ${user.tag}! You now have ${amount} levels!`);
}
here
var amount = args[0]
var user = msg.mentions.users.first() || msg.author
var output = await dl.SetLevel(user.id, amount)
msg.channel.send(`Hey ${user.tag}! You now have ${amount} levels!`);
}```
ummmm
amount won’t be an integer, it will be a string
how?
you would have to convert it
by using parseInt
oh
That code is not important anyway
ok
bruh how to make that someone gets xp every minute in js?
code it
using an easy function to solve a problem
deleting the entire command
yes
There are numerous tutorials for an xp system...
Can someone see what is wrong with this? Bot acts like it loads the file with no errors but yet it doesn't detect anything at all. It doesn't even trigger the console log.
https://pastebin.com/7n0X4DKT
Also I am trying to do this with Eris
lemme seee..
i commented out most of the mongo stuff but heres what i got in the base command
#user = self.db.posts.find_one({"user": ctx.author.id})
if not str(ctx.author.id) in todo:
todo[str(ctx.author.id)] = {
#post = {
"TODO" : [],
"rTODO" : []
}
#self.db.posts.insert_one(post)
D2.save_json("todo.json", todo)
else:
pass
await asyncio.sleep(1)
#data = owo.posts.find_one({"user": user.id})
#new = data['Todo'].append("watch hentai") <-- yes hentai
#owo.posts.update_one({"user": user}, {"$set":{"Todo": new}})
idk
theres no fixing it? 

im just gonna practice rethink
you should rethink that decision mmlol
@trim saddle What is self.db
the mongoclient
You need a database and then a collection
Or use it as an attribute aka
s = MongoClient()
db = s.voters
collection = db.vote
im saving this snippet for later
anyone help me?
Don't ask to ask
How to make webhook for website?
not code?
A webhook has code

What’s the rate limit on status changes
hey, someone can send me a server count poster? i tried everything. i tried #312614469819826177 too. But it does not work. 😦
for python please
https://discordbots.org/api/bots/BOT_ID_HERE/stats will be the API endpoint you need. (Change BOT_ID_HERE to your bot's ID)
Look up aiohttp examples on how to send a POST request in aiohttp
You wanna post or get server count?
I hope you did read the part where I said that you will need to use aiohttp
aka use your code, not your browser
In browser, you send a GET request instead when visiting that link
i think people told me this many times but one last time xD,
how to get the servercount on my bot page?
like that
Post it on the website, you mean?
ye
Scroll up until you see my message with discordbots.org link
Anyone familiar with the SQLite settings provider in commando
Wrong place, bad meme
oof\
File "D:\Bot - Copy\bot.py", line 2769, in on_message
'\n"damage": "' + str(itemdmg) + '"'
TypeError: must be str, not int
not in need of help
but this is dumb
it is a string xd
Error is probably somewhere else
where it is thinking its at tho
Python can sometimes be dumb on errors
first it said it couldnt be str() so i changed it to int() as it was needed
and now its doing that
its funny, in a way
but ive got it handled enough, im just trying to make the file look a little better :I
meh
my idea of course didnt work
cri
How does one get the amount of servers ther bot is on to display on the discord bot page
Send the server count to DBL API
Either use an already existing library or send an HTTP request yourself
hey guys
need help
why dont work?
let kUser = msg.guild.member(msg.mentions.users.first() || msg.guild.members.get(args[0]));
if (!kUser) return msg.channel.send("Не могу найти человека!");
if (!msg.member.hasPermission("KICK_MEMBERS")) return msg.channel.send("К сожалению у тебя не хватает прав друг!");
if (kUser.hasPermission("MANAGE_MESSAGES")) return msg.channel.send("Этот человек не может быть кикнут!");
let embed = new Discord.RichEmbed()
.setTitle('')
.setDescription('Это кик:anim_ban: \nЯ заметила, что кого-то кикнули!:anim_cat:')
.addField("Кикнут человек:", `${kUser} с ID ${kUser.id}`)
.addField("Кикнут человеком:", `<@${msg.author.id}> с ID ${msg.author.id}`)
.addField("Кикнут в канале:", msg.channel)
.addField("Время:", msg.createdAt)
.setThumbnail('https://cdn.discordapp.com/attachments/463276215663591435/558748363143512086/IMG_20190322_222615.png')
.setColor('0x2c69d3')
msg.guild.member(kUser).kick("Кикнут звёздочкой")
msg.channel.send({embed})
}```
Please properly format your code blocks
And you need to be more specific. What isn't working? What error does it through, what are you trying to do? @silent cloud
Does the bot has the required perms?
I might move to russia idk
xD
does it give an error?
okay dokie

hastebin
xd
@unique nimbus take a look at it. I don't understand js lol
xD
ummm
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()
i dont understand
Эта ошибка возникла либо в результате выброса внутри асинхронной функции без блока catch, либо в результате отклонения обещания, которое не было обработано с помощью .catch ()
xD
lol
Google Translate good
idk sorry
xD
server most likely
We will be performing an infrastructure upgrade. We anticipate a short, 2-minute downtime during this upgrade
there's a buddy looking for help and hes just joining the chat givin' infos for his server.
if it's an anouncement for your bot nobody cares lol
No need to be a jerk @earnest phoenix
not a jerk, just being honest and indifferent about it 🤷
do you care that their bot is going down? exactly
stuff like that should be contained to your bot's support guild
what if everyone started posting when their bot is going down in here
Ok, we get it
heyyy i need some coders for a nice Discord Global Chat project.
i need writersfor python who know how the json databanks works and other
O.O
pm me if anyone has interest ^^
json database
that would be for beginers tbh. using json as a db is bad
"hey lets ignore everything that literally has database in it's name and use json WOOOOOOO!"
What exactly is a "Discord Global Chat project"
maybe chat in chat

its a programm with you can chat with guys from other servers in a channel.
like a global chat in a game with allow you to chat with other kingdoms etc
that's more than likely against the tos
you're not allowed to login with a user token outside of the discord client
that is not what i do...
he just wants to do the same thing yggdrasil and many other bots do
ok lets explain it a little bit.
its is simple to write but i want to expanse it lol.
you write he prefix of the bot and a message,
the bot send than in example follow message in the "global" chat
[your server where you write the cmd] Niko#1375: hello
the bot send the messeage in all servers who use this bot in a specific channel
ah
a telephone
yes
can help me
let kUser = msg.guild.member(msg.mentions.users.first() || msg.guild.members.get(args[0]));
if (!kUser) return msg.channel.send("Не могу найти человека!");
if (!msg.member.hasPermission("KICK_MEMBERS")) return msg.channel.send("К сожалению у тебя не хватает прав друг!");
if (kUser.hasPermission("MANAGE_MESSAGES")) return msg.channel.send("Этот человек не может быть кикнут!");
let embed = new Discord.RichEmbed()
.setTitle('')
.setDescription('Это кик:anim_ban: \nЯ заметила, что кого-то кикнули!:anim_cat:')
.addField("Кикнут человек:", `${kUser} с ID ${kUser.id}`)
.addField("Кикнут человеком:", `<@${msg.author.id}> с ID ${msg.author.id}`)
.addField("Кикнут в канале:", msg.channel)
.addField("Время:", msg.createdAt)
.setThumbnail('https://cdn.discordapp.com/attachments/463276215663591435/558748363143512086/IMG_20190322_222615.png')
.setColor('0x2c69d3')
msg.guild.member(kUser).kick("Кикнут звёздочкой")
msg.channel.send({embed})
}```
thats a code
he send about he kick him, but he in a server
and error is...
that error is usually related to file paths, but nothing there is accessing any file. you can try changing some stuff and see if it works:
.addField("Кикнут в канале:", msg.channel) -> .addField("Кикнут в канале:", msg.channel.id)
msg.guild.member(kUser).kick("Кикнут звёздочкой") -> msg.guild.members.get(kUser.id).kick("Кикнут звёздочкой")
msg.channel.send({embed}) -> msg.channel.send(embed)```
anyway i need sleep, good luck
Glitch: Scheduled maintenance is currently in progress. We will provide updates
ty I'll try
how can you do that only the developers of the bot can use a command?
have an array of whitelisted ids then check if the command's author id is in the array
Hm
Okay
is this an appropriate place to ask about requirements for bot approval?
my discord bot is throwing a 401 on the load up when i regened a fresh token
discordia btw
2019-03-23 01:39:25 | [INFO] | Connecting to Discord...
2019-03-23 01:39:25 | [ERROR] | 401 - UNAUTHORIZED : GET https://discordapp.com/api/v7/users/@me
2019-03-23 01:39:25 | [ERROR] | Could not authenticate, check token: HTTP Error 0 : 401: Unauthorized
thats the log
Ive changed the token and created new apps
still same 401
Integrate your service with Discord — whether it's a bot or a game or your whatever you wildest imagination can come up with.
401 (UNAUTHORIZED) The Authorization header was missing or invalid
so either
- no token is being sent
- the token is invalid (not an actual discord token)
my question about requirements for bot approval isn't specifically covered by the rules page
my bot was denied for having a command (google image search) that could produce nsfw content in sfw channels. my question is whether or not it would be acceptable to have the google search function be blocked in sfw channels by default, with the option for an administrator to enable googling in any channel.
through a config command
is there somewhere specific I should be asking this question? I apologize if it doesn't quite belong here.
File "/data/user/0/ru.iiec.pydroid3/files/accomp_files/iiec_run/iiec_run.py", line 31, in <module> start(fakepyfile,mainpyfile) File "/data/user/0/ru.iiec.pydroid3/files/accomp_files/iiec_run/iiec_run.py", line 30, in start exec(open(mainpyfile).read(), __main__.__dict__) File "<string>", line 40 async def ban(ctx, members: commands.Greedy[discord.Member],reason: str) ^ SyntaxError: invalid syntax [Program finished]```
Need help plz 🙏
wow that formatting is fucked
async def ban(ctx, members: commands.Greedy[discord.Member],reason: str)```
isn't valid
how i install it ??
What to install
dm
Sqlite
can any1 help
File "/data/user/0/ru.iiec.pydroid3/files/arm-linux-androideabi/lib/python3.6/site-packages/discord/ext/commands/core.py", line 304, in _parse_arguments
transformed = yield from self.transform(ctx, param)
File "/data/user/0/ru.iiec.pydroid3/files/arm-linux-androideabi/lib/python3.6/site-packages/discord/ext/commands/core.py", line 225, in transform
raise BadArgument('Converting to "{0.__name__}" failed.'.format(converter)) from e
AttributeError: 'str' object has no attribute '__name__'```
I'm new at this pls can anyone help me please..?
I am .js so I can't help
It literally tells you what is wrong kek
core.py", line 225, in transform
raise BadArgument('Converting to "{0.__name__}" failed.'.format(converter)) from e
AttributeError: 'str' object has no attribute '__name__'```
I only have 40 Lines -.-
What is discord/ext/commands/core.py then a client/command handler?
Then something in the command handler or your commands are breaking it
Ok
does anyone know how to do announcements from the console in node.js?
well how to code it
@lime geode What command does that happen on?
@prime cliff Actually no, it doesn't tell what is wrong
The original error either wasn't posted or didn't appear because another one happened in the d.py code itself
I found it and fix it ;)
Hm?
Now I have an other Problem :^D
Which is?
api says that GET/bots/{bot.id?}/check checks for past 24h. what if someone votes like twice. cuz like the cooldownis just 12h right
or is it just assumed that they wouldnt have voted twice
😂
it checks if a user has voted in the last 24 hours. 12 hours < 24 hours
Error please
File "/data/user/0/ru.iiec.pydroid3/files/arm-linux-androideabi/lib/python3.6/site-packages/discord/ext/commands/core.py", line 374, in invoke
yield from injected(*ctx.args, **ctx.kwargs)
File "/data/user/0/ru.iiec.pydroid3/files/arm-linux-androideabi/lib/python3.6/site-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```
Yes
read this guide
...
does anyone know a script for node.js that adds a feature so i can announce updates in servers that use my bot?
can rly somebody help
i cant fix it
let kUser = msg.guild.member(msg.mentions.users.first() || msg.guild.members.get(args[0]));
if (!kUser) return msg.channel.send("Не могу найти человека!");
if (!msg.member.hasPermission("KICK_MEMBERS")) return msg.channel.send("К сожалению у тебя не хватает прав друг!");
if (kUser.hasPermission("MANAGE_MESSAGES")) return msg.channel.send("Этот человек не может быть кикнут!");
let embed = new Discord.RichEmbed()
.setTitle('')
.setDescription('Это кик:anim_ban: \nЯ заметила, что кого-то кикнули!:anim_cat:')
.addField("Кикнут человек:", `${kUser} с ID ${kUser.id}`)
.addField("Кикнут человеком:", `<@${msg.author.id}> с ID ${msg.author.id}`)
.addField("Кикнут в канале:", msg.channel)
.addField("Время:", msg.createdAt)
.setThumbnail('https://cdn.discordapp.com/attachments/463276215663591435/558748363143512086/IMG_20190322_222615.png')
.setColor('0x2c69d3')
const user = msg.mentions.users.first();
const member = msg.guild.member(user);
member.kick("Кикнут звёздочкой")
msg.channel.send({embed})
}```
@lime geode Are you trying to kick someone who is not in the server?
I wasn't even talking to you lul
No
Can I ask about discord servers here
Iterating is basic js
client.guilds.map(g => g.name)
learn js before making a bot in js is a pretty basic rule
ty
but
can u too help with this?
let kUser = msg.guild.member(msg.mentions.users.first() || msg.guild.members.get(args[0]));
if (!kUser) return msg.channel.send("Не могу найти человека!");
if (!msg.member.hasPermission("KICK_MEMBERS")) return msg.channel.send("К сожалению у тебя не хватает прав друг!");
if (kUser.hasPermission("MANAGE_MESSAGES")) return msg.channel.send("Этот человек не может быть кикнут!");
let embed = new Discord.RichEmbed()
.setTitle('')
.setDescription('Это кик:anim_ban: \nЯ заметила, что кого-то кикнули!:anim_cat:')
.addField("Кикнут человек:", `${kUser} с ID ${kUser.id}`)
.addField("Кикнут человеком:", `<@${msg.author.id}> с ID ${msg.author.id}`)
.addField("Кикнут в канале:", msg.channel)
.addField("Время:", msg.createdAt)
.setThumbnail('https://cdn.discordapp.com/attachments/463276215663591435/558748363143512086/IMG_20190322_222615.png')
.setColor('0x2c69d3')
const user = msg.mentions.users.first();
const member = msg.guild.member(user);
member.kick("Кикнут звёздочкой")
msg.channel.send({embed})
}
I think
member.kick("Кикнут звездочкой");
Should be in english
have you tried replacing cyrillic text to latin one by one
error still occurs?
Can I host my bot on mobile
No wtf
you can on android
Google it
Ok
Am I too late? Lol
A guide for coding on mobile
@loud salmon lmfao true
@languid dragon shut and blame gh pages
gh pages is https
is this the server for "Server-Stats" ??
Negative answer
This server is NOT the support server for ANY bot. You need to click on the Support Server button. not the Join Discord button.
Anyone good with regex here?
yes
but this is why im good with regex
How would I get the end part of an URL? 
👌
my bot uses a regex that finds all valid urls in a message
I don't need the entire URL
mk
Yep, got it 
@west spoke android
ah
what lang are you coding it in tho
if its python
get Pydroid
and most likely there are others for different languages
can we dont code on mobile tho tbh?
What if one can't afford a laptop/Pc
Nothing coded on mobile will turn out as you want it to.
Though in most cases you are correct, sometimes even a phone is enough
It's actually pain in the ass to code on phone
My phone costs the same as a cheap laptop ~$120 tho 
Prices, at least in my country, are not that low for laptops
Even some shitty ones cost enough
const ipc = require('node-ipc');
ipc.config.id = "jpbbot";
ipc.config.retry = 1000;
ipc.config.silent = false;
ipc.serve(() => {
//MESSAGES;
ipc.server.on("dblVote_CB", (message) => {
console.log("Received Message: " + message);
})
})
ipc.server.start();```
I'm just starting with ipc and this is my code,
It keeps giving me this error and exits:
```2| jpbBOT | starting server on /tmp/app.jpbbot
2| jpbBOT | starting TLS server false
2| jpbBOT | starting server as Unix || Windows Socket
2| jpbBOT | TypeError: this.indexOf is not a function
2| jpbBOT | at Server.Array.contains (c:\Workspace\bots\jpbbot\index.js:5:21)
2| jpbBOT | at Server.emit (c:\Workspace\node_modules\event-pubsub\es5.js:74:21)
2| jpbBOT | at Server.onStart (c:\Workspace\node_modules\node-ipc\dao\socketServer.js:45:14)
2| jpbBOT | at Object.onceWrapper (events.js:285:13)
2| jpbBOT | at Server.emit (events.js:197:13)
2| jpbBOT | at Server.EventEmitter.emit (domain.js:439:20)
2| jpbBOT | at emitListeningNT (net.js:1290:10)
2| jpbBOT | at processTicksAndRejections (internal/process/next_tick.js:76:17)```
suck me
gladly 

😩

When sending code in discord you use ```thing. Now the question is, which thing should I use when sending js code? Just look at this
condition ? object.prop.subprop : object.props.prop7
absolutely colorless. I am using js. What does a better job of highlighting js than js?
The code is javascript. I used ```js, which is supposed to be for javascript, yet there are no colors
if(true){
console.log("No")
}```
That should have colors
I cant tell because mobile
Was mine even highlighted?
yes
Then discord might not give ternary syntax highlighting
mobile doesnt do highlighting
that's completely beyond my point
why? because the mobile devs are retarded
rartaded*
yes
i swear to god the entire team should be fired and they should hire new interns
imagine firing the ceo
they're ignoring community suggestions and opinions and only made the app worse and more unstable than a few months back
reason? "consistency"
They added that stupid gift button literally in the chat box
they're literally just asking you for money
message box in a few months
I wouldnt be surprised
And you can't turn it off! And their point is "if we added a toggle for everything there would be too many toggles". Honestly, everyone would prefer a toggle instead of 3 buttons I never use
ok this is the wrong channel
want better codeblocks? hit up hastebin
code blocks are ehhh in discord
adding standard syntax highlighting wouldnt be very difficult
and adding it to mobile would be the same
Ok I am shit at regex and I need help. This is my regex /foo|bar/gi. It only matches foo but not bar
I'm assuming I just need to add a letter but idk which one
It does match bar if foo is present
i think is /[foo|bar]/
i dont remember, you can just check a regex linter online or something
Ken sent this before today
If you don't help me don't write plz
that made 0 sense
you are flooding chat, especially for mobile users, posting your code to hastebin reduces it to one line, a link
put it in a hastebin next time
Hi i have a problem
:
My code :

Wait
My code :
This code has a problem, it works however when the PC is full but nino if in the PC ex: in pc 1 there are only a few pokémons and not 25 it shows no pokémon so : Aucun Pokémon Type
can somebody help me get my bot's PLAYING status to work?
this is what i have thus far: ```client.setInterval(() => {
let Status = [
Status 1,
Status 2,
Status 3,
];
client.user.setActivity(Status[Math.floor(Math.random() * Status.length)], { "type": "PLAYING" });
client.user.setStatus('online');
}, 30 * 1000);
have you ensured the interval is running?
i don't remember how to do so.
console.log is your friend
just a console.log inside of it to ensure it actually starts to run
does anyone here know through JS, how to post infomation on a webpage regarding a bot stats?
some sort of <script> code idk
lmao thx XD
i know a bit of html but i dont know java
i know it will be in the form of a script, but just don't know how to set it up
java and javascript are not the same thing
read into how to write an own api and expose data about your bot that you want to display on your website
How do you guys get rank of someone in an exp leaderboards for example ?
Do you store the rank in a column ?
Or do you use a trick to get a position with sql ?
I don't want to destroy performances
depends on your db and how youre storing the data
id use a json

and have it replace with whatever value is updated
like if someone were to have lets say $1000, then it would update w/ the name, and the current balance
idk
Why json
json is not a good way to store data
its prone to corruption if you write often
json is useful as a read-only set of static data
for any dynamic storage, you should move up to a database
^
there are simple key/value dbs that work just like json files
Except better 
ye ofc
hi
How would i grab the invite code?
Im trying to make a command that will show invite link info etc
Get guild invites and output them, you mean?
If( messege.contain === 'invite') {
message.reply === ( link here );
}
@earnest phoenix
massege 
My perfect english any problem @slender thistle
@earnest phoenix Could you give some more details?
Do you want to output all guild invites or info only for the one that will be in a message?
module.exports = async (client, message, guild, args, user) => {
message.delete()
function verification_level() {
let verification;
if (message.guild.verificationLevel == 0) {
verification = `No Verification`
}
if (message.guild.verificationLevel == 1) {
verification = `Email Verification`
}
if (message.guild.verificationLevel == 2) {
verification = `5 Minute Waiting`
}
if (message.guild.verificationLevel == 3) {
verification = `10 Minute Waiting`
}
if (message.guild.verificationLevel == 4) {
verification = `Phone Verification`
}
return verification;
}
let inviteslogEmbed = new Discord.RichEmbed()
.setTitle(`Invite Link was created by ${message.author.tag}`)
.setThumbnail(message.guild.iconURL)
.addField(`Server Name:`, message.guild.name)
.addField(`Invite Code:`, `${invite.code}`)
.addField(`Inviter:`, message.author)
.addField(`Server ID:`, message.guild.id)
.addField(`Server Channel:`, `${message.channel}`)
.addField(`Server Invite:`, value =`[Click Here]()`)
.addField('Verification Level:', verification_level(), true)
.setColor(message.guild.member(client.user).displayHexColor)
message.channel.send(inviteslogEmbed).catch(console.error);
}```
here my code
Okk
And where do you want to get an invite from?
like its show you info about the invite code
What invite code
any invite code that you create
I guess pick a random one out of all guild invites
That will be more of basic js + read the docs thing
Theres a <Guild>.fetchInvite() or something.
guys
now somebody can help?
const args = msg.content.slice('*kick'.length).split(' ');
let kUser = msg.guild.member(msg.mentions.users.first() || msg.guild.members.get(args[0]));
if (!kUser) return msg.channel.send("Не могу найти человека!");
if (!msg.member.hasPermission("KICK_MEMBERS")) return msg.channel.send("К сожалению у тебя не хватает прав друг!");
if (kUser.hasPermission("MANAGE_MESSAGES")) return msg.channel.send("Этот человек не может быть кикнут!");
let embed = new Discord.RichEmbed()
.setTitle('')
.setDescription('Это кик:anim_ban: \nЯ заметила, что кого-то кикнули!:anim_cat:')
.addField("Кикнут человек:", `${kUser} с ID ${kUser.id}`)
.addField("Кикнут человеком:", `<@${msg.author.id}> с ID ${msg.author.id}`)
.addField("Кикнут в канале:", msg.channel)
.addField("Время:", msg.createdAt)
.setThumbnail('https://cdn.discordapp.com/attachments/463276215663591435/558748363143512086/IMG_20190322_222615.png')
.setColor('0x2c69d3')
const user = msg.mentions.users.first();
const member = msg.guild.member(user);
member.kick("Кикнут звёздочкой")
msg.channel.send({embed})
}```
i rly cant fix
can anyone help me with discord bot? (python)
Dont ask to ask
Just ask your question
it wastes time if you say "i need help" or "can someone help me?" instead of just saying what the problem is. Save your time and other people's time by just asking the question.
meh
I keep getting these today
good point
do anyone of you meet this problem as well?
AIOHTTP error i guess?
or is that something on my side?
aiohttp?
my god do you even know how to do that @tardy shell
are you using file storage?
no?
that would happen if you were using a file storage as your main method of doing it
when i type something then bot spams this message
why tho
@client.event
async def on_message(message):
channel = client.get_channel('559353981944725504')
await client.send_message(channel, f" {message.author} said {message.content}")
is my code
@client.event
async def on_message(message):
if message.content.startswith(''):
channel = client.get_channel('559353981944725504')
await client.send_message(channel, {message.author} + 'said' + {message.content})
try that
I'm not gonna expose you the truth, but you should understand this yourself
on_message basically means do something when a message is sent, anywhere
^
regardless of a channel, who sent it, where it was sent
yuh
are you still not getting what is your issue?
no because im very starter of coding im using async
mmm
then don't go straight to bots, learn the language first
my first project was a basic console calculator built in C#
mm
i was working on a graphing calculator
now that i know pillow i can likely try to make a coordinate plane in it and actually do stuff
I want to stop people from automating commands.
I'd do this by having certain "suspicious users" verify being human.
Any ideas on how I could do this? 👀
Like a capcha?
Yeh
what lang
js
look into some sort of image generation
or create a random number and text message (likely less secure than a imagee tho) and have the user have to respond with that
ill try to work on one, idk
but it'll be in python unfortunately
yeh
But a selfbot that listens for messages could still solve it
@tardy shell Your on_message doesn't exclude bots
Let's see how far we can get with common sense
Maybe I'll just start with that
a developer named Kanno did something similar to what you are trying to do in JS
Should already stop a lot of people
lemme get what he made as it
👀
I already gave him a mood to learn python, no need to make him get used to being spoonfed
spoonfed*
whatever
oh
thats essentially what it was
a iteral capcha
but if its just numbers a bot may just have a script to add 1 to whatever number to get in
maybe
I tried searching for some kind of service I could use for it
But couldn't rly find anything helpful
hmm
i know if you were using Python you could use Pillow
lemme look for a image creation thing
Preferably I'd just have something that returns a link to an image + the secret word on it
😐
there's no benefit in making something CPU bound async
I guess using asyncio.run_in_executor is the only way at this point, eh?
anyone know why the dispatcher when i do .playSteam start than stops right after, the stream is valid and i get not error or debug info, i using discordjs
how much are you willing to pay?
pfffff
jk i'm not making you one, please learn to code one
just get galacticbot or sth


