#development
1 messages ¡ Page 109 of 1
no
SELECT type, value, timestamp, ((value - value) / value) * 100 AS percentage_increase from history WHERE timestamp > (NOW() - INTERVAL 2 HOUR) ORDER BY percentage_increase DESC;
i already know how to do that
basically
i want to compare the last two hours
get the percentage increase
and list it by the highest increase
as i want to add a trending section
also
In SQLite, there isn't a function called the now function, but rather "now" is a timestring parameter that is used in various SQLite functions to retrieve the current date and time. This may seem a bit confusing at first, since other SQL databases have a built-in function whose purpose is to return the current date and time. SQLite does this differently.
Error: near "2": syntax error
read above
chatgpt gave you code for mysql, not for sqlite
lol
This may seem a bit confusing at first
Imagine knowing how to ask proper questions
The error in the SQL statement is caused by the use of the "INTERVAL" keyword. This keyword is not supported by SQLite. Instead, you can use the "DATETIME" function to subtract two hours from the current time.
is this right or wrong
its probably not wrong, but thats not all of it
ok
NOW() is also not supposed
man... sqlite is dogshit
well then use what u used at first again
WHERE timestamp > DATETIME('now', '-2 hours')
ok
chatgpt may have fixed it
it started spitting out a lot of data
but idk if it's correct
lemme see
well tim already posted the query string
except the fact u need to replace the where clause
as I wrote
it didn't work
chatgpt fixed
tbh
i don't think it works properly
no way 370 -> 401 is the highest percentage increase
@lyric mountain Do you know what could be wrong? Although, literally, the console does not tell me anything.
//Message intent is on.
const client = new Discord.Client({
partials: [User, Message, GuildMember, ThreadMember],
intents: "3276799"
});
//I use CommandHandler.
client.commands = new Collection();
for(var archi_helps of archivos_helps){
let command = require("./commands/helps/"+archi_helps)
client.commands.set(command.nombre, command)
}
let archivos_helps = fs.readdirSync("./commands/helps").filter((f) => f.endsWith(".js"))
//prefix part.
client.on("message", async js => {
if (js.author.bot) return;
let prefix;
if(prefix_db.tiene(`${js.guild.id}`)) {
prefix = await prefix_db.obtener(`${js.guild.id}`)
}else if(js.author.id == "Hidden xd") {
prefix = "dev." || "ya!";
}else{
prefix = "ya!";
}
if(!js.content.startsWith(prefix)) return;
let args = js.content.slice(prefix.length).trim().split(/ +/g);
SELECT id, type, value, timestamp, ((value - value) / value) * 100 AS percentage_increase
FROM history
WHERE type = 'playing'
AND timestamp > strftime('%s', 'now', '-2 hours')
ORDER BY percentage_increase DESC
LIMIT 10;
this is the query
Uhh...tiene?
I clarify that, I have the dependencies that are seen in that code, in addition to discord.js, etc. So there is no margin for error in that aspect (I guess.)
Why are ur db methods spanish?
yes, is mega_db
Put a console.log("here") (replace "here" with something unique) after every step
I dont see any issue with the query
without seeing the data
I see
Well, before, it worked for me... since that package is in Spanish, however, I haven't updated it for a long time, and now that I've updated it, it may have changed... although it didn't give me any kind of error.
But they blocked me so they wouldn't even read my message
Don't mean u
Sorry hehe
They used keywords as column names
Without quotes it'll use the internal value instead
megadb*
'\
i showed how the data is formatted
idk any python, this is my first time using python
when i type "python" to check if i installed python correctly on my computer, it redirects me into microsoft store python
how do i fix it?
iirc it's py when you install via store
what
at first i install it on microsoft store
after that
i uninstalled it đ
then set your env var correctly if you haven't installed via the store, should be fine after that
this is my first time using python
but has a year old installation of PyCharm
oh
i never used it before
i usually use nodejs
i wanna try out something new, decided i wanna try to do python code
why'd you even have pycharm installed for a year

python <file>
oh
time to google stuff
how do i know which packages i have installed on the directory in python
python -m pip list
where can i learn about python
@earnest phoenix thanks for the help on the clang thing btw
It ended up working
<3
what website o you guys recommend for public translations?
Crowdin or Weblate
thanks
Or just make your own platform 
I suck at ui design so I doubt thats an option
Can also use basic github PRs
As crowdin & weblate & other services are paid
Weblate can actualy be self hosted
ooh, nice
Crowdin's free plan has limitations obviously
Hey can anybody please give some simple command ideas for my discord.js v14 bot?
You're welcome 
/amidumb
the answer is always yes
/swearinpolish
the answer is random polish stuff like kurwa jebana
Any other? (normal & simple)?
stealing this right now
Any of yall know why node-canvas may produce differing results depending on the machine its running on? Got two machines, my Windows 11 dev computer, and my Windows Server computer. Text renders perfectly on my dev computer, but when being rendered on my home server, the text is all shifted, aside from the text using a system font.
Im not sure its using the correct font but it looks too close to what I want to tell
Font is a custom .otf font that is installed on the machine and is being registered correctly in canvas
Good idea, strange that I didn't come up with that myself 
It really depends on what your bot specializes in. If you don't have an idea for a bot, you need to take a direction because adding everything you come up with to the bot is probably not a very good idea
different OS, different font handling
windows likes to fuck up fonts
Ah, thats kinda annoying that it differs even between Windows versions
Ez fix but still
idk if it's possible in canvas, but in java I can transform text into glyphs and have the pixel-boundary of it
certainly helps dealing with non-uniform ascend/descent (which doesn't happen in java tho)
hello
https://media.discordapp.net/attachments/1086395889750384721/1087697158804881428/standard.gif
CAN SOMEONE TELL HOW TO MAKE THIS GIF
Yeah Im just gonna have to change the coordinates for the placement. The text fits within its bounds and scales correctly, its just weird about where to put the text
ANY VIDEO EDITOR + A COUPLE WEEKS OF EFFORT
After effects?
THERE ARE PROBABLY TEMPLATES BECAUSE EVERYONE USES THE SAME BORING GIFS
sure, anything that can edit videos will do
Fivver
OK I'LL MAKE ONE
Fiverr* 
hi
Maybe not the same but generally there are some free generators on the internet
https://cdn.discordapp.com/attachments/1054010741465825310/1092462462126805102/standard_1.gif
yeah i was actually experiencing something similar
was very annoying
the link that is shared among all turkish yardim bot developers ^
that is a default generated banner you can make with like 3 clicks on a website
please don't unironically do that
I've seen enough bots with that type of banner, still gives me PTSD from reviewing
No
Other than listening to a message sent, you can't specifically listen to a message by a webhook by its URL or whatever
A message object has a webhook ID if it was sent by a webhook, use that
huh
what the fuck is this
isText is not even coming from my code but the actual node_modules folder
tf why is it giving me this issue then
you can upgrade to the latest version of v13 or v14
oowh
for v13 it's v13.14.0
does it change anything in the general structure?
no
alright thanks bro
Hello, I need help I am creating a discord.js V14.5.0 discord bot and I wanted to create a button so I did but when I interact with the button it's giving me some strange error.
Interaction.create event code:
if (interaction.isButton()) {
// Handle the button click
if (interaction.customId === 'primary') {
// The 'example-button' was clicked
await interaction.reply('You clicked the button!');
}
}
/button code:
const row = new ActionRowBuilder()
.addComponents(
new ButtonBuilder()
.setCustomId('primary')
.setLabel('Click me!')
.setStyle(ButtonStyle.Primary),
);
await interaction.reply({ content: 'I think you should,', components: [row] });
The Error:
if (channel && !channel.isTextBased()) return;
^
TypeError: channel.isTextBased is not a function
at InteractionCreateAction.handle (C:\node_modules\discord.js\src\client\actions\InteractionCreate.js:46:33)
at module.exports [as INTERACTION_CREATE] (C:\node_modules\discord.js\src\client\websocket\handlers\INTERACTION_CREATE.js:4:36)
at WebSocketManager.handlePacket (C:\node_modules\discord.js\src\client\websocket\WebSocketManager.js:352:31)
at WebSocketShard.onPacket (C:\node_modules\discord.js\src\client\websocket\WebSocketShard.js:481:22)
at WebSocketShard.onMessage (C:\node_modules\discord.js\src\client\websocket\WebSocketShard.js:321:10)
at callListener (C:\node_modules\ws\lib\event-target.js:290:14)
at WebSocket.onMessage (C:\node_modules\ws\lib\event-target.js:209:9)
at WebSocket.emit (node:events:513:28)
at Receiver.receiverOnMessage (C:\node_modules\ws\lib\websocket.js:1184:20)
at Receiver.emit (node:events:513:28)
Please can someone help me đ
read what i literally said directly above this
oh ok thanks what a dummy đ¤Śââď¸
lol
Hello, I wanted to ask you another question I am creating a channel and setting the permissions on the channel.
code:
interaction.guild.channels.create({
name: 'quizchannel',
type: ChannelType.GuildText,
permissionOverwrites: [
{
id: interaction.guild.id,
deny: [PermissionsBitField.Flags.ViewChannel],
},
{
id: interaction.user.id,
allow: [PermissionsBitField.Flags.ViewChannel],
allow: [PermissionsBitField.Flags.ManageChannels],
},
{
id: clientID,
allow: [PermissionsBitField.Flags.ViewChannel],
allow: [PermissionsBitField.Flags.ManageChannels],
},
],
})
But the default view channel is denyed and that's working but the interaction.user.id is not so its really confusing.
Pics:
idk
try without ()
if anything, check docs
is the version exactly the same?
channel.isTextBased
that's an issue with discord.js itself
you need to upgrade to fix it as i said
but idk about your new issue everything looks fine
no i fixed that issue @hushed robin helped me
w me
Idk
Why not look at all of them and take small bits of inspiration from each? Itâs kinda boring if you just straight up âcopyâ another siteâs look
I know but often times âinspirationâ means a similar look and feel
You should look at sites for ideas but I wouldnât try to look at any one specific site to gather inspiration from
I would suggest looking over what aspects of their design each make them unique and interesting and create your own look that builds off of those aspects
These sites seem to be mostly minimalist, aim for minimalist if you like that style
Theyâre pleasing to look at without cluttering your vision with flashy things
None of them look the best because theyâre all slightly different styles
I think youâre missing the point that theyâre all good in their own way
You like the minimalist style, being concise, and having a simple yet visually appealing color scheme
Perhaps
Iâm not big into frontend so I canât speak for those types of things
Wut
So newbie here i created a verification bot in python that uses / commands but no / commands are showing someone said / commands can take upto 6 to 12 hrs and it need to be signed? I got understand why is it not working can someone tell me in simpler terms-?
- they don't take up to 6-12 hours to register, that was before (even before it was fast/closer to 20 minutes/1 hour) and now it's instant
- they don't need to be signed whatsoever, all you have to do is send a request to Discord with information regarding the slash command, which is most likely done by the library you're using
You most likely have something wrong in your code and can get help if you post your code, for example one slash command you've created and how you sync/post the commands
And how do i request to discord-?
As said, it's most likely done by the library you're using
Until you share code for us to help you, can't really do anything
There are no slash commands there
You're just listening to on_message events
See https://gist.github.com/AbstractUmbra/a9c188797ae194e592efe05fa129c57f on how to implement slash commands
discord.py 2.0+ slash command info and examples. GitHub Gist: instantly share code, notes, and snippets.
Well fk me thanks!
Examples mainly use cogs but shouldn't be too hard to just the same code without cog
https://pastecode.io/s/84o6oe4j
How about now-
Looks better, still need to sync the slash commands though
You mean like this
bot = commands.Bot(command_prefix="/", sync_commands=True)
No, like shown in the gist 
So uh kinda struggling with understanding and implementing the sync
Please help ;-;
There are sync command examples https://gist.github.com/AbstractUmbra/a9c188797ae194e592efe05fa129c57f#sync-command-example
What does group mean
hi i was sleeping
a set of subjects clumped together
Timeout for: 5167
Limit: 5
Methods: patch
Path: /channels/1046346065256906843/messages/1091627031990648933
Route: /channels/1046346065256906843/messages/:id
Global: false``` what's this ratelimit for?
Patch sounds like editing a message
Hey, okay so, Im trying to send a message in a channel in all the guilds my bot is in, Im able to fetch all the guilds using the guilds api, and the channels api, but how do i check if my bot has perms to send message in a channel
Pretty sure you already got told countless times 
Can't you just send a message and catch an error saying that the bot doesn't have permission to send messages on the channel?
Example here
Other example here, that's just the lazy way
no
Just catch the error when your message doesn't get sent lol
Also, why don't you use webhooks instead
thats not right lol
This is what they are for
so its basically creating a new channel and then posting messages there?
no
It's creating a webhook and posting to that webhook
but that webhook is uh connected to a channel it says?
Yes
You create a webhook in a channel, yes
basically a proxy
ic
That's the principle of what a webhook is
gotcha, thanks
mmmm, my use case here is different but i see how this can be useful
I don't design I just code
Because my designs never look the same as the code
And the code is much shittier
I design in my head and end up editing lots of things lots of times
ikr
tbh is sucks ass
that's why i'm also not a frontend dev 
no
mdx yes
i had it before
and not going back 
not as bad as this
I could get back to some monospaced font
The issue is that none looks good/smooth
Tried Source Code font or whatever it's named
Not cool
spam jetbrains mono
does anyone know sequelize well? I want to make it so a server can have many users & a user can have many servers, a server has a users field which should be all users that did something on that & a user has a servers field for the same
sequelize is based on sql databases, doing such a thing in sql/tabular data is not so simple, it will probably require a lot of duplication
what are the contents of the users inside server and servers inside user?
only the id, or something else?
a user has id, name, discriminator, avatar, authToken, refreshToken, accessToken
a server has id, name, icon
but like
user has servers and server has users/members right?
and inside that, its only ids?
or something else
I dont have anything yet, I dont know how it should be done
because if its only ids then you can create a table mapping one to the other
for example
// users
1, name, discriminator, avatar, authToken, refreshToken, accessToken
2, name, discriminator, avatar, authToken, refreshToken, accessToken
3, name, discriminator, avatar, authToken, refreshToken, accessToken
// servers
1, name, icon
2, name, icon
3, name, icon
// servermap
1, 1
2, 2
2, 3
3, 1
3, 2
3, 3
``` somethinglike that
in the server map both columns should be indexed but none should be unique
that way you can fast query stuff like "all servers in user id 1" and also "all users in server id 1"
the actual server id
i mean, you can use another auto incrementing id as the primary key
but thats only useful if you need to query stuff by creation/insertion date
or by insertion order
if you dont think you'll ever need that, you can make the id itself your primary key
hi ! sorry to disturb, idk if I'm at the right place, but I've got a problem with the kvote in the karuta server / game... can I ask some help to anyone ? thank you and have a nice day / evening â
Guys, i am from italy (where ChatGPT got banned) and i wanted to ask you a thing, if in italy ChatGPT got banned, also my APIkey got banned? Because i can't use my ask-gpt command on my bot
if u selfhosting , try free hosting in ukraine/europe
if they also banned the api endpoints, you'll have to use a proxy/vpn
also yeah, the ban should only affect you if you're running your bot from home or from an italian server
I am running my bot temporary on Replit, so i am not hosting my bot locally
I don't know where are Replit servers
But 100% not in Italy, haha
i can say u ukrain free host ( not adv )
Hi does someone know or can make a bot that can see how many twitch points a user has on twitch and show it in discord?
I would probably start by reading the twitch api documentation first
Yea I found that there is a way but I ain't the best programmer
oh god another tim
moehahaha
you'll probably need to hire someone to make it for you
not including hosting cost + maintenance
from what i can see on the Twitch API docs
theres no way to fetch a users channel points
what are you doubting
unless itâs undocumented it doesnt exist
doesnt say you can fetch a users channel points
and neither does the docs
not sure what your doubting
apparently that's covered in their ToS
did you find the non existent endpoint?
fuck you
at least I have the maturity to know when I'm mistaken
differently to your underdeveloped brain
didn't u block me btw?
^
i dont believe theres a way tbh i even saw a forum and another guy said theres no way
there IS a way, just not without breaking their ToS
also there is a way that'll get an estimate of how many points an user has (without breaking tos)
what there isn't is a precise and legal way
so it can be wrong which probably isnt ideal
but it is a way
figure it out
if (interaction.channel && interaction.channel.type === ChannelType.DM) {
return interaction.reply({embeds: [dmn], ephemeral: true});
}
Why not responding
Wouldn't it be better to just
if(interaction.channel.isDMBased())
?
Ohh
When sending the identify payload to Discord's gateway, is the intent required for user authentication?
Wondering if they handle that for users as well or just bots
the intent is included in the url
I think you do need to include it in the exchange payload tho
like, after you get the key
Key?
after the user presses "Authorize" in the oauth2 screen
it'll send u the key to exchange for the actual info
the token I mean
Isn't that access token just for the REST API?
Why not check the network inspector?
It has all the messages and payloads for the ws
Yeah it doesn't have there iirc, though it doesn't necessarily mean they don't handle it
Especially when the token sent is not the user token
yes, that's what I mean
for the oauth2 part you already specified the scope in the url
Yeah but gateway != rest
You could check it yourself
They might ignore the field entirely since it's not a bot token
What would be an optimal way to edit some HTML component, e.g. make it bold, given I get a WebSocket event related to one component based on its ID.
So for example all components are normal text at first, then I get a WebSocket event and want to put the component bold that the even said should be bold.
cc @earnest phoenix if you got some mastermind idea
Don't want to iterate because it's absolutely shit
u don't need to iterate if you set ids for them
u can also reduce the iteration scope if u put an id on the enclosing component so you can do a targeted iteration
So iterating can't really be removed or what
^
ids are O(1), no iteration involved
e.g. the websocket payload is
{
"id": "1337"
}
I'd need to update the component with ID 1337 only.
Given my components are not saved in an array or whatever, still need to find which one
Not HTML, component may have been a bad name
Like yes it's an HTML components but from a class
...?
Have a Something class
That has an ID
And need to edit data in that class
Which will then be reflected in HTML on its own
Bad practice to edit the HTML tag that has the ID of the class
mind to show an example of the structure?
like, of the component in question
It's just a class, don't have code available at the moment though
Just a basic class with ID and text
Will then be rendered in HTML with React magic
When editing text it reflects on HTML
Just an example, could very well be Angular
Don't want something limited to React
well, if it doesn't have an ID then there's no way to escape iterating
but most framework do allow setting ids

It's shit in what way?
Html iteration is pretty fast yeah
Even if you need to iterate over let's say 500 classes every 1-2 seconds
500 is nothing and 1s is an eternity
whats the chances of sqlite getting corrupted
đĽ˛
is there any free way to backup
my database is now passed discord file limits
aint no way he was ACTUALLY using that to backup data
that's like
a violation of user privacy
Please
on so many levels
no it's not
Wait idk
Are you trying to use sqllite to compile?
Idk why u even care in making a backup for something that's not generated by you
Ah wait, I know
this is unrelated to the compiling thing
..wha
Because you don't want to bomb steam api again
I was referring from his message history
it's not generated by me but i have a few million rows of data that i don't want to loose
I know but that doesn't even make remote sense đ
Lose
Loose is the opposite of tighten
Iâm questioning whether or not youâre using chat GPT to help with sql
They are
i was, it wasn't really working properly though
but what about how i can backup my db?
Because chat GPT isnât also good with sql
You generate a dump and tar.gz it
Well iteration is your only option, 500 is pretty much nothing, you might be doing something that slows it down drastically
what will this do
It'll generate a dump and make a tar.gz file
whats a tar.gz file
Research time
true
Short for Tape Archive, a TAR file is used to store multiple files in one to send over the internet or for archiving purposes. Similarly, the TAR GZ file extension is created when compressing archived TAR files with the GNU zip utility.
so does this mean i can send it on discord ?
so whats the point of it
Because simply copying the database will include the chance of fucking it
please take our words of advice that we are giving you in this channel. Chat GPT WILL NOT WORK. Idk how to get it to you that we are trying to help you and chat GPT isnât helping. Even I donât know SQL but that wonât stop me from asking for advice here if I need to. Back when I was new I used to believe that even I knew everything but I was humbled easily by devs who knew more than me. I know itâs hard but I know you can and are willing to understand eventually that what we are giving you is more important for you to use. We all started somewhere and learned to build from the ground up with advice from here.
Nah was just a guess that it would be slow/bad behavior, because like 500 every second feels sort of a lot 
Ok what language are you mainly using
me?
Yes
javascript
If js is your "much" I'm afraid of what's "little"
1 or 2 projects != "a lot"
just sayin
there's always a lot to learn
that's part of the development cycle
- start project
- work alot on it
- get depressed over something
- stop working on it
- repeat

Exactly
Not what I meant entirely but ok
average dev workflow
Stick to one project and continue with it
Preferably one you start yourself
this one i did myself
my amount of unfinished projects is 
yeah uh, nothing is EVER done
Stole?
Average dev
Letâs go back to sql and database
ok
I suggest googling how to do the database, there is a good explanation by w3schools
So what are you trying to do now
well
what i recently tried doing with sql is i want to add a trending command to my bot
where it'll basically compare the latest hours data with the second latest hours data, see which has the highest percentage increase, then order it in DESC order
which is really hard which is why i asked chat gpt
what chat gpt made returned data but it didn't look right
Like I said itâs easier to learn than chat GPT
25% of the basics
because the basics include create, update and delete
it's not
idek where to start
ik those too
Ok so if you do then you should know how to do those steps with a database
what you want to do is fairly simple
it is to me
i mean
i could probably do it with javascript but i think it would be more efficient to do it with sql
just do what i do and hire people to help with whatever you dont fully understand
Do it with JavaScript
hm
Thatâs what Iâm saying
but as i said wouldn't it be more efficient just doing it with sql
sql wont be efficient if you don't know how to write efficient queries anyway
Either way itâs efficient but I recommend using JavaScript
i know how to write queries
just not advance ones like this
only simple
well, the path of least resistance is your wallet
otherwise, a week or so learning how to compile it
This means that you don't have a C++ (CXX is C++) compiler installed on your system, and so CMake won't work with the operation you're telling it to do
how? i installed visual studio
and it took like 20gb from my memory
Visual studio has a selection of different ones to use
C+ and C++
love to code in C+
Shut
i have all these

battleless coding in C++? what dimension is this
he's just trying to compile a paid software that happens to have source open for compilation without license telling otherwise
atp let him
le-mao
What is in language packs
what
No. Language packs I think has the main programming languages in individual packs
I'm pretty sure it's what battleless said
lol
battleless is right about something? what age is this?
Oh wtf
Choose the "Desktop Development with C++" workload and install it, that's the only one you need
i already have that
Emberassing
it's checked
Did you install it?
yes
Checked != Installed
Install it again
how do i install it again
Did you click on the "Install" button after selecting the workload I mentioned?
yes
as i said i installed it quite a bit ago
i am currently reinstalling i will send the results here
What happens when you run cl on your terminal/console?
(Run cl.exe if you're in Command Prompt)
He went to general chat
yeah
i will do that when it's done reinstalling
my internet is a bit bad so it'll be like 10-15 minutes
Any progress?
both return
... is not recognized as an internal or external command, operable program or batch file.
On what terminal are you running it?
command prompt
You must run it inside Visual Studio, there's a program called "Developer Command Prompt from VS", you might want to run it in there and see it for yourself
Congrats
yup
it's now compiling
hopefully everything works đ¤
ayyyy w
now i don't have to pay
đ
i mean i don't mean any bad by that
Even paint when using the zoom
it's basically the difference between Dihydrogen Monoxide and Water
it's not
pixel is pixel
yes but because this is specifically made for pixel art it has tools to make it easier
and better
anyway just wanted to ask if they removed the ability to give ownership of servers to bots cuz the option is gone now
fair enough
probably?
why would you give a bot ownership of a server
cuz I own a couple that are dead but dont want to delete them incase they are needed in the future so i just give them to a bot and leave
have done it a couple times one fairly recently
but the option is gone now so i was curious why
well, it makes sense it's gone
don't think they want people giving bots ownership of a server
like?
and if it's gone there's nothing you can do about it
give 1 example
no
classic
why you always hating
i mean its fair enough but they let each bot own like 10 servers or something as a limit
but oh well
wonder what happend to all the servers owned by bots
maybe don't give a bot a server?
I'm just being realistic
makes no sense
no your just a hater
tell me a single feature that's "better than other painting tools"
pixels is as simple as it gets
can't improve much over something like that
heck people were doing pixelart ages ago, it was called cross-stitching
it just saves me having to make another alt i will forget the password for
...but you're the one claiming it has better features
maybe just stay in the server?
the burden of proof is on you
for pixel art, yes
say 1
I use Aseprite all the time and have GIMP installed on my computer, so I can answer this.
Aseprite has indexed colour palettes that make it easy to manage your colours.
Aseprite handles layers and the canvas very simplistically, while GIMP can be a bit awkward with that stuff.
Aseprite has animation tools built in, and allows for easy playback, loop sections and onion-skinning.
Aseprite has a "tiled" mode where you can work on a single tile and see how it tessellates with itself.
Aseprite is still growing, and new features just for pixel artists are being added all the time.
Those are a few reasons I can think of. Overall it's just tailored to pixel art a bit better.
there ya go
thats like 5
and most of the servers i have transfered had a custom bot i made for it and i hate being in alot of servers
so makes sence to juts gove the bot the server and leave
or just use folders
aseprite is more targeted to pixel art, gimp can do almost anything
i do but eh
1 - gimp has it (left panel, second/third tab)
2 - gimp improved layer functionality since that post was written
3 - gimp has it (filter -> animation -> playback)
4 - gimp has it
5 - that's generic as hell
The only thing that GIMP sucks at is being user-friendly, it's user interface is literally a hellish landscape, but once you know your way around it it's very nice
Krita solves GIMP's problem
krita is gimp but more drawing-oriented
gimp is more for image editing tbh
and inkscape excels at vector drawing
Krita also has very nice features for image editing as well, it's also nice that Intel became a gold corporate sponsor of it a few months ago
and ofc, all 3 fully free and have an ungodly amount of plugins
(free if you know how đ )
yeah i remember first using it in like 2015 and oh boy just that ui made me not use anything but ms paint for another 2 years
started using it more in about 2018 for random stuff and it became easyer to use as they reworked the ui but then like last year they moved everything around again and i have no idea where anything is anymore
i guess thats cuz if you are a gfx sweat you use hotkeys and crap so the ui isnt that bad then but eh idk
its probably worse for me cuz my screen is only 720p
not much room to work with, or thats just a cope idk
its still better
theres many more things not listed there
Feel free to add any more points
no
Until then, it has no advantage over regular drawing software
there's no L being taken
not showing you proof doesn't change anything
your free to have your opinion but i think otherwise tbh
Sure, just as it doesn't make that tool any different from other editors
Aside from UI
wrong again !
Prove it then
no
Smh
this guy should stop coding and go become a politician
that's the plan
I could mistake him for a flerfer
president of the united states đ
Or a moon denier
imma make trump proud tbh
Oh boy
next justin trudeau
Tf Flazepe
what's wrong
I mean the mods arenât watching
why does that matter
Just why I didn't comment on that lul
heheheha
I think Battleless should battle Elon musk
No wait that would make dumb and dumber for
elon musk is very smart
remember that guy
that demanded elon musk make him ceo of tesla
because "i am a super genius just like you so i deserve to be ceo"
fair enough tbh
ngl tho aseprite is the best
Calling yourself genius = super red flag for anyone in life 100%
AttributeError: 'Bot' object has no attribute 'slash_command'. Did you mean: 'add_command'?```
https://pastecode.io/s/ndm2sg0y
help ;w;
get rid of command_prefix in your constructor of your bot instance
You're starting your bot in prefixed mode
You can't have both in dpy? That sucks
So just ("/") or get rid of everything in the bracket?
Sorry newbie to discord bots
No
Remove it from your Bot instance, the command_prefix="/"
Like bot = discord.Bot()
Just remove the command prefix parameter, keep the intents one
bot = discord.Bot(command_prefix="/")
AttributeError: module 'discord' has no attribute 'Bot'```
You did the opposite of what I meant
Best is to check out the docs from discordpy about slash command usage and refer to that example
You said to remove it-
According to this, you removed the intents one
Not the one i was talking about
@pale vessel does dpy still not support slash commands or are the docs just really outdated? 
.... ....how does one remove it from the constructor
From
To
bot = commands.Bot(ntents=intents)
TypeError: BotBase.__init__() missing 1 required positional argument: 'command_prefix'```
To be honest, you should probably switch to a different library than discordpy, am really not finding anything on their docs about slash commands lol
Yes, check out https://libs.advaith.io/ for that
Compares Discord libraries and their support of new API features
Just try some python based ones out
They're called app_commands https://discordpy.readthedocs.io/en/latest/interactions/api.html?highlight=app_commands#command
So i should switch from @pallid tartancommands to @whole stratusp.commands?
bot.app_commands, I believe
Untrue
Just use hybrid commands
It will have slash commands by default, and have prefix commands if needed
Why do you have to argue with everything man
I dislike how discordpy doesn't have slash commands on their quickstart ngl, especially when slash commands are the way to go at the moment
Because it hasn't been updated in ages and they are working on a proper guide
What if i ditch slash command for a symbol
I was using slash to look cool
Cuz this is getting confusing :'>
The error persists
You can literally just create a slash command with
@app_commands.command(name="aaa")
async def aaa(self, interaction: discord.Interaction) -> None:
await interaction.response.send_message("bbb")
Which is documented
And if you don't use cogs and have a 3k lines bot.py file then you can use
@bot.tree.command(name="aaa")
async def aaa(interaction: discord.Interaction) -> None:
await interaction.response.send_message("bbb")
Its not working chief
Ill try this
use the one below
Its like 71 lines of code
But ok
Usually you'd use cogs for your command and not put them in your bot.py file
if you don't use cogs, use the one below
Can you implement it
Because either im putting it wrong or is it still not working
https://pastecord.com/wisisirypa.py
I changed your bot to use a custom class which replicates the normal commands.Bot class, the reason is so that when your bot is set up it will call the setup_hook function and automatically sync commands for your testing guild ID, which you need to replace from GUILD_ID to your actual testing guild ID. Feel free to remove the custom class if you want, you can copy the code of the setup_hook in a on_ready event if you wish, though that is not recommended, hence the custom class.
Everything else stayed the same besides some small changes with the @bot.tree.command decorator and the Interaction as parameter.
Also changed that it sends ephemeral messages instead of sending a DM to the user. ctx.author is pretty much interaction.user now
Also haven't tested more than sending the embed
@bot.tree.command(name="verify", description="Verify your account")
AttributeError: 'CustomBot' object has no attribute 'tree'```
đ
Wtf is up with my thing
How do you run your bot
Can you run
python3 -m pip show discord.py
in your cmd/terminal
Ok
Name: discord.py
Version: 2.2.2
Summary: A Python wrapper for the Discord API
Home-page: https://github.com/Rapptz/discord.py
Author: Rapptz
Author-email:
License: MIT
Location: /home/user/.local/lib/python3.10/site-packages
Requires: aiohttp
Required-by: discord, discord-ext-bot
Okay then just below the line
super().__init__(intents=intents, command_prefix=command_prefix)
add
self.tree = app_commands.CommandTree(self)
You'll also need the
from discord import app_commands
import
Okie!
That will add a bot variable that you can then access with bot.tree
You can use that for lots of things, can also make
self.version = "Bot version here"
and always access it with bot.version
Pretty convenient depending what you may do in the future
For example your verified_users variable, you could very well make it a bot variable in the future ^-^
ImportError: cannot import name 'AppCommandOptionType' from 'discord.enums' (/home/user/.local/lib/python3.10/site-packages/discord/enums.py)
Issue with my python?
like i will host this bot online definitely wont run on this loacl machine
Can you do
python3 -m pip list
Because you seem to have an old version of discord.py installed
Some 1.x version installed
2.2.2
Yeah which is pretty weird
and python is 3.10
so I want to make a function that can be either sync or async, now I need to add intellisense but for some reason it just displays Promise<...> | ..., why?
loadEnv<F, A extends boolean | undefined>(
/** The path to the Env file */ file: string,
/** Whether to load the file asynchronously */ loadAsync?: boolean
): A extends true ? Promise<Record<string, string>> : Record<string, string> {
// ...
}
Can you just try to uninstall discord.py and start the bot, you eventually have some legacy package installed somewhere
python3 -m pip uninstall discord.py
should do the trick
File "/home/user/Desktop/discord bot/bot.py", line 3, in <module>
from discord.ext import commands
ImportError: cannot import name 'commands' from 'discord.ext' (unknown location)```
if i host this on an online service will it guarantee to work?
Not necessarily
i mean it worked for you-
What is the output of python3 -m pip show list
Yeah, but just sending the message
2.2.2
even tho i uninstalled
and uninstalling it again says its not instlled
No the entire list
There should be the list of installed packages
you wanna see all the pip packages i installed?
Oh yeah my bad, it's
python3 -m pip list
sorry
Oh yeah then that yep 
python3 -m pip uninstall discord
python3 -m pip uninstall discord-ext-bot
python3 -m pip uninstall py-cord
discord is the old package name of discord.py so it's not needed
discord-ext-bot is some weird package
py-cord uses the same imports as discord.py so it will cause issues when importing
Then you can install discord.py again with
python3 -m pip install discord.py
You can also remove the
self.tree = app_commands.CommandTree(self)
line
And try to start again

this interaction failed why-?
i gave bot all permissions
Probably something wrong with the code that is handling button clicks
how would i debug---
In discord.py there's no button_click event
Can see how buttons work with the examples discord.py has, one is available at https://github.com/Rapptz/discord.py/blob/master/examples/views/confirm.py
if the return type is based on parameters, like the loadAsyncparam , its better to use overloads
oh boy, don't use json as a database
also, delete that url, quickly
you just leaked your token
and refresh it asap
Aw fuck time to generate new token
regarding your question, you're probably taking too long to answer the interaction
or actually, not responding at all
đ
since i pull the icons from the apiand i need to insert them in the site i did this
const getIcon = (iconName: IconName) => {
switch (iconName) {
case 'react':
return <FontAwesomeIcon icon={faReact} />;
case 'css3-alt':
return <FontAwesomeIcon icon={faCss3Alt} />;
case 'js-square':
return <FontAwesomeIcon icon={faJsSquare} />;
case 'html5':
return <FontAwesomeIcon icon={faHtml5} />;
case 'js':
return <FontAwesomeIcon icon={faJs} />;
case 'vuejs':
return <FontAwesomeIcon icon={faVuejs} />;
default:
return null;
}
}
does anyone have another idea?
in the map i do this:
<div className="flex justify-center">{getIcon(project.icon)}</div>
is it causing issues?
took me long enough to figure out this way cuz i was trying to just pull them from the api directly and insert them
which ofc leads to issues
you could format the iconName to be in the proper format
i was getting this btw:
Unhandled Runtime Error
Error: Objects are not valid as a React child (found: object with keys {prefix, iconName, icon}). If you meant to render a collection of children, use an array instead.```
wait no that's the previous one
yeah i was playing around with next api
they had a huge update lately
took me long enough to figure out the new way
first split by non-word (\W), make the first chars uppercase and then concat them with the prefix fa
alrightys i am gonna try that
make sure to add a fallback measure since it's possible that not every icon will follow that pattern
ok
i hate using nextjs api btw, i would really love ot use express. but i don't own a personal server atm
or maybe even better use rust
@radiant kraken is rest-api with rust a overkill?
//res.body.joined = timestamp
console.log(res.body.joined)
console.log(moment(res.body.joined).format('DD/MM/YYYY'))```
```js
1611624932
19/01/1970```
why is it giving me a wrong date?
joined is a UNIX (seconds) timestamp
moment uses millis timestamp
simply multiply the value by 1000
oh great, thank you
the same applies to every other discord timestamp, if u ever face that again
The name of the command is invalid
drop the account and you're set
https://discord.js.org/#/docs/discord.js/main/class/GuildMember
https://discord.js.org/#/docs/discord.js/main/class/User
to stick to the brain: member will always come from a guild or a guild event
member will always contain user, but not the opposite
anything that's local to guilds (nickname, roles, permissions, etc) will always come from member
yes

question of the day #1
whats your favorite language?
||English||



