#development
1 messages ยท Page 421 of 1
kek
no
Don't put your token on github
DONT USE GITHUB 4 BOTS!
true
I don't have my computer yet though
but it's still acessable
you'd rather have the files on your pc, then use filezilla to transfer them to your host
if i log my token i get lol
Laptop
which is the current server prefix
By putting your bot on public github you are asking for trouble
@gusty topaz how
ok, use git clone then
^
Clones, leaks
and clone the repo
I'm just so lost
ikr

still dont know why it returns [object Object]
If you're not a fucking retard then how would you leak anything?

oh boi I'm uploading my bot to github I sure hope nobody looks at my token.json file...
BECAUSE IT'S AN OBJECT @knotty steeple
gitignore isn't hard to configure
It is a private repo
@knotty steeple does it return ["lol"] or "lol"?
@earnest phoenix GIVE ME YOUR GITHUB XD
Sure
"lol"
o
I'll pm
hmmm
idk i gtg
actually just lol
is it hosted on glitch.com
no
it's suckybot.github.com
.gitignore is ez, just use the node template and shove the config file in there
its on vps
hmmmm
shared one 
it should be on glitch
cause it's better
thats all I have to say
not looking at yer code
how is glitch better than a vps
Whatevre I'm hosting it on somee
cause u can let others edit it
Whatever
why tho
lol jk
and look at it
github is for that
@earnest phoenix u still getting errors
somee is terrible
Or no
yes
Did you update the code
Like I said
I don't even wanna code a fucking bot anymore I am so confused
glitch <<<<<< vps
Free hosting will always be worse than a vps
ik
@shy verge nice meme
I think I'm gonna go back to web development
ok
Technically they are
how
yes, but they aren't for the web
They're not websites
that's like calling osu! a web app because it interacts with it's own api
I think I'm gonna stick with heroku for now
gayroku
ik
Whatever suits you man
I use localhost
I'll prob use the linux VPS later
No issues never ever
I could host it at my house too ๐ค
But my slow ATT internet will slow to a halt
Of it's a small bot it's ideal
If*
Besides you can also setup a db server
I can host it on a pi
Or something
db?
Database 
o
I host my bots on Windows 93
same
Using IIS
I host my bots on Windows 9
I'll look into skysilk when I get my computer
cuz I have a chromebook rn
As my main
For skysilk I believe you need to enter your credit card
chromebook 
If you don't have one then rip
It runs ubuntu
Gnome
I replaced chromeos
Gnome for servers 
a chromebook that runs ubuntu 
USB boot
kek
Run windows 2000 on a usb drive
Chromeos is still there
I'm a hacker now
waw
I wanna try to fix this
I'm prob gonna add some simple commands and ditch bots forever
I told you how to fix your bot
When did yoi start getting errors anyway
It got lost I guess
today
arg
What did you add in
Undo it
100% fixed
Case closed
2018-05-27T15:55:21.425681+00:00 app[worker.1]: client.user.setPresence({
2018-05-27T15:55:21.425684+00:00 app[worker.1]: ^
2018-05-27T15:55:21.425685+00:00 app[worker.1]:
2018-05-27T15:55:21.425687+00:00 app[worker.1]: TypeError: Cannot read property 'setPresence' of null
2018-05-27T15:55:21.425690+00:00 app[worker.1]: at Object.<anonymous> (/app/bot.js:29:13)
2018-05-27T15:55:21.425691+00:00 app[worker.1]: at Module._compile (module.js:652:30)
2018-05-27T15:55:21.425693+00:00 app[worker.1]: at Object.Module._extensions..js (module.js:663:10)
2018-05-27T15:55:21.425694+00:00 app[worker.1]: at Module.load (module.js:565:32)
2018-05-27T15:55:21.425696+00:00 app[worker.1]: at tryModuleLoad (module.js:505:12)
2018-05-27T15:55:21.425698+00:00 app[worker.1]: at Function.Module._load (module.js:497:3)
2018-05-27T15:55:21.425699+00:00 app[worker.1]: at Function.Module.runMain (module.js:693:10)
2018-05-27T15:55:21.425701+00:00 app[worker.1]: at startup (bootstrap_node.js:191:16)
2018-05-27T15:55:21.425702+00:00 app[worker.1]: at bootstrap_node.js:612:3
2018-05-27T15:55:21.479894+00:00 heroku[worker.1]: Process exited with status 1```
ik but I wanna have the custom presences
I saw that already
How do I fix it though.............
I told you
Many times
Not by removing it
Delete the second client login
Where
Omg
line 16 or somethign

Look for it
B o i
I saw that
ik it's deleted
It's somehwere in line 10-15
I d e l e t e d it
Okay did you try again
To run the bot
same thing....
Hastebin
Line 7
Change it with your token
ok
Don't delete the client login part
Just what's between ()
ok i fixed the [object Object] thing with my prefix
it could be because bot not ready yet?
not certain
And don't upload the code anywhere
thanks for the help that i didnt get
I don't think so
He said his code was working before
It is already there
ill check real quick
nice token leak
It is not the full thing
still
lmao
It's a useless bot
atleast i have part of your token
ye its because of that
time to crack the rest
also everything before the first . is just the client id of the bot to base64
so...
you can't do shit with it
reset that token
Why?
No need
It was just his bot's id to base64
Just fix the error first
it's basically useless @knotty steeple
ik how though
Put the token
There
Nnantis said smth
That could fix it
imma just do tht
you're calling setPresence before bot is ready - Ntanis
He might be right
2018-05-27T16:03:24.794106+00:00 app[worker.1]: ^
2018-05-27T16:03:24.794107+00:00 app[worker.1]:
2018-05-27T16:03:24.794109+00:00 app[worker.1]: TypeError: Cannot read property 'DeTb' of undefined
2018-05-27T16:03:24.794111+00:00 app[worker.1]: at Object.<anonymous> (/app/bot.js:7:51)
2018-05-27T16:03:24.794112+00:00 app[worker.1]: at Module._compile (module.js:652:30)
2018-05-27T16:03:24.794114+00:00 app[worker.1]: at Object.Module._extensions..js (module.js:663:10)
2018-05-27T16:03:24.794115+00:00 app[worker.1]: at Module.load (module.js:565:32)
2018-05-27T16:03:24.794117+00:00 app[worker.1]: at tryModuleLoad (module.js:505:12)
2018-05-27T16:03:24.794118+00:00 app[worker.1]: at Function.Module._load (module.js:497:3)
2018-05-27T16:03:24.794120+00:00 app[worker.1]: at Function.Module.runMain (module.js:693:10)
2018-05-27T16:03:24.794121+00:00 app[worker.1]: at startup (bootstrap_node.js:191:16)
2018-05-27T16:03:24.794123+00:00 app[worker.1]: at bootstrap_node.js:612:3```
I removed the token
But it does not like it

Which is why I used a variable
Boi
Lol
arg
I told you to remove what was between ()
wdym
The whole thing, not just the .token
o
Ofc it won't work
huh
As is
arggggggkgpoekep
kegp4o9ik49gkog

Replace what's between brackets
With your token
And put a " before and after the token
pls get real vps
Ez
^ also
Since it's on localhost nobody has access to the file anyway
shared vps is great ๐
2018-05-27T16:06:47.965050+00:00 app[worker.1]: client.user.setPresence({
2018-05-27T16:06:47.965051+00:00 app[worker.1]: ^
2018-05-27T16:06:47.965053+00:00 app[worker.1]:
2018-05-27T16:06:47.965055+00:00 app[worker.1]: TypeError: Cannot read property 'setPresence' of null
2018-05-27T16:06:47.965057+00:00 app[worker.1]: at Object.<anonymous> (/app/bot.js:29:13)
2018-05-27T16:06:47.965058+00:00 app[worker.1]: at Module._compile (module.js:652:30)
2018-05-27T16:06:47.965060+00:00 app[worker.1]: at Object.Module._extensions..js (module.js:663:10)
2018-05-27T16:06:47.965061+00:00 app[worker.1]: at Module.load (module.js:565:32)
2018-05-27T16:06:47.965063+00:00 app[worker.1]: at tryModuleLoad (module.js:505:12)
2018-05-27T16:06:47.965064+00:00 app[worker.1]: at Function.Module._load (module.js:497:3)
2018-05-27T16:06:47.965066+00:00 app[worker.1]: at Function.Module.runMain (module.js:693:10)
2018-05-27T16:06:47.965067+00:00 app[worker.1]: at startup (bootstrap_node.js:191:16)
2018-05-27T16:06:47.965069+00:00 app[worker.1]: at bootstrap_node.js:612:3
2018-05-27T16:06:48.043126+00:00 heroku[worker.1]: State changed from up to crashed
2018-05-27T16:06:48.027268+00:00 heroku[worker.1]: Process exited with status 1
omfggg
orgpoergk
ARGGGG
I don't wanna do this anymore ._.
Me neither
What is this output ew
its heroku @native narwhal
And that is? ๐
Sounds fishy
I put things together
And it somehow worked
Sure
I don't even know
Okay
I gtg
yea
Ask someone else for help
I'm ditching this piece of shit
@harsh star
Did you even learn how to code
I know how to code
Not trying to be rude
Oh okay
I'm not good with JS
I'm rlly good with HTML/CSS though
I see
I'm taking a JS course over the summer, I'll prob restart once I have more knowledge
Well you better step up your js then
yea
Angery
Like windows 93
whaterve imma go back to html
Good luck
@earnest phoenix
link Discord.js Guide, a guide with many detailed sections you can use to assist in your bot development!
link http://discordjs.guide/
A guide made by the community of discord.js for its users.
is it possible somehow to use Discord's voice call through a VoIP or phone bumber system?
Yes
Cloud communications platform for building SMS, Voice & Messaging applications on an API built for global scale. Get started with a free trial.
It's paid tho
So you could but you'll probably need to charge for bot use
@earnest phoenix does that
I have another mongo related question
I have the following document:
{user:1234, meta:{name:{field1: 0, field2}}}And I want to be able to add another "name" field to "meta" while keeping the data intact. How would I go about it?
I want to keep everything as is but add new fields basically
var thePresident = new pizzapi.Customer(
{
firstName: 'Barack',
lastName: 'Obama',
address: '700 Pennsylvania Avenue, Washington, DC',
email: 'barack@whitehouse.gov'
}``` for like the firstname last name adress and email that can be saved right?
store whatever you want, but since it's not provided by Discord you HAVE to encrypt it
no
such info can't be saved like that
users have to agree on it and you also need to provide them ways to do stuff
read up GDPR
@earnest phoenix aren't you a mongo user? Maybe u could help me with my little issue
imo don't go that way, doesn't worth the effort to try and do a domino's bot, legal wise
I really need to read the documentation again
at least if you want to make it public xD
ehh nao no
I am the sometime-I-used-firebase user

Oh yeah
Lol
I'll read the docs then
They must have an article about this
Yep I'm a noob, just found out I can use $set
Got it to work :3
well
I thought i did..
if (typeof property !== 'boolean') return message.channel.send(`Instead of using ${property}, try using a boolean (true/false)`)```
is this because its a string?
yes
parse the string
no
no
boolean !== json
ah
do Boolean(string) to parse it
okay
so
property = Boolean(property)
if (typeof property !== 'boolean') return message.channel.send(`Instead of using ${property}, try using a boolean (true/false)`)```
yes try that
u should probs check if the string is actually true or false first
okay
this?
if(property.toLowerCase() == 'true') Boolean(property)
if (typeof property !== 'boolean') return message.channel.send(`Instead of using ${property}, try using a boolean (true/false)`)```
I see on stack this is what they use
Boolean boolean1 = Boolean.valueOf("true");
boolean boolean2 = Boolean.parseBoolean("true");```
o
Java is not JavaScript
ok good
Oh sorry I just realized i was in the wrong stack
i was like wtf
What is it you're trying to do?
if(property.toLowerCase() == 'true') Boolean(property)
if (typeof property !== 'boolean') return message.channel.send(`Instead of using **${property}**, try using a boolean (true/false)`)```
check if property == boolean
but its a string
just to save some sanity I would make it a toggle instead of parsing a string into a bool
so check if a string is a boolean
Why don't you just do
if(property.toLowerCase() === 'true') {
}else if(property.toLowerCase() === 'false') {
}else{
return message.channel.send(`Instead of using **${property}**, try using a boolean (true/false)`)
}
what if instead of 'boolean' do Boolean
this works :3
property = property === 'true' ? true :
property === 'false' ? false :
property;
if (typeof property !== 'boolean') return message.channel.send(`Instead of using **${property}**, try using a boolean (true/false)`)```
smh gotta fix lol http://prntscr.com/jnafut
nvm i just added a || id
W O K E coding:
if (response.get(1).toLowerCase().equals("true".toLowerCase()) {
// its true
}
rly gud
Guys
I want to know
At a simple command
For python
For example:
@bot.command(pass_context=True)
async def uptime(ctx):
await bot.say('Uptime {}'.format(uptime_here)```
How to set uptime
in discord js, when the promise returned by #Client.login resolves, am I 100% sure that the login was successful?
Like if I have await client.login(config.token);, can I be sure that after that point the client is logged in
and I can do super fancy shite with it
okay I found this in d.js code
this.client.once(Constants.Events.READY, () => {
resolve(token);
this.client.clearTimeout(timeout);
});
0w0
no need to answer anymore
@gusty topaz Yes, it logged in succesfully but that doesn't mean that its ready yet, you need to wait until the Client emits the "Ready" event after that you can work with it as normal
isnt boolean 1 or 0?
@mental solstice 1/0, True/False.
was reading above and they are trying to figure out to set boolean from a command. I assume he would have needed to use 1 instead of true
at that point its a string, it all comes down to how the bot interprets it
@tardy hatch Haven't you had a code for that before?
Nope
def get_bot_uptime(self, *, brief=False):
# Courtesy of Danny
now = datetime.datetime.utcnow()
delta = now - bot.uptime
hours, remainder = divmod(int(delta.total_seconds()), 3600)
minutes, seconds = divmod(remainder, 60)
days, hours = divmod(hours, 24)
if not brief:
if days:
fmt = '{d} days, {h} hours, {m} minutes, and {s} seconds'
else:
fmt = '{h} hours, {m} minutes, and {s} seconds'
else:
fmt = '{h}h {m}m {s}s'
if days:
fmt = '{d}d ' + fmt
return fmt.format(d=days, h=hours, m=minutes, s=seconds)
@bot.command(pass_context=True)
async def uptime(self, ctx):
await bot.say('Uptime {}'.format(self.get_bot_uptime)
You could use Google and learn a bit of Python, just in case.
@floral stone u can help me?))
To set uptime
In command
In this line:
await embed.add_field(name="Uptime", value=uptime)
await bot.say(embed=embed)```
There
With format or
To set uptime
And how
secs = round(time.time() - process.create_time()), 3)```
Seconds will return the amount of time your process has been running
At value?)))
add those 2 lines above
await embed.add_field(name="Uptime", value="{} seconds".format(secs))
I updated the code
Oh
you could just divide the seconds by 60
I ll try to transform single
so my serverinfo command is broken in this server
is there any way to make it not broken
that question is so vague the best answer I can give you is "fix it"
lol
@knotty steeple elaborate
File "bot.py", line 130
secs = round(time.time() - process.create_time()), 3)
^
SyntaxError: invalid syntax
I moved
On user
ok
But i have error
I don't really use python that often so I can't help you there 
@floral stone how can i convert seconds to minutes and hours? ๐ค๐ค
maths
more like long maffs
How do i convert python to maffs

