#development
1 messages · Page 593 of 1
Lol wut
he is a whitename means his bot is not here
thats why Im assuming that did he even do a program at the first place?
1234567891011121314151617181920
Lol
He's talking about dsl bot being down
if its dsl bot then
Which probably does have shards
could be the dsl bot itself
anyone want to join my free youtube/spotify premium server?
Lol
no
Epic ad
..
Is this #development anymore
Lmao
Still looking for most efficient way to get an array with all user ids from all members in one server with Eris
I do use master
but be careful on master
its not something that is easy to maintain in a long run
Is there some epic trick I can do or do I have to just loop through all members
Hmm why
so they don't test their changes before pushing to git?
Loop is your good bet
yes but look on internal sharding
they tested that before pushing
but did it work well on everyone?
I see a lot of people having issues with it
oh ok, unexpected bugs
but they tested it
So I was using thisjs message.guild.roles.create({ data: { name: 'Muted', color: '11112' }, reason: 'For muted people' })
if I put permissions: { SEND_MESSAGES: false } inside that json ^
it gives error
I love to use RANDOM color
@late hill https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/keys
members.keys()
Oh
members.forEach(m => anArray.push(m.id))?
@late hill just use .keys()
In like a 10k user server
Collection in eris = Map
to put it in other words, it extends Map
means it has the functions of a map
let ids = members.map(m => m.id)?
.keys() returns an array of keys, which is the user_id of the user
const ids = members.map(m => m.id)
// is same of
const ids = members.keys()
@late hill
map = slower
because you still need to access the property which is .id
Can I use .keys() on discord.js library MemberStore?
Collection extends Map
ofc
what do you think MemberStore Extends
Data store, then collection, then map if I remember correctly
🙏
I am using either .map() or .forEach() till now
thats why you read every source you can see
Extends means its inheriting the function, properties of the original source
Can someone help me with this -> https://discordapp.com/channels/264445053596991498/272764566411149314/560400783917449217
See if there's any object that has that permission as its attribute
Probably undefined
so that we can know where it exactly happens
wait
UnhandledPromiseRejectionWarning: RangeError [BITFIELD_INVALID]: Invalid bitfield flag or number.```
I think it doesnt work like that
Here is my code again
message.guild.roles.create({
data: {
name: 'Muted',
color: '11112'
},
reason: 'For muted people',
permissions: {
SEND_MESSAGES: false
}
})```
// Create a new role with data and a reason
guild.roles.create({
data: {
name: 'Super Cool People',
color: 'BLUE',
permissions: 'an array of permission resolvable or a permission resolvable' // this is the permissions you will give it
},
reason: 'we needed a role for Super Cool People',
})
.then(console.log)
.catch(console.error);
https://discord.js.org/#/docs/main/master/typedef/ColorResolvable colors accept this values
so he is fine on that
@sinful lotus like permissions: ["SPEAK"]?
yes but thats the allowed permissions
then dont put anything
I don't want to deny all permissions
also to deny someone on sending message, you do it in "channel overrides"
ik I m doing that too
as well, it wont technically deny all permissions
it would combine the permissions of the other roles as well
but if I want to deny role permissions for something else, what do I do?
if you have everyone role and u have embed links there, even it isnt in the role u create its fine
on the stable branch I used to use
guild.roles.create({
name: 'Muted',
color: '11112',
SEND_MESSAGES: false
})``` and it used to work
you can use bitfield
I don't know anything about bitfields
this is bitfield
Ohhh
hi there. do i have to setup a server (expressjs) in order to use the dbl webhooks for information on who upvoted, or is there another way?
https://github.com/telkenes/dbl-discord-webhook or use dblapi.js
hmm nice, you know of anything like that, but not dbl specific, for receiving any webhook?
use express
basicly make a post server
or anything else, you just need a webserver that can accept post requests
well i know how to do that but my question is if theres a better way because i would like the code to be standalone so to say and work without much configuration around it.
express is very simple
^
its not about the program, i mean the operating system configuration.
all express requires is node tho
if i run it on my pc id have to do anything necessary for a server, security dns updates etc.
i dont have money
Well i have a miner here running for 1,5 years now through. and my other bot needs windows powershell to work so it would be really much less costly to have it here
then buy money ez
my pc here at home is perfect for running the bot, except that id liek to avoid making it a server
you just have to get 2 euros a month lol
make someone a bot each month and charge 2€ ez
So you guys building the server into the same app as the bot or are you running two separate processes for that? (my webhook does only change a database entry)
if you can pass data from one process to the other, do that
do which one of the two?^^
if you can pass data from one process to the other, go for 2 processes
but it might be simpler to build both into one
ok thanks
Use pendrive for that
who most i add command to my bot
what
That's a sentence...
Guys, how most add command bot to
``` if (message.content.toUpperCase() === prefix + DAILY) {
message.delete();
if (money[message.author.username + message.guild.name] != moment().format('L')) {
money[message.author.username + message.guild.name] = moment().format('L')
money.updateBal(message.author.id, 500).then((i) => { // The daily ends of the day, so everyday they can get a daily bonus, if they missed it, they can't get it back again.
message.channel.send({embed: {
color: 3447003,
description: 'Recieved your $500 `!daily\. I think you should check \!money`.',
author: {
name: ${message.author.username}#${message.author.discriminator},
icon_url: message.author.avatarURL
}
}});
})
} else {
message.channel.send({embed: {
color: 3447003,
description: 'You already recieved your `!daily\. Check later **' + moment().endOf('day').fromNow() + '**.', // When you got your daily already, this message will show up. author: { name: ${message.author.username}#${message.author.discriminator}`,
icon_url: message.author.avatarURL
}
}});
}
}
});
I defined moment
With
Let moment = require('moment');
Do you need moment instead of moment()?
It should be like?
I looked at the documentation, so nvm on that
is it a good practice to open the file on startup and never close it while the program is running?
no
I am using JavaScript.
@mossy vine Like this?
fs.readdir('./commands/', (err, files) => {
if(err) console.log(err);
let jsfile = files.filter(f => f.split('.').pop() === 'js');
if(jsfile.length <= 0) return;
jsfile.forEach((f, i) => {
let props = new require(`./commands/${f}`).bot;
bot.commands.set(props.name, props);
if (props.aliases !== null) props.aliases.forEach(alias => bot.aliases.set(alias, props.name));
});
});
what do the command files look like?
module.exports = {
name: '8ball',
description: 'Seek advice from the famous Magic 8-Ball.',
aliases: ['8-ball','8b'],
usage: '{prefix}8ball <question>',
cooldown: { time: 3, users: [] },
category: 'Fun',
execute(message, args, bot, prefix) {
if (args == '') return message.channel.send(':info: Command usage:`' + prefix + this.usage.slice(8) + '`');
if (!args.join(' ').endsWith('?')) return message.channel.send(':no: That is not a question!');
else return message.channel.send(responses[Math.floor(Math.random()*responses.length)]);
}
};
You have to export a class buddy
Ohh, that's probably what I did wrong. I combined two of my bots' command handlers. One is this, the other is classes.
or don't use new
So why has my tip bot have not been listed yet?
and plus there's donate bot
are suggesting a donation?
you would be mentioned and dmmed if you were declined or accepted
ok thank you
how can i show in how many servers my bot is in . Currently it says this
thanks!
what language
that is not a language, but I got it
stable or master
the version
if you didn't specifically get it off master you're probably running stable
inside a message event
<Message>.isMentioned(<Client>)```
it returns boolean, so you can put it inside an if statement and get it from that.
var 
that won't work anyway
since 'a!' has a boolean value of true, the stuff past the || will be obsolete
if (<Content of the message>.startsWith('a!') || <Content of the message>.startsWith(<Client>.toString()))

does anyone know more or less how it works to get tickets like this?
https://cdn.discordapp.com/attachments/265156286406983680/560551955269812232/unknown.png
Wtf channel.overwritePermissions() removes old overwrites too???
@still rune compare the joined_at dates for every user
what could the solution be for setting the bots presence if one shard restarts;
At the moment when there's a full restart the highest shard broadcasts a set presence because my server count is in my status message, meaning that all the shards have to be online to set the presence or else it'll either error or it'll have an inaccurate count in the name.
This works fine, but when one shards restarts it's presence is not set for another 30 minutes (the amount of time the highest shard intervals through to set the new presence).
This is why i asked the question a while before about if there was any way to retrieve the total guild count from a simple endpoint, which is just, no, its not possible :p.
So how would I go about solving this problem?
what language are you using
js
Hi
RedstoneMiner27Today at 9:03 PM
Wtf channel.overwritePermissions() removes old overwrites too???```
**overwrite**Permissions

hi, i know this is simple but i cant seem to assign nickname to member
member.user.setNickname doesnt work
you dont give nicknames to users
e.g. message.member.setNickname works, but doesnt with mentions
you give them to members, as members represent the object that the user has directly with the server
@earnest phoenix wdym doesnt with mentions?
i'll explain details
i can assign nickname to message author
but, if i did: bruh = message.mentions.members.first();
bruh.member.setNickname("asd") wouldnt work
bruh, is a member
so no .member
ahhhh
tnx
oh one more thing
how do i check if bot has permission to e.g. manage messages
i can get it for user, but not for client
guild.me.hasPermission?
yup
my life is so bad rn
at Client.<anonymous> (C:\Users\chill\Desktop\chill\discord-bot\bot.js:117:31)
at Client.emit (events.js:189:13)
at MessageCreateHandler.handle (C:\Users\chill\Desktop\chill\discord-bot\node_modules\discord.js\src\client\websocket\packets\handlers\MessageCreate.js:9:34)
at WebSocketPacketManager.handle (C:\Users\chill\Desktop\chill\discord-bot\node_modules\discord.js\src\client\websocket\packets\WebSocketPacketManager.js:103:65)
at WebSocketConnection.onPacket (C:\Users\chill\Desktop\chill\discord-bot\node_modules\discord.js\src\client\websocket\WebSocketConnection.js:333:35)
at WebSocketConnection.onMessage (C:\Users\chill\Desktop\chill\discord-bot\node_modules\discord.js\src\client\websocket\WebSocketConnection.js:296:17)
at WebSocket.onMessage (C:\Users\chill\Desktop\chill\discord-bot\node_modules\ws\lib\event-target.js:120:16)
at WebSocket.emit (events.js:189:13)
at Receiver._receiver.onmessage (C:\Users\chill\Desktop\chill\discord-bot\node_modules\ws\lib\websocket.js:137:47)
at Receiver.dataMessage (C:\Users\chill\Desktop\chill\discord-bot\node_modules\ws\lib\receiver.js:409:14)
(node:5460) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
(node:5460) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.```
const helpembed = new RichEmbed()
.addField(['All Commands']("tinyurl.com/commandschill"))
.addField(['Chill Support Server']("discord.gg/ZbEUUU7"))
.addField(['Invite Chill to your server!']("tinyurl.com/chillinvite"))
.addField(['Donate']("tinyurl.com/donatechillbot"))
.addField(['Donate using Patreon']("www.patreon.com/chillbotdiscord"))
.setColor("RANDOM")
message.channel.send(helpembed)
}```
wot is wrong'
What the hell are you even doing---
Why are you just doing ['stuff'] out of thin air
not to mention why are u using it as a function
to add a field its;
.addField(title, value)
^ .addField("[Hello](www.world.com)")
markdown isn't code compliant
rather use ${[]}
with ` around
why
there's literally no use for that
i though all command is a tuple xd
lol i am so dumb
embed fields need a title and a value
??
are you ok
false
maybe
using internal sharding fo rdbls post stats, would i just manually put 0 as the shard since you cant really get current shard
I think the lib handles all that if you give it a client
im using discord.py and im getting a 400 bad request from this code:
await client.say("{}, The top players are: \n \n {} ```{} points``` {} ```{} points``` {} ```{} points``` {} ```{} points``` {} ```{} points```".format(user.mention, '<@' + firstp + '>', users[firstp]['points'], '<@' + secondp + '>', users[secondp]['points'], '<@' + thirdp + '>', users[thirdp]['points'], '<@' + fourthp + '>', users[fourthp]['points'], '<@' + fivep + '>', users[fivep]['points']))
any ideas?
Is the message longer than 2000 characters?
Also you should consider using f-strings
It allows you to use the variables within the string without using .format
huh
oh
Actually they apparently were added in 3.6 I guess
for example
await ctx.send(f'{ctx.author.name} you are gay')
wait I did it wrong
yes
Yeah, it makes it a lot easier to maintain code I find
But now I use js for most things
Yay i'm intelligent
@earnest phoenix you can post server count without shards
yea but if i want to post shard count
o i see
:p
You can get shard count with internal sharding I believe he said
wdym internal sharding?
current sahrd
@hushed berry on dev build of d.js theres something called internal sharding
basically its automatic sharding handled all on one process
so no need to communicate between shards etc
just post it with shard count
i could write a post without ig but talking about their js lib
you could just manually count the number of guilds assigned to that shard
if they arent divided
however inefficient that may be
i dont think yall know what im askin :p
you're talking about guild coutn.........?
You can get shard id from guild tho
no
posting guild count
shardcount posting
with the shard count
no
with the new internal sharding
there is no way to know your current shard
since its all handled on one process
and dosnt have a property
i realize uber
the postStats in the lib
but you can get the shard of a guild by math
require current shard
so you can perform that function on all the guild ids
and then just post the shard array
if you really want
ok
so
this
is what im trying to figure out
i assume
i just manually enter 0
since
internal sharding dosnt provide
what shard the process is on
and thats my question
should i manually enter the 0 shard
or is there another way
to post stats with the library
that wouldnt require current shard
im just going to write my own post request
nvm
Very indecisive
what?
bruv no way to get current shardId on new internal sharding :p
since one process
thats what im prolly ending up doing
why do you even care about shard count at the point, btw?
it's his bot framework
at the point?
I post with my lib and it doesnt post shards 
its just an extra something
for the dbl page
and since its a bot framework i intend to use many times over why not add it now instead of later etc
if anyone want to help dev Tyden DM me you need to know some html css and must know js
This isnt the place
@earnest phoenix wanna see how easy adding commands are 😂
wdym
module.exports = commandManager.addCommand({
commandsAlias: ["ping", "clientPing", "pong"],
configuration: { guild: false, loud: false, nsfw: false},
description: `gets the bot's ping`,
commandArguments: ``,
example: ``,
runFunction: (args, params, msgObj, speaker, channel, guild, isStaff) => {
Util.sendEmbed(channel, 'Ping', `PONG! \n ${client.ping}`, Util.makeEmbedFooter(speaker), null, Colors.Orange, null);
},
});```
oh right on

args, params, msgObj, speaker, channel, guild, isStaff that is a large amount of redundant arguments
especially considering msgObj contains paths to speaker, channel, guild and can calculate isstaff
tbh the isstaff part should just be the part of the msg event
or at least speaker.isstaff
What you want
Lol
const Discord = require('discord.js'); const client = new Discord.Client(); client.on('ready', () => { console.log(`Logged in as ${client.user.tag}!`); }); client.on('message', msg => { if (msg.content === 'ping') { msg.reply('pong'); } }); client.login('token');
Take it
Lmao
Lol
What you want
Which command
Nope
I can't give anything else
For some reason I cant remove a border between 2 element
in html + css, any idea on why it cant?
yeah that will work here 100%
transparent lemao
i'd have to see the CSS to tell you why its happening
<!-- Actual Webpage -->
<div id="display">
<div class="scroll_1">
<br>
<h2>Welcome to my Landing Page</h2>
<img id="loaded_pic">
<h3>Saya
<span class="txt-rotate" data-period="4000" data-rotate='[ "Amanogawa", "#0113", " is qt"]'>
</span>
</h3>
</img>
<svg width="40" height="90" viewBox="0 0 50 130">
<rect id="scroll_down" x="0" y="5" rx="25" ry="25" width="50" height="120" stroke="white" fill="#686868"
stroke-width="4">
</rect>
<circle id="scroll_moving_circle" cx="25" cy="32" r="8" fill="white"></circle>
</svg>
<h5>Scroll Down</h5>
</div>
<div class="text_bg">
<h5>About me</h5>
<h6>A self taught developer in Node.js. The creator, and one of the maintainer of the Discord Bot named Kashima. I also know a bit of Java and currently studying HTML and CSS. Most of my hobbies include reading visual novels, reading mangas or watching anime when I have time to do so.</h6>
</div>
</div>
the html code
#display {
height: 100%;
width: 100%;
text-align: center;
display: none;
}
.text_bg {
background-image: url("https://amanogawa.moe/assets/about_bg.jpg");
max-width: 100%;
padding: 50px 80px;
}
.scroll_1, .scroll_2, .scroll_3 {
position: relative;
background-attachment: fixed;
background-position: center;
background-repeat: no-repeat;
background-size: cover;
}
.scroll_1 {
background-image: url("https://amanogawa.moe/assets/bg.jpg");
min-height: 100%;
padding-bottom: -10%;
}
it has inherits on the framework I use which is the skeleton http://getskeleton.com
try putting border:none; on the scroll down element
my guess is that is the problem
might have to override as well, even though that is considered bad practice
you can alway inspect using chrome to see where the border is coming from
Ok I'll try
eems like it isnt on the scroll down
@serene oar I found the issue, it was the padding of the .scroll_1
interesting
must be a part of the framework
glad you figured it out
oh nvm i see it there
Wrong token?
should I be worried that 640 servers are using 2GB of my server's RAM?
Depends on how much RAM you have
100% is 2GB
Then probably yes, what does your bot do?
quote messages, it only caches server basic configs like prefix so idk
You should plan to get more ram tho
how do i keep my bot from doing this? i've tried stopping it from doing that myself, but i about fucking give up
@grim aspen What language?
discord.js
if (message.author.bot) return;```
Alright
@ruby dust have you checked for possible memory leaks? my bot is at 780 servers using ~300mb ram
not yet, but I've currently restarted the bot and now trying to get the updated graph
it went down to 76% @quartz kindle
What lib are you using?
@ruby dust how much do you pay for 2 GB
also where does that data come from?
.... I'm paying 2$ for 128 mb ram
it's more accurate to query the runtime for mem usage
it may have allocated more but isn't using it all
I'm using OVH's monitoring tab
also you can try eg htop
to see if the memory is actually being used or it's only disk cache
huh, didn't think of that
my google monitoring panel says my bot is using 30-50% cpu, but my top/htop says 1-5% cpu
alright I'll check that out then
@coral trellis night bruh
@potent frost Night, next time #memes-and-media or #general uwu
good day. is there a way for testing to trigger the webhook for upvotes without actually upvoting?
@viral spade right underneath the save webhook button
does anyone know why i cant open the glitch dot com website on my ipad? It shows a white screen
life hack; use proper hosting
use a vps
What is a good not too expensive VPS
check pins
Personally I started out on vultr but now use ovh
?
click that link
btw
?
did it ever happened a hosting stole a bot
idk
?
your host shouldnt even be able to get into the machine if you set it up right
well
at least into your os
meh
Why would they want to steal a bot anyways
Im new to coding so yeah don't know that much xd
That'd be a big privacy concern and they'd get loads of backlash for doing that
tru point
they wouldnt be in business if they stole random people's tokens
and ye
Especially when you're paying them
as long as you dont choose the sketchiest site ever
learn to code too
or liek some "free hosting here!!" site
"just paste your bot token here"