Do i delete system32?
multiply them
60 seconds = 1 minute
then convert minutes to hours
60 minutes = 1 hour
therefore 3600 seconds = 1 hour
or
60 * 60 = 1 hour in seconds
Lol
@earnest phoenix how to set in code, ffs
what language are you using
that should be basic stuff
if you don't know how to multiply in code
you might aswell take a whole course about it
Python
I don't use python sorry
tbh you should know how to multiply in python
look it up
psuedo code:
def StoH(s): // seconds -> hours
return s * 3600;
def MtH(m): // minutes -> hours
return m * 60;
@trim plinth u can help me to put that in code..?

=)()
it should be easy enough to do it yourself
Wouldnt that formula return a massive number tho @earnest phoenix
ok
How would I wait for an event with JDA?
async jda??
what would return a massive number
@tepid laurel
that would be the actual seconds
which is what he asked for
sure
so like a user executes a command and it asks a question
then it waits for message event
add the user to a list, then on the message event check said list, if the user is in the list, go from there
o rlly
Ya
hmm
you could use that formula + timestamp
use that formula to calculate ms
then timestamp - ms
or + depending on future or past
understand?
Or you could just divide
Yeah fam
<seconds> / 3600
Or even do it with minutes which I think is better
that's what I said
it would be logical to use division instead of multiplication with the formula
I previously stated
Ya but ur doubling it
??
In that code u sent b4
oh true
Rip lol
๐๐
oof
Guys..
Girls..
@bot.command(pass_context=True, no_pm=True)
async def stats(ctx):
process = psutil.Process(os.getpid())
secs = round(time.time() - process.create_time(), 1)
minutes = 1 * 60
embed = discord.Embed(title = '__Stats__', colour = 0xFFFF);
embed.add_field(name="Uptime", value="{0} seconds / {1} minutes".format(secs, minutes))
await bot.say(embed=embed)```
I have this command
Okay?
Great news
How to set minutes
dont spoof feed him
Wasnt gonna
Rip
Ffs
Sake is not here mate
I don t ask for jokes
Look.
I want to set bot, if seconds is 60, to set at 0 and to add one minute
Okay and
Wait not and
First of all where do you get your 60 seconds from?
Is it from your bots actual uptime, do you guess it, did you set an interval
Whatd you do
I call that a wizard explanation where someone tells you something and expect you to know the context of the question thus making you a wizard
Bruh if I got paid for being that wizard so often even just 50 cente
Or to add minutes & seconds
Id be a millionaire by now
I think a lot can relate
@tardy hatch in your bot is not an actual understanding
In your bot is so much you probably dont even know half about
So how did you once again get the 60 seconds
Is it from your bots uptime
?
But you will have to store the minutes somewhere
minutes = secs * 60
What
For example
No
If seconds is 2
Minutes will be 120
If u did that
Yea
What a fucked up thing to do
If you want to get the actual minutes
You need to divide the seconds
And round it to no decimals for clean look
'/'
<seconds> / 60
you should probaly do some basic programming tutorials if you dont know math operators
@tepid laurel
What

yes
you should probably learn basic python syntax before making a bot if you don't know how to even divide with it
I got it
https://www.youtube.com/watch?v=N4mEzFDjqtA Pretty quick 45 min video on python. I reccomend watching
Get the Cheat Sheet Here : http://goo.gl/Rv01oG Best Book on Python : http://amzn.to/1NxiMLo Beginner Python Tutorial : https://www.youtube.com/playlist?list...
That youtuber is good I learned basic clsip and c# from his videos
at the start
@unique solar and i want to remove seconds..
When seconds will be 60
To set at 0..
round it up you mean?
I think you should take a look at that video and google a bit
I dont know python. So your gonna have to look how to round in python
@tardy hatch use something like
Ffs
wdym ffs
dude if you wanna make a bot then your gonna have to learn at least basic programming
period
do you think were all just gonna help you when you make no effort to try and google?
Cant blame them for being sick of that๐คท๐ผโโ๏ธ
and now he disappears
like the stuff we are telling you is what I learned on the very first day of my first programming class ever in grade 11
Basic shit
like i can google, "how to round a number in python" and like a million results will come up
Yup lmao
Man
When seconds will be 60
I want to add +1 at minutes
And to remove -60 at seconds
..
You just make a var from it
i aint helping you anymore and reccomend nobody else help you until you figure shut out your self
basic shit
I doubt you'll really get the exact code you want, you just need to learn it yourself..
I did it..
Your equations are okay but if you wanna do what you want to
@bot.command(pass_context=True, no_pm=True)
async def stats(ctx):
process = psutil.Process(os.getpid())
secs = round(time.time() - process.create_time())
minutes = round(secs / 60)
hours = round(minutes / 60)
days = round(hours / 24)
embed = discord.Embed(title = '__Stats__', colour = 0xFFFF);
embed.add_field(name="Uptime", value="{3} days\n{2} hours\n{1} minutes\n{0} seconds".format(secs, minutes, hours, days))
await bot.say(embed=embed)```
man there's an easier way of doing uptime, with the time module
make like a function to add hours if there is hours
doesn't python have the % operator?
can't send to bots
it's way easier to do with that
it does
as far as u know a bot cant dm a bot
Electron is a user ;3
yeah
I mean you can just use time module's divmod to do basic uptime
why tho
member.send(`You've been kicked from ${message.guild.id} for ${reason || "No reason specified."}`).catch(e => {
message.channel.send(`Didn't send the reason to ${user.tag} because they have dms blocked ERROR: ${e}`)
})```
Well i needed to know what was happening
it could just be Didn't send the reason to ${user.tag} because they have dms blocked
Send to a user
I did before
just saying
that didn't work either
dms could be blocked
No
Broooo
why even say that? it can just fail that silently
its a member object ๐
smh
Just said that
thats why im using user now
val seconds = time % 60
val minutes = time / 60 % 60
val hours = time / 3600 % 24
val days = time / 86400```
considering time is in seconds
one is for when you want it disabled on new servers, so you don't get dm spammed by bots
just had to use await
Guys
:3
On command error, for example potato akdkdksksksk, how to make bot to response with Command not found.
:))
Thats so fucking annoying
no unknown command responses
I have a code
mainly asking how to annoy users the common way
But it s wrong
your bot will be instantly denied/muted 
Loool
*i don t want to make bot public, ffs
but if you do disable it here
actually, why warn him? not like he ever listened to us, so lets just help this little dude
well im gonna go because i dont know python
Well you could do it e.g by storing your commands in the cache or so
Or in a array whatev
If it dont exist somewhere in there or whatever make it return that memeโ ๏ธ
Okay
A few searching hints tho
Use logical keywords to what you need
Theres a difference between like e.g 'python how to check if a command exists' or like 'python command cache/ python array usage (has/push)'
And np๐๐ป

How i can get the inviteurl created of the user?
I tried to .fetchInvites() but he still returning a object promise
did you do await on it
oh...
lmfao
How can I separate each command from my bot into a .js file inve sde sweat a file only?
What
@topaz fjord But i already set the async
english
It went from english to spanish
@spring bone show code
but if I use the command will the bot work? same without any reference where is the commands?
how old are you?
how old are you
so here is development chat, can you help me? '-'
Sure, but you need to re explain your question so I can understand you.
It's just curiosity
If you are under 13 you can get access to a special development channel 
You must a folder called commands and inside this folder the .js files of each separate command, because I use a file and inside a file all the commands are there.
i'm 16 ..
Does More Copy and Paste Work? do not need a reference in the main file where are the commands?
@wanton walrus I'm surprised people believe that
you would need to create a command handler
Ikr @floral stone
I'm out
i'm only 16, so my english is bad, i speak portuguese fluently
Turtle will help you, he owes me
i'm learning English
i do? @floral stone
yes
for wat
Being awesome ๐
owo
I'll do what I @floral stone said
owo โค
in visual studio code have a function to refactor the code and play in another file?
i dont think so
if you want to create a command handler use https://www.youtube.com/watch?v=XH1Fp77D-js
ok thx s2
channe typo
@topaz fjord no
then try it
Ok
also what Ntanis said
anyways you wouldnt be able to fetch the invites for here
our bots dont have the perms
anybody know stuff about heroku?
I have this
var sqlite3 = require('sqlite3').verbose();
var db = new sqlite3.Database('./database.sqlite');
db.serialize(function(){
})
Idk what .serialize is but
Ima go with it
serialize?
you don't need that
as far as I know
did you read the guide?
I didn't know there was a guide
most packages have a guide
go to it's github page
im on it
you're on the wrong package
actually nvm
there it is
"Usage"
serialize is to create tables right
I just used a third party app then created tables
it's way easier
idk ๐
this looks weird to me
db.serialize(function() {
db.run("CREATE TABLE lorem (info TEXT)");
var stmt = db.prepare("INSERT INTO lorem VALUES (?)");
for (var i = 0; i < 10; i++) {
stmt.run("Ipsum " + i);
}
stmt.finalize();
db.each("SELECT rowid AS id, info FROM lorem", function(err, row) {
console.log(row.id + ": " + row.info);
});
});
db.close();```
you should use knexjs
instead of pure sql
okay
npm i knex --save right?
okay so
var knex = require('knex')({
client: 'mysql',
connection: {
host : '127.0.0.1',
user : 'your_database_user',
password : 'your_database_password',
database : 'myapp_test'
}
});```
Im guessing sqlite3 is like the server and the db?
all in one?
sqlite3 is embedded, it doesn't have a client and a server, it's just a "client" if you want to think of it that way
^
knex is compatible with multiple db types
find the snippet for sqlite
oh i see
so
var knex = require('knex')({
client: 'sqlite3',
connection: {
filename: "./database.sqlite"
}
});```
knex isn't really required to use sqlite3
it'll just make things easier
ye i need it easier
lol
let commandfile = bot.commands.get(cmd.slice(prefix.length));
have error on this line?
the error:
cmd is not defined
ok thx
@shy verge Ive seen newtonsoft on nuget package manager. Just curious though, in your opinion why is xml bad?
ive used json before so I might as well
People can still talk when they are muted. My bot is made in discord.js.
how to format this date? i I want so: (dd/mm/aaaa, hours:minutes)
you would use the timestamp or whatever it's called
so you get miliseconds
then parse that with math
of the code does what I like, how would I implement it? it is used in embed.
"timestamp" : "..."
is there a way to integrate the level coding into individual commands instead of into index.js
like seperate commands into different files?
havent used js in a long time but im pretty sure there is a 'include' function
im so confused
so, my bot is working fine, right?
i decide to change it (just a bit)
and i get IndentationError: unexpected unindent
which is weird, because i havent messed with that part of the code
so, i try to fix it, then i get Syntax Error
well you'll have to tell us what the syntax error is and what the code looks like
hm looks fine but frankly I don't know python and am on a phone
you know that its not saying anything because it not bot.say its ctx.say
get a code linter for your ide and you won't have syntax or indent errors
I'd assume there's linters for python
the syntax is fine
also just a heads up @static lynx this is counted as api abuse
it'll get you ratelimitedโข
Wouldn't that be bot.say(message)?
both work ยฏ_(ใ)_/ยฏ
Wait what
Really

Async does not have ABC's, though. I doubt ctx.say would work.
@uncut slate is this self-promotion? ^
@fleet mason stuff like that isn't appropriate for #development, try #memes-and-media
Can I ask a question?
About development, sure.
What is it when people use shards?
Shards are basically only for big bots.
Only for 2.5k+ guilds.
It says shard 1, then displays stats, and on.
Is it for what servers the bot's on, and how its running?
shards is splitting the bot into 2 instances
@uncut slate its something we need XD. it think its pretty relevant
not to this channel, no
I was just wondering because like, are shards all the servers the bot is connected to, but each server has it own shard?
No.
Oh.
A shard is an instance for a certain amount of guilds.
it splits it into 2....
.
I went onto a bot's website and it says shard 1, connected, and bunch more info, and so on.
What does the connected and running part mean under each shard?
python
yes
I can't help you there.
I use discord.js
I use js
read the screenie