maybe i should set something like that up...
I'd back your project
Praying on idiots != fraud
scaleway got even cheaper since that message
Ads
it's 2€
if sketchy site != 'costs $10 per month':
print('abandon ship lol')
or maybe even less
idk
thats what i do when im bored dont question
on('userSignUp', (user, token) => {
new AdvertisingBot(token)
new Testimonial(user, 'positive')
})```
Yeah but they're
if (condition) {...}
why do i have a server in my discord that has a image of elon musk as the icon
im not gonna question
Not
if condition:
...
honestly the if staments for py are
if [condition] {variable} [condition2]:
it will keep it on
so like
If you set it up properly it will always run @earnest phoenix
if name == 'Lazy':
print(name)
meh tru
i should put it on some vps
but idk yet
i should FinIsh it
I can host for you, just send bot token and SSN
Hey im trying to make it so that it shows the amount of times someone with a certain id sends a message and grab the total, but it keeps saying the total sent is 1? Does anyone know what im doing wrong? Im quite new to programming
no
not goin to do that
mmmmmmmmmmmMMMMMMMMMM
if it was py it would be so freaking simple
@earnest phoenix I believe it has to do with scoping
try declaring without var
just i = 0
Alright i'll try that thanks
xd

Declare that before the message event
use common sense, you're redeclaring the same variable over and over again
its not in the event itself its outside it
How can I make this code so ony I can do the command
const discord = require("discord.js")
module.exports.run = async (bot, message, args) => {
if(!message.member.hasPermission("MANAGE_WEBHOOKS")) {
message.delete()
return message.channel.send(`**ERROR**\n${message.author} You are missing the permission: **\`MANAGE_WEBHOOKS\`**`)
}
let reply = args.join(" ").trim();
if (!reply)
message.delete()
message.channel.send({embed: new discord.RichEmbed()
.setDescription(reply)
.setColor("RANDOM")
});
message.delete().catch(O_o=>{});
};
module.exports.help = {
name: "embed"
}
where?
(quite new to coding)
Oh shit I have a unit test in < 20 mins
oof
and I haven't studied
Add a js if (!msg.author.id == yourIdHere) return;
like this
let ownerID = "266962438685982720"
instead of
if(!message.member.hasPermission("MANAGE_WEBHOOKS"
?
ah ty
ERROR
@earnest phoenix You are missing the permission: MANAGE_WEBHOOKS
thats what it says now
return it
Because you're missing that permission...
^
wait
so now only I can use it but I still need MANAGE_WEBHOOKS permission?
thats cool
um
I have the manage webhook permission
but still if I do the command it returns:
ERROR
Only cdxx 🦑#6666 can use this command
@scenic kelp wrong
O
!msg.author.id == yourIdHere won't do what you want
Sad
operator precedence
Yes I am dumb
! has a higher precedence than ==
!=
Remove the ! and do != I thincc
no
No
^ not to be rude but what he said
A command for ddmall user on a server discord is unautorized by discord ?
can anyone help me how to do the servers (and dont send me https://discordbots.org/api/docs) because i don't understand it, if anyone can explain it to me
ow..
thanks didnt see it
python lib is broken afaik
yes
cool
the page literally tells you everything you need to know and even gives you codesnippets regarding its implementation, it's not that hard to read the documentation and figure it out
.
do you need help with anything? ^
class Log:
def __init__(self, bot):
self.bot = bot
async def log(self, x: str):
print('Foo' + x)
class foobar(commands.Cog):
def __init__(self, bot):
self.bot = bot
@commands.command(name='bar')
await logger.Log.log(x='bar')
def setup(bot):
m = foobar(bot)
bot.add_cog(m)
Anyone know why it says that the self parameter is unfilled when using the log()?
And how to fix this?
Still need help?
@ruby talon After specifying x in command Logger.log, slap ctx in
Also, it will be log.callback
my bot got accepted yaay
Congrats 🍾
hey guys
i need bot if know someone like this
I need when someone join main room voice called: "Create Party here"
When someone joined there, bot will automatic create for him new room called: Party 1 and bot will moved him in that voice channel. Voice room limit 0/3
Translation:
"when a user joins a VC named create VC the bot would automatically create a voice channel and move the user to that channel"
thats pretty damn specific and you probably won't find that anywhere
Ah
write it yourself
Yeah
Yuh
Gonna need to pay or write it yourself
Y e
this bot doint almost that
but dont lika nems ofr voice room
can i change that ?
someone know ?
Would really just recommend buying a cheep laptop to host like i do
ask in the bot's support server? 
cheep laptop and host nasa haha 😄
ok test and tell me ty
bcs im not rly good on this bots like u guys
but i have good server and need this for help my gamers
it's alright
Np
but do try and learn to code whenever you can
Very useful skill to have
just so you can have a better understanding
yes i can understound like normal things about bots/cmd
@grim aspen what language do you program in?
but this what i looking i thinks it's hard for me explain or find
and i find this server for look help
nodejs
Ah nice
library: discord.js
nodejs is still not a programming language 
.py
yes right
it's good enough
Temporary
can be replaced to 1 , 2 ,3 ,4
T = temporary
?
It can not be changed as of now
when some come and scream in party rooms
i need check logs
all rooms called same
i need numbers
u know what i mean
So you want a speech-to-text moderation bot
nah
Do you even know how long that would take
no that bro
That is allllloooootttt of work
i need same like this bot
Even creating a mp3 file
I told you
You cannot change the name of the VC as of now
I cant even figure out how to receive audio from a vc
create a mp3 file, and have it record the audio
Sure
ok i will contact support server of this bot
and this bot is hard for make
like this bot
just ask your question, no point in asking whether or not you can ask
You need to give sections of it what the problem occurred from
why restrict yourself to input from a single person when you could have a few hundred
we only need the code that gives error to identify bugs, not entire code..
^
^
^
What doesn’t work?
Mmmmm...
^
i tested this bot
and it's create double same party room
that is problem only about this bot 😦
if(message.content == 'help') {
// message.reply('commands');
message.channel.sendMessage('Quotes:
*connor licks blue blood* (with stars *)
Where is Hank?
Hi!
How are you?
I am good, thanks!
sbeve
Kickerinio
oof
Hank_Androids
Connor
ping
');```
There xd
^
Ye
And it's colorful o3o
sendMessage is deprecated, use .send to prevent problems in future
if ur library is discord.js
change .sendMessage to .send
it will be removed in future
Dep... yes
the string you're trying to send is probably fucked which is why you get the comma warnings
' ' quotes are for 1 line strings
if you want multiline strings you either have to use ` or combine single strings with a +
or use ' with \n to separate line
mind sending a screenshot of the code you sent earlier (alternatively you could use discord's codeblocks but use em properly, no need to separate anything)
if(message.content === 'help') {
// message.reply('commands');
message.channel.send("Quotes:\n*connor licks blue blood* (with stars *)\n\nWhere is Hank?\n\nHi!\n\nHow are you?\n\nI am good, thanks!\n\nnsbeve\nKickerinio\n\noof\n\nHank_Androids\n\nConnor\n\nping");```
@earnest phoenix tell me if this code works? ^
But that's py?
...?
Or does js now look very similar to it
That if statement looks almost exactly like a python statement
Ye
and @west spoke == can also be used in js but it is for .type
i hope you realize that == works aswell
MeH
I like is most of the time
== is only for type
ime
Shhhh
holy shit might that be c++ because that if statement literally looks like something out of c++
for == in js
if (message.content == String) message.reply("message was a string!")
can't get any more wrong than that
== compares values, === compares values aswell as types
Ah
xd
how do you even work on bots if you have no clue about the most basic syntax there is to any programming language, shit's beyond me
Me?
if(message.content === 'help') {
// message.reply('commands');
message.channel.send("Quotes:\n*connor licks blue blood* (with stars *)\n\nWhere is Hank?\n\nHi!\n\nHow are you?\n\nI am good, thanks!\n\nnsbeve\nKickerinio\n\noof\n\nHank_Androids\n\nConnor\n\nping");```@earnest phoenix does that code work or not??? ^
no
Me?
if you have never in your life used == why in the world are you claiming things you cannot have any idea about
I had read about == a year ago...
=== compares types?
types and values
aswell as value yes
Neet
Ew
xd
thats the firefox console which for some reason isn't affected by my dark theme
Actually wait, I got it wrong. Sounds about right
use node.js console
Yeah thanks for clearing my memory up
search node in Start
you don't have to teach me about how to use my environment, i certainly am well aware of how to use node
it just seemed faster to use my browser
to prove a point i shouldn't have to prove in the first place to someone who develops bots
oof
let's start over, https://hastebin.com/ paste the code snippet over here for simplicity and send the link in here
does it error out in your console when trying to use the command
https://i.ryeqb.me/5d5ef39142.png the string you use works for me (im on eris but that shouldn't affect it), looks weird but it works
so your string fucks codeblocks thats for sure
sec
if you just copy pasted what i sent you it obviously won't work because im using a different library
oh its commented, im blind lul
if you need to use ' somewhere within a string define the string itself with either " or `
he's already been told
fix your brackets before caps responding to something he's right with
how is he not right?
sendmessage is outdated and you shouldn't use it period
deprecated means its still in the code for compatibility reasons but will be completely removed in future versions
so they give you a time frame for you to adjust your code before the next update permanently removes it
it still works for now, but who knows for how long
Anyone help me?
as tim mentioned earlier, your code doesn't execute properly because you're throwing brackets and braces all over the place
(node:2704) UnhandledPromiseRejectionWarning: TypeError: Cannot read property 'id' of null
my swear blocker
whatever you're trying to read the id of isn't defined
says so right there in plain english


hows that even an omegalul anymore
if your bot processes messages sent via dm channels it won't be able to grab an ID
= is for variable assignment
== and === are for comparison
== or ===?
=
const kufurengel == db.fetch(`kufur_${msg.guild.id}`) ?
for the third time, no
if msg.channel.type ( https://discord.js.org/#/docs/main/stable/class/Channel?scrollTo=type ) is 'dm' or 'group' msg does not have a guild property
cause there is no guild
if your bot responds to message events fired from dms your code will error because it cannot get an object property as it doesn't exist
:/
i just read up in chat and @earnest phoenix i suggest reading up on this https://stopbeingabad.dev/#general-being-an-asshole
help yourself
that will get you the channel's id, not the guild's id. if you have things saved in your db under guild ids you'll be searching for a long time if you try accessing your data via channel ids

Guys it's better to actually learn javascript before trying to code
just a little advice
@gleaming tulip why are you so hungry
because you're eating so much
im meming you
bad meme
you didnt get it
Sorry, I don't understeand 😦
@earnest phoenix do you know what a DM is?
😩
@quartz kindle directmessage ?
yes
hi
100 points, are direct messages guilds?
guilds = a server (like the one we're in right now)
how many time will take to approve my bot in the site ?
@earnest phoenix
msg.guild.id (message -> guild -> id)
msg.guild.id (directmessage -> guild (???) -> id (error))
@quartz kindle there
that's an unfortunate statement sir
one is a kinder version of saying the other 
ok so lets clear it up: i know what spoon feeding is, and we are not really spoon feeding here, and you kept spamming the spoon feeding emote, so i memed you because it looked like you were feeding yourself with so many emotes
@earnest phoenix ty
how is it not spoon feeding, that's such a basic error, with means they have very low JS knowledge.
if that's spoonfeeding why don't we consider references to the api/documentation spoonfeeding
can easily be researched
if people can't find it or simply aren't sure they're incompetent and have no clue how to use the language they're working with™
and what is this?
You forgot the part of the error with the error
imma save that to my bookmarks
@earnest phoenix who made that website and why is there a node_modules directory in it
its react
react loads all of that?
i love how it literally includes a module called "isobject" that is just one line of code lmao
npm best packet manager /s
also this
yeah probably because it pulls data from gh pages
🤔
oh thats why everything is rendered client side
yeah
xd
and he left
Who
why doesnt (!message.guild.me.hasPermission("SEND_MESSAGES") work
it just ignores it
message.guild.me.permissions.has("SEND_MESSAGES") is this working
no
it still gives me error in console
Missing permissions
it works with other permissions
just not with send messages
oh
wait a second
try with SEND_MESSAGE
ok that was dumb it wont work
let me try it
.
if this works
if (message.guild.me.hasPermission("ADMINISTRATOR")) {
why wouldnt
if (message.guild.me.hasPermissions("SEND_MESSAGES")) {
why'd you say it's not working
fdklojasdkg


