#development

1 messages ยท Page 1875 of 1

urban slate
#

one sec

#

add what?

lyric mountain
#

my guess is that something held the bot hostage after the first help command or before the gif command

earnest phoenix
earnest phoenix
lyric mountain
#

"I ran"

earnest phoenix
#

I raq

lyric mountain
quartz kindle
#

i fgan

urban slate
earnest phoenix
urban slate
#

well here we goo

earnest phoenix
#

w r o n g

lyric mountain
urban slate
#

N O

lyric mountain
# urban slate

beware, contentfilter=high might be an issue give how big gifs can get

urban slate
#

really?

lyric mountain
#

other than that, I can't notice anything off

urban slate
#

its just for how nsfw the image is according to tenor api

lyric mountain
#

part because I'm pretty confused by the formatting choice

urban slate
#

also i did the i ran thingy

lyric mountain
#

ah, it isn't image size then

urban slate
#

everthing ran

lyric mountain
#

no prob

#

try sending many times that command until it doesn't work

urban slate
#

now the only thing i can imagine of is this https://www.youtube.com/watch?v=AaZ_RSt0KP8

Tiny particles from distant galaxies have caused plane accidents, election interference and game glitches. This video is sponsored by Brilliant. The first 200 people to sign up via https://brilliant.org/veritasium get 20% off a yearly subscription.

This video was inspired by the RadioLab Podcast "Bit Flip" https://ve42.co/BF -- they're brillian...

โ–ถ Play video
lyric mountain
#

maybe it's an specific subset of images that are causing deadlock

urban slate
#

it was slow but did respond

lyric mountain
#

10 is not enough

urban slate
#

how many u want

lyric mountain
#

we are talking about hundreds

urban slate
#

imma just copy paste the gif command over and over

lyric mountain
#

keep trying, random image generators sometimes return buggy images

urban slate
#

ight les go ctrl c + v

lyric mountain
#

just so you don't spam api, remove the message.send part

feral aspen
#

Hey all. ๐Ÿ‘‹

lyric mountain
#

all you need is to see if it'll faild during fetch

urban slate
#

well

lyric mountain
#

if the error ocurred on message.send it'd show a very specific error

urban slate
feral aspen
#

Is there a way I can store a password online but to access the password is a link that I can only access but a code too. (If this made sense)

urban slate
#

it did respond

#

and the console on has that it did send

lyric mountain
#

that?

feral aspen
#

Yes.

urban slate
#

ight i think radiation fuck my bot up....

feral aspen
#

(again, since I'm sharing the entire files publicly)

lyric mountain
#

you can hardcode for it to only accept requests coming from your ip

#

you can just use env files tho

#

then share everything but that file

feral aspen
#

I'm sharing a project but that project is accessible by everyone by downloading the files.. but the project itself using an app ID and app Key.

#

.. I want to store those online but get used in code.

#

.. since I don't want the users recreate an account for the key and so.

solemn latch
#

so like drm?

lyric mountain
#

definitely drm

urban slate
#

any other tests you guys would recommend?

lyric mountain
#

from now onwards, store a log of retrieved urls

#

let it happen again you'll have the required links to backstep it

urban slate
#

ohh

#

yeaa

#

thats smart

feral aspen
#

Is there a link I can follow?

solemn latch
#

for drm?

tulip ledge
#

whats drm if I may ask?

feral aspen
#

Not sure if that's what exactly relates to what I said.

urban slate
#

thanks guys

solemn latch
lyric mountain
#

ah, wait, I got it wrong

#

basically you want publicly (yet hidden) useable api keys and tokens

#

bad, baaaaad idea

feral aspen
#

I want to like store a password online readed by code using a URL whereas I can only visit and check the password while other IPs don't.. so if I share the URL with others.. they won't be able to check the password since the files of my project are all PUBLIC.

feral aspen
solemn latch
#

not possible to do safely

tulip ledge
feral aspen
#

@solemn latch

urban slate
#

no bro

#

how about u just get out of here

#

lol

tulip ledge
#

discorcl

feral aspen
#

Lol

#

l_ = L

urban slate
feral aspen
urban slate
#

api keys?

feral aspen
#

Yes.

#

Well.. I may explore this more tomorrow..

urban slate
#

hmm

tulip ledge
#

Like I said

feral aspen
#

Imma head out now.

tulip ledge
#

if u wanna do api keys

#

use jwt

#

you can use IP's to generate the keys if you want

#

but adding a login page would still be best

feral aspen
#

I'm using readline npm. ๐Ÿ˜‚

urban slate
#

u can just copy paste the whole bot and get different api keys for the copy and incase anything goes wrong your main thing is still there?

#

lol idk about this xD

#

i have never shared my code like that

feral aspen
tulip ledge
#

wdym?

feral aspen
tulip ledge
#

so readline is to read files?

feral aspen
#

To read command prompt inputs

tulip ledge
#

uhuh

#

what does this have to do with the api keys?

feral aspen
#

I made a project called Vocbabulary Search, allowing you to search for meaning of words, but the best one requires you to use an API key and the ID which you registered.

#

(for school)

#

Anyways.. I wanted to share them privately, but seeable by me only, but readable by code.

tulip ledge
#

wdym with "them"

feral aspen
tulip ledge
#

Also api key and ID sounds more like a login system to me

solemn latch
#

ideally your keys wouldn't be readable even by you.

tulip ledge
#

true

solemn latch
#

they are just keys, no need to access them

tulip ledge
#

Like I said if you want to make something with API keys you should use JWT

#

you can use it to "encrypt" data into a key

#

like for example the user id

#

then you can "decrypt" the key and get the userid

#

and based on that you can authorize them

#

the users will have to input the keys themselves tho

#

unless you make a login page and encrypt the key based on the username for example

feral aspen
#

Yup.

tulip ledge
#

then use that key to talk with a backend

feral aspen
#

I'll check more about it.

feral aspen
tulip ledge
#

well you don't want to publicly show the code right

feral aspen
#

The API Keys only.

#

I don't want to show those.

tulip ledge
#

you only want to show the api keys?

feral aspen
tulip ledge
#

huh?

#

Wait wait

#

so you want to show the api keys?

#

but not the program?

feral aspen
#

Share the code but not the API Keys.

#

Vice Versa means other way around.

feral aspen
tulip ledge
#

then how will access the code?

#

if they don't even know their own api key?

#

and you don't want to add login stuff

feral aspen
tulip ledge
#

then save it in a database

#

I suppose

feral aspen
#

I'll see.

urban slate
#

Ooo Ooo

brave garnet
#

?

urban slate
#

@lyric mountain i managed to get the same gif

brave garnet
#

ok

urban slate
#

and it did respond to it and the next query too

earnest phoenix
#

Is there more easy way

urban slate
#

interesting what cause the bot to stop ๐Ÿค”

tulip ledge
#

but I think recreating is a better way

knotty obsidian
#

is it allowed if i make a counter for myself which shows how much times my bots commands were issued

#

if this is a good place to ask

tulip ledge
earnest phoenix
lyric mountain
earnest phoenix
tulip ledge
#

yeah I haven't tried it

#

but I thought that might work

#

but recreating them is the best way

earnest phoenix
lyric mountain
tulip ledge
#

What I like to do is make a function/method called getButtons() and using the parameters to add options @earnest phoenix

lyric mountain
#

try to ask xiuh when s/he's free, maybe there's some important detail to reproduce it

earnest phoenix
#

Ill wait until discord api includes button.edit

tulip ledge
#

I dont think they will add something like that

solemn latch
#

yeah, probably wont be added

earnest phoenix
#

Why not

tulip ledge
#

because you can't edit buttons without editing a message

urban slate
earnest phoenix
#

Alr i want it with edit message

#

I am using button help menu

urban slate
earnest phoenix
#

for example when someone presses the settings category i want to disable it

tulip ledge
#

inside of the parameters

#

you can add like an array or an object or whatever which includes settings

solemn latch
#

do buttons even get their own id? 887044132269330000

lyric mountain
#

you define their ids

solemn latch
#

thought so

earnest phoenix
#

Yes

#

.setCustomId

tulip ledge
#

for example:

// Thi sis typescript tho
function getButtons(options): MessageActionRow {
  return new MessageActionRow().addComponents(
    new MessageButton()
    .setDisabled(options.disabled.includes("thisButton")
  )
}

buttons = getButtons({ disabled: ["thisButton"] })
brave garnet
#

talking ended?

earnest phoenix
#

I don't think it's worth the effort lol

tulip ledge
#

its also way cleaner

earnest phoenix
#

Alr my code is 130 line

tulip ledge
#

and teaches you functional programming which could be really useful in making your code more readable and understandable

earnest phoenix
#

I dont want to make it bigger

tulip ledge
#

then don't edit the buttons

novel jetty
#

When i delete a picture, my bot logs it as not found. How can i make it send the picture deleted?

import Discord from 'discord.js'
import { Command, CommandProps } from '../@types'
import { client, db } from '../index'
let e: CommandProps
export async function messageDelete(message: Discord.Message | Discord.PartialMessage) {
  let channel = await db.fetch(`modlog_${message.guild?.id}`)
        if (!channel) return;

        const deleteMessage = new Discord.MessageEmbed()
            .setTimestamp()
            // .setFooter(message.member?.user.username as string, `${message.member?.user.avatarURL}`)
            .setAuthor(`${message.author?.username}` as string)
            .setColor("RED")
            .setDescription(`**A message from <@${message.author}> was deleted in <#${message.channel}>**`)
            .addField("Content", message.content as string || "No content found... Either the message was a Sticker or a Picture")
            .setFooter(`ID: ${message.author?.id}`)

            var sChannel = message.guild?.channels.cache.get(channel) as Discord.TextBasedChannels
            if (!sChannel) return;
            sChannel.send({ embeds: [deleteMessage]})
}
earnest phoenix
#

If there is so something button.edit() i would use

tulip ledge
#

well there is not and there will probably never be

earnest phoenix
urban slate
#

Lol

urban slate
#

Ohh guys

#

Anyone here used tenor api?

#

Does it like stop working anytime randomly?

brave garnet
#

is here alr empty?
or no?
again only playing left for me...
i see that dev day is more for making them one day less, than helping...

lyric mountain
urban slate
#

Omg

brave garnet
solemn latch
#

or i guess do you want to add another field if a picture was deleted?

brave garnet
#

is it empty here?

#

โ”

solemn latch
#

its never empty

brave garnet
#

o ok. i go away. should i also delete previous messages?

novel jetty
#

I want it to log the picture which was deleted

rose warren
brave garnet
#

so delete all mine mesages from this channel? or no?

solemn latch
lyric mountain
novel jetty
solemn latch
#

where you want to add a field for deleting attachments/images

urban slate
rose warren
livid jackalBOT
urban slate
#

Thnx lol

tulip ledge
#

Brave

#

people actually use brave?

urban slate
#

Yes

tulip ledge
#

I always thought Brave was a meme

urban slate
#

Some of my friends do

solemn latch
#

brave still is spooky imo, most suspicious browser

urban slate
#

Firefox the best

#

Edge has improved a lot too

brave garnet
#

m$ edge is shit. and spies

urban slate
#

Spies?

brave garnet
#

becaue its from m$ every thing they do spies

#

similar to google but google is doing for free, so a one thing beter

tulip ledge
#

I mean it is because you consent to it lol

#

it's in the terms of service

urban slate
#

Lol

brave garnet
#

i know that edge is free. but 1/2 apps they made is paid and in this moment i just compared companies, not products

lyric mountain
#

ah it's you the dude who protests against ms

brave garnet
#

indeed. i use arch btw

urban slate
#

Lmfao

brave garnet
#

ยฏ-ยฏ

tulip ledge
brave garnet
#

gedit or nano

#

:|

tulip ledge
#

you use github?

brave garnet
#

nope, replit but as repo is opensoure i know that people have access to it]

tulip ledge
#

you really hate microsoft dont u

brave garnet
#

yep

tulip ledge
#

would you've switched to guilded if discord agreed to microsoft's offer?

brave garnet
#

if i could - i'd send there a nuke

urban slate
#

Isnt discord owned by ms? Or did they not sell

brave garnet
tulip ledge
#

discord denied the offer

lyric mountain
#

iirc you were making a bot that mimics bash cmds

brave garnet
#

yes, i was cause noone helps me and people from new api thrown me out of their discord

tulip ledge
#

wait but why

brave garnet
#

many things, nvm

#

talk to urself

#

i'll play some dumb games and go sleeping. everything i can do. bye

lyric mountain
tulip ledge
#

No, I meant why would you want to make a bot that mimics bash commands?

brave garnet
#

not ur business

lyric mountain
#

first discuss was about how flawed making a file downloader bot was, second (2 days after) is about how he's trying to fight microsoft by being the flag-holder for opensource movement

lyric mountain
tulip ledge
#

but what's the point

brave garnet
#

geez. stop

tulip ledge
#

of having a bot that mimics bash commands

lyric mountain
#

server management

#

like, mv to move stuff, cp to clone, rm to delete

brave garnet
#

im leaving. and im deleting bot from topgg cause i see i'll have problem cuase of it

tulip ledge
#

oh yeah

#

I get it

brave garnet
#

bye

lyric mountain
#

with the right implementation it'd be a cool bot

wheat mesa
#

Idk why this person feels personally attacked by every single message people send

lyric mountain
#

it's always like that

#

btw, weren't u a mod?

wheat mesa
#

I was trying to help earlier and they kept complaining

#

Who, me?

lyric mountain
#

ye

wheat mesa
#

Nah never been a mod

lyric mountain
#

I swear I've seen u in red robes

wheat mesa
#

Lol

solemn latch
wheat mesa
#

Ig

tulip ledge
#

You know what, I've been so burned out on my main project now I'm inspired to make a bot that uses bash commands

valid frigate
#

doesnt this surpass language barriers

wheat mesa
#

I feel like it does

tulip ledge
#

yeah same

brave garnet
#

๐Ÿคฎ

lyric mountain
#

or !/bin/bot

valid frigate
#

eventually you realize there are some people you cant help

tulip ledge
#

thats

#

an amazing name

valid frigate
#

LMAO

tulip ledge
#

but I don't make public bots anymore

#

it's just my own project

#

I create them for personal growth mainly

lyric mountain
#

make it opensource so you can get free jetbrains juice

tulip ledge
#

I will

wheat mesa
#

If youโ€™re in a school then you can also get free jetbrains juice

tulip ledge
#

I don't know whaty jetbrains juice is but sounds nice

#

btw anyone knows if you can still get a free .dev domain from github?

wheat mesa
#

JetBrains IDEs

lyric mountain
tulip ledge
#

oh

#

I prefer vsc

#

bro

#

this hack norris guy

wheat mesa
#

Trust me once you go JetBrains you never go back

tulip ledge
#

has said bye

#

like 10 times

brave garnet
#

lmao

tulip ledge
#

and is still here

lyric mountain
#

and now he's in a reaction tantrum

wheat mesa
#

Although VSC is lightweight

brave garnet
#

i go mods

wheat mesa
#

Compared to JetBrains ides

tulip ledge
#

I mean

#

can u call it lightweight

#

it uses chromium

lyric mountain
#

vsc is nice for quick edits

#

like, stuff you just need to change a bit

brave garnet
lyric mountain
#

jetbrains is the whole personal jet with built-in cinema and hot bathtub

wheat mesa
#

True

tulip ledge
#

is jetbrains rlly that good?

lyric mountain
#

oh you can bet it is

tulip ledge
#

but doesnt it cost money?

lyric mountain
#

ye

tulip ledge
#

ye

#

I'm 15 yo with no job and no allowence

#

so

lyric mountain
#

that's why I said to start an opensource project

wheat mesa
#

Do you go to school?

lyric mountain
#

so you can get jetbrains juice for free

tulip ledge
#

yes

wheat mesa
#

If you go to school, you can get it for free

#

Thatโ€™s what I did

rose warren
tulip ledge
#

even if I don't get programming in school?

wheat mesa
#

I donโ€™t think that matters

lyric mountain
#

you just need to be oficially an student

tulip ledge
#

mmmh

#

I'll look into it tomorrow

#

also

#

does github still do the .dev domains for students?

lyric mountain
#

do note, that you NEED to think about what you'll do after you end school

#

bcuz you don't keep it forever

tulip ledge
#

I already know

#

I'm going for master in computer science

lyric mountain
tulip ledge
#

yeah

#

Like

#

2 years ago or something

#

I tried to apply

#

but needed a school email

#

and asked my school and they said we would get one this year

lyric mountain
#

ic

brave garnet
#

geez. offtopic as fuck...

tulip ledge
#

This is in the student pack

#

for github

tulip ledge
#

this isn't offtopic

tulip ledge
brave garnet
tulip ledge
#

Look at all this shit

solemn latch
tulip ledge
brave garnet
#

but it wasnt a question? lmao

#

@drowsy crag knows bout it...

wicked pivot
#

possible to set the setTimestamp this way?

tulip ledge
#

Divide it by 1000

brave garnet
#

its built in. i dont think so

tulip ledge
#

discord requires a timestamp in seconds

#

@wicked pivot

brave garnet
#

indeed

#

=]

wicked pivot
solemn latch
brave garnet
#

idk

tulip ledge
#

setTimestamp doesn't take parameters

lyric mountain
tulip ledge
#

You also can't but it in the footer

lyric mountain
#

^ use footer for custom timestamps

brave garnet
#

+1

wicked pivot
#

okay okay thx

lyric mountain
#

do note before u try, you cant use markdown in footer

#

so no fancy unix timestamp parser

wicked pivot
#

ow ?

lyric mountain
#

you'll need to write ur own timestamp formatter

#

and output it as text

#

(that if u want relative time like in xxx days)

wicked pivot
#

setDescription and necessarily at the top of the message?

lyric mountain
#

else u can just use dateformat

wicked pivot
#

hm ok

#

well, it does not matter, I will do otherwise

#

Date.now() = date on ms ?

lyric mountain
#

looks too small, probably seconds

#

oh, nope

#

ms

#

it's just the font playing tricks

wicked pivot
#

how to switch in minute for unix timestamp ?

lyric mountain
#

ms / 1000 = sec
sec / 60 = min
min / 60 = hr
hr / 24 = day
day / 7 = week

#

so ms -> min would be ms / 60_000

boreal iron
#

Eww meth math

wicked pivot
lyric mountain
#

round it

#

btw, that's supposed to be seconds

#

so ms / 1000 only

boreal iron
#

Wonโ€™t work anyways as it takes Unix timestamps only

#

The message format

tulip ledge
lyric mountain
#

unix timestamp is just normal timestamp divided by 1000

wicked pivot
#

message.createAt ?

lyric mountain
tulip ledge
#

no I meant

#

it was your idea

lyric mountain
#

no prob

tulip ledge
#

do I have ur permission?

lyric mountain
#

my only beloved bot is shiro

boreal iron
#

I was referring to his actual number which wonโ€™t be a valid timestamp after rounding either, Mr Kuhabukawaga

tulip ledge
#

alright

lyric mountain
#

don't see myself making any other bot

boreal iron
#

Did you even read what I wrote lol

brave garnet
#

bye. i go sleep i think and/or play something. but im just going to go afk

lyric mountain
#

go on bro, have fun

lyric mountain
boreal iron
#

He still here not banned

#

God damn

lyric mountain
#

that earlier timestamp is messed up bcuz he converted to minutes

boreal iron
#

Yeah

lyric mountain
#

when he should've converted to seconds

boreal iron
#

You should told him the message format is doing the job for him after passing a timestamp

#

Shame on you

lyric mountain
boreal iron
#

Hax

cinder patio
#

how is this an offer

boreal iron
#

Used it, itโ€™s trash anyways

quartz kindle
#

thresh

boreal iron
#

Worse than notepad++

lyric mountain
#

you get: text editor
I get: analytics data, sellable coding habits and market info

boreal iron
#

lmao

cinder patio
#

I don't like how all of the offers are basically trials

opaque seal
#

there is some cool stuff

#

Jetbrains products ^

lyric mountain
#

some jet ides have both a community version and a paid version

sage bobcat
#

One message removed from a suspended account.

#

One message removed from a suspended account.

#

One message removed from a suspended account.

sage bobcat
#

One message removed from a suspended account.

lyric mountain
#

community version are fully unlocked, they just don't have some official features ultimate has

#

but it's not like there isn't a plugin available for that either

#

but it's totally worth it, it saves so much time and headache when coding

green sorrel
#

naruto start

lyric mountain
#

and given how user friendly jb is, you can't really not love them

green sorrel
#

n start

lyric mountain
#

like "oh you're not a company owner and can't afford our ides? that's fine, here take this all-in lifetime license and be happy coding"

eternal osprey
#

how do i automatically kick a user if he/she hasn't written anything in 30 days? (djs v12)

opaque seal
opaque seal
#

it's 100x compared to vscode

pale vessel
#

bruh...

lyric mountain
#

that's what I said

#

they have a shitton of support packs for non-commercial devs

#

even commercial ones get discounts

eternal osprey
#

how do i get the latest timesttamp of a users message

wheat mesa
#

JetBrains is honestly great

#

User friendly, has an educational and open source license, clean UI, etc

lyric mountain
#

too pog

lyric mountain
#

contantly fetching from discord is not really a good option

wheat mesa
#

And/or coworkers

opaque seal
wheat mesa
#

Vscode isnโ€™t an ide

#

Itโ€™s a text editor

#

With some syntax highlighting

#

And extensions

#

IntelliJ IDEs are fully fledged IDEs with tons of features

opaque seal
#

well with the extentions it can be considered an ide

#

itโ€™s basically what it is

#

itโ€™s not just a text editor

wheat mesa
#

I still wouldnโ€™t even consider using vscode for anything other than light web dev and ts/js imo

#

Maybe some scripting languages

#

But certainly not any of the C derivatives

opaque seal
wheat mesa
#

Both programs have their different use cases

opaque seal
#

well no jetbrains can be used for anything

#

vscode not really

lyric mountain
wheat mesa
#

Who doesnโ€™t?

wheat mesa
#

Something simple

drifting shell
#

do anyone know how to do bitwise ops on a grafana query

#

im trying to add a panel to figure how much ram is currently being used, but i can only get it in bytes and well....bytes is not exactly user friendly nor eye friendly

#

im using prometheus with grafana if that makes a difference

proven lantern
#

i love counting by 8s

silver remnant
#

can anyone help me out pls, i made a game and would like it to show up on discord when i am playing it. How do i do this?

solemn latch
#

its just rpc isnt it?

silver remnant
#

ya

lyric mountain
#

How is it currently? Hex?

drifting shell
#

just bytes

#

its reported by a dependency, i dont actually report it myself

#

i figured it out

#

i was just being rart

lyric mountain
#

Yeah but, how is it represented?

lyric mountain
earnest phoenix
#

when I go to add the bot, it says: this bot has been flagged by our anti-spam system for abusive behavior pending review and currently cannot be added to any additional servers.
what do i do? :/

lyric mountain
#

You've already been told to reach the devs

earnest phoenix
#

:/

lyric mountain
#

Top.gg has no control over individual bots

earnest phoenix
#
const { MessageEmbed } = require("discord.js");
const { client } = require('discord.js')

module.exports = {
  name: "hack",
  aliases: ["hacking"],
  description:("Vote"),
async    execute(message, args) {
    const hacked = message.mentions.users.first();
    const user = message.mentions.users.first();
    const answers = [`Hack of ${user ? hacked.username : hacked} is just completed\n_**The Totally Real And Dangerous Hack Is Done!**_`, `Hack of ${user ? hacked.username : hacked} is just completed\n_**The Totally Real And Dangerous Hack Is Done!**_\nTop Visit: For More Updates!`, `Hack of ${user ? hacked.username : hacked} is just completed\n_**The Totally Real And Dangerous Hack Is Done!**_`, `Hack of ${user ? hacked.username : hacked} is just completed\n_**The Totally Real And Dangerous Hack Is Done!**_`,];
    const words = [`duck`, `chicken`, `ok and?`, `never gonna give you up...`, `im gay`, `wtf`, `porn`, `lol`, `dank`];
    const ipaddress = [`127.0.0.1:890`, `167.1.0.1:800`, `229.6.3.1:190`];
   const dm = [`joe mama`, `@everyone Steam, Discord Steam Is Giving Out Free Nitro At: ***********`, `i just nuked a 400 member server!`, `how are you?`, `Vcodez.xyz is the best bot ever man!`, `Vcodez.xyz SUCKS! ITS SOOOOO BAD!`, `vote for trump today!`];
   const virus = [`meme_virus.exe`, `bonzy_buddy.exe`, `steal_emotes.exe`, `free_nitro_scam`, `your_time_has_come.exe`];
    if(user == client.users.cache.get(message.author.id))
    {
      return message.channel.send(" Ok, You are hacked Pick someone else")
    }
            function wait(ms){
            let start = new Date().getTime();
            let end = start;
            while(end < start + ms) {
              end = new Date().getTime();
           }
         }

if(!user)
{
  return message.reply("Who to hack? Please Mention him");
}
const prompt = await message.channel.send(`Hacking ${user ? hacked.username : hacked} now...`);
    
   await wait(2700);
     await  prompt.edit('[โ–˜] Finding Discord Login...');
     await wait(2700);
     await  prompt.edit(`[โ–˜] Discord Login Found:\n**Email**: \`${hacked.username}***@gmail.com\`\n**Password**: \`*1*9**h\``);
     await  wait(3700);
     await  prompt.edit('[โ–] Fetching dms');
     await  wait(3700);
     await  prompt.edit(`[โ–] Last Dm: \`${dm[Math.floor(Math.random() * answers.length)]}\``);
     await  wait(3700);
     await prompt.edit('[โ–—] Listing most common words...');
     await  wait(3700);
     await  prompt.edit(`[โ–—] Most common words are: \`${words[Math.floor(Math.random() * answers.length)]}\``);
     await  wait(2700);
     await  prompt.edit(`[โ––] Injecting virus into discriminator #${hacked.discriminator}`);
    await  wait(3700);
     await  prompt.edit(`[โ––] Virus Type \`${virus[Math.floor(Math.random() * answers.length)]}\` Injected!`);
     await  wait(3700);
    
   await prompt.edit('[โ–˜] Finding IP address');
    await wait(5000);
    await prompt.edit(`[โ–˜] IP address Found: ${ipaddress[Math.floor(Math.random() * answers.length)]}`);
    await wait(5000);
   await  prompt.edit('[โ–] Spamming email...');
   await wait(6700);
   await  prompt.edit('[โ–—] Selling data to facebook...');
  await   wait(3700);
  await  prompt.edit(`${answers[Math.floor(Math.random() * answers.length)]}`);
    

  }
};
solemn latch
#

if(user == client.users.cache.get(message.author.id))

#

youll want to use message.client, or get it in your function parameters.

earnest phoenix
#

thanks!

lyric mountain
#

yk stuff like .then exists right?

proven lantern
solemn latch
#

could even just do a interval, loop over it.

woeful pike
#
            function wait(ms){
            let start = new Date().getTime();
            let end = start;
            while(end < start + ms) {
              end = new Date().getTime();
           }

lmaoooooo

quartz kindle
#

lmao

woeful pike
#

this sleep function is the equivalent of hitting your computer with a baseball bat because it will most likely be waking up in a hospital

#

pls @earnest phoenix watch this talk or something ๐Ÿ˜ญ https://www.youtube.com/watch?v=8aGhZQkoFbQ

JavaScript programmers like to use words like, โ€œevent-loopโ€, โ€œnon-blockingโ€, โ€œcallbackโ€, โ€œasynchronousโ€, โ€œsingle-threadedโ€ and โ€œconcurrencyโ€.

We say things like โ€œdonโ€™t block the event loopโ€, โ€œmake sure your code runs at 60 frames-per-secondโ€, โ€œwell of course, it wonโ€™t work, that function is an asynchronous callback!โ€

If youโ€™re anything like me...

โ–ถ Play video
quartz kindle
#
function wait(ms) {
  const end = Date.now() + ms;
  while(Date.now() < end) {}
}
woeful pike
#

ok but watch the talk regardless

earnest phoenix
#

i will

boreal iron
#

this sleep function is the equivalent of hitting your computer with a baseball bat because it will most likely be waking up in a hospital

#

lmao

#

nailed it

rocky hearth
#

For react when I update a state with returning a new state I also updated a useRef array. With this useref Im trying to update the dom. But its not working.

#

But, y bcoz as the state changed it should rerender the whole dom with correct useref value too

lyric mountain
#

And u can do one action per .then

echo blaze
#

why isn't this writing to the file (server-count.txt)?

client.on("guildCreate", guild => {
    var logMSG = (`Server Count: ${serversIn}\nDate: ${moment().format('MMMM Do YYYY, h:mm:ss a')}\n`)
    console.log(logMSG)
    fs.writeFileSync(`server-count.txt`, logMSG);
})
proven lantern
lyric mountain
#

it wouldn't be 30 levels

#
await sendMessage("blabla")
  .then(() => sleep(3000))
  .then(() => sendMessage("hi"))
  .then(() => sleep(3800))
  .then(() => ...);
#

1 then per line, no more than 1 level per .then

proven lantern
#

That's better than nesting, but still worse than await

lyric mountain
#

Idk, then feels cleaner and can be handled by a single .catch

proven lantern
#

awaits have to use try/catch

#

that does add nesting

waxen bough
worthy ivy
#

is it a bad idea to start a collector in another collectors end event?

earnest phoenix
worthy ivy
#

that requires user input

#

so, collectors

earnest phoenix
#

Well you can yes

#

But be careful doing so

#

iirc it can cause memory leaks

worthy ivy
#

2 more

#

also how do you map an array into an array object

#

say i have an array of like 3 different things

#

["foo", "bar, "what"]

#

then i want them to be in a array object like this

#
[{
  "label": "foo",
  "desc": "foo"
},{
  "label": "bar",
  "desc": "bar",
}, //....
earnest phoenix
#

i want to keep image before invite musically can someone help how to keep

pale vessel
worthy ivy
#

ok thanks

short spruce
#

Why this is happening

earnest phoenix
#

@short spruce the endpoint url is not valid

short spruce
#

oh

earnest phoenix
short spruce
#

Btw can we coding bot with mobile?

earnest phoenix
short spruce
#

okay

#

I might need to buy pc

#

Ah

urban slate
#

i guess just god said no

#

at this point

earnest phoenix
#

Lol

urban slate
#

we have tried everything to replicate the error which didnt even console log

#

but didnt get it again

earnest phoenix
#

Whenever I have a command that makes me pull my hair out I just delete the file and start from scratch

urban slate
#

but it works for everyone everytime but didnt work specifically that time lol

urban slate
earnest phoenix
urban slate
#

hmm

earnest phoenix
#

Or...

#

A neon display supporting 256 total colors and a laser keyboard

urban slate
#

will node run on that lol

sick cloud
#

are there any reliable apis/gh sources for copypastas? trying to roughly detect them in chat and auto delete

earnest phoenix
urban slate
#

so like this?

#

so like this?

sick cloud
#

that's spam

earnest phoenix
#

Because the rpi is an actual computer

sick cloud
#

i mean like

urban slate
#

oh

earnest phoenix
#

Happens to me too

sick cloud
#

"watch out for this user!!"
or
"click for free nitro! <some link>"

urban slate
sick cloud
#

just a db or maybe a file someone maintains with those kind of msgs

earnest phoenix
#

well i can add a single space and break it

sick cloud
#

trying to then match words together and del if like above 90% match

urban slate
#

welll you can always make a bot whihc allows only certain links in the server

sick cloud
#

already got a func to do that

urban slate
#

dont think an api will have somethin like that

earnest phoenix
#

there's a reason auto mod bots suck
they cannot seperate innocent users from rule breakers and most of the time they don't work

sick cloud
#

api, some json file that's maintailed

#

anything like that

earnest phoenix
#

A human mod will be WAYYY better

urban slate
#

and about the words.....the more that i think about this project of yours it sounds just like my bot lol

sick cloud
#

there's a reason i don't use them, but i'm making one anyways

urban slate
#

my bot does the same stuff

sick cloud
#

mine's not for discord

urban slate
sick cloud
#

just asking here because it's the kind of thing a discord bot would do

earnest phoenix
#

Well

#

The next best thing would be machine learning

urban slate
earnest phoenix
#

Best idea

urban slate
#

but i dont got that much time for that

earnest phoenix
#

Because you can write the copypasta ล‚รฏkรซ thรฏs

sick cloud
#

if anybody wants to pull a db of those together though, i might start making one

earnest phoenix
#

i have a life

urban slate
#

lol

earnest phoenix
#

ask a dbl mod to do that

urban slate
#

oof

sick cloud
#

imagine having a life

rose warren
sick cloud
#

but yea, doubted there would be any ready to go resources around

#

sad, but it happens

urban slate
earnest phoenix
urban slate
#

ohh yeaa

#

that might work ig?

#

you will have to work on it though

sick cloud
#

i mean if i went to that length i'd be feeding it actual scam stuff though

#

and that gets complex

#

scammer dorks using embeds

earnest phoenix
#

At that point you should hire an actual mod

urban slate
#

i mean for what you want ml feels the go to or a human

#

ยฏ_(ใƒ„)_/ยฏ

sick cloud
#

and at the point of an actual human, well outside of bot use tbh

earnest phoenix
#

outside irl chat isn't moderated

#

you can throw a nokia at someone

sick cloud
#

lemme just put my nokia back in my draw

earnest phoenix
#

someone threw a nokia at ovh

urban slate
#

ovh is a hosting right?

earnest phoenix
#

yeah

#

their data center burned down in march

urban slate
#

ohhhh

sick cloud
#

f

earnest phoenix
#

this is why you don't use brick walls instead of nokia phones

rose warren
#

This is why they should have made backups lol

urban slate
#

yes

#

lol

rose warren
#

People literally lost their data in a fire

earnest phoenix
#

And cubedhosting's servers blew up

sick cloud
#

"hi, we host your server for the huge monthly fees you pay. last night our servers burned down so you lost everything. cool, have a good one"

short spruce
rose warren
#

Pretty much dog_Joy Which is why I started making daily local backups just in case

urban slate
#

wait so i dont know much about this so like if i had my bot hosted on their servers and they burned in fire would i lose my bot's code?

#

if i didnt back it up

rose warren
#

If the host hadn't made backups in a different location yeah

earnest phoenix
urban slate
rose warren
#

Bigger hosts usually have backups in other datacenters

urban slate
#

no wonder one of the minecraft servers i was part of literally had fuck ovh emojis and stuff

rose warren
#

So if one has a catastrophic failure you don't lose your data

#

But that was the problem with OVH. They either didn't have backups or backed up files in the same datacenter. So when it burnt down they lost those files.

#

They had backups in the same datacenter iirc

#

Kinda like putting all your eggs in one basket

earnest phoenix
#

all your eggs

rose warren
#

Yeah which is why you as a dev should always make local backups of everything too.

rose warren
#

Yeah all my bot files are on github and I do daily local db dumps

short spruce
#

how to start coding?

rose warren
short spruce
#

thakns

#

thankks

rose warren
#

Mhmm

royal portal
#

you dump your db cryangeryBOYE

rose warren
#

That's where it belongs

royal portal
dark warren
#

does anyone know the format for this? the link is clickable but the other parts of the text aren't. this is for your server description!

dark warren
#

hyperlink is text right?

#

but i wonder how they made the text big think_as

royal portal
#

you can change text size using css

rose warren
#

By big do you mean size or bold?

dark warren
#

the bold

royal portal
#

use <b>

rose warren
#

**[text](url)**

royal portal
rose warren
#

Mixing html and markdown is stinky

royal portal
#

never knew you could do that angeryBOYE

rose warren
#

same on discord

dark warren
#

so would it be like this? i wanted a big header so i used h2

<h2>vanity link!<h2>

#

im using the markdown guide to help me figure out heading sizes

cinder patio
#

Why not use html only?

#

Why mix them

dark warren
#

ohh i could use my vanity for both?

#

ill just use that then

cinder patio
#
<h2><b>Check out the <a href="link">support server</a></b></h2>
urban slate
#

your status

#

how did you do that?

#

teach me or guide me

#

howw do you actually get buttons on status bruh

rose warren
#

Google Discord RPC API.

urban slate
#

ightt thnx

#

oh its in beta

dark warren
rose warren
#

Paste your code here but put it inside ``` triple backticks

cinder patio
#

where does it take you?

dark warren
#

oh..

#

sorry

rose warren
#

Must use the triple backticks

#

Oh nvm

#

It's a server invite

dark warren
#

<h2><b>เฆ“ <a href="discord.gg">- discord.gg - #1 kpop mental health server </a></b></h2>

i removed the links

rose warren
#

Add https://

dark warren
#

invite i meant

#

ohh

rose warren
#

In the href property

dark warren
#

i previewed it and the link worked but for some reason i clicked saved and it never worked ๐Ÿ˜ญ it's still my same server desc

rose warren
#

Clear your cache

dark warren
#

aa there we go! it worked :D

#

now i just need to do the whole description again

#

my head hurts

dark warren
rose warren
#

Wrap them in <b></b>

#

You're using HTML so stick with that instead of mixing it with markdown or it'll get messy

dark warren
#

ahh alright got it!

#

for underlining texts what would be the format? i cant find it on the guide or im just blind

cinder patio
#

<u></u>

dark warren
#

tyy

earnest phoenix
#

better

rose warren
split hazel
#

hard coded password?

#

and for another layer you should also code a value of expected workers and once that limit reaches do not allow anymore connections

#

and sessions may be able to reauth with a special token?

#

there's lots of ways

#

but then you're moving the problem an extra step aren't you (assuming workers aren't in the same server)

#

maybe even 2fa

austere thicket
#

hello i would like help

#

before the new pinkish and white update to top.gg my iframe was correctly adjusted and the site was responsive but now this is happening

#

before it the update it was good

#

well anyone can help

#

and if ur wondering the height of the iframe here you go
<iframe src="https://jarvis-bot.netlify.app/" width="880" height="990px">

rose warren
#

That looks like a problem with your website not being responsive

austere thicket
rose warren
#

Open your website in a new tab and size it to 880 x 990px. It'll probably look the same.

austere thicket
novel snow
#

hey there

#

So like I have run into a issue, How would I be able to make a interactive scrolling thing, So like you have multiple pages to a embed and to scroll, Got the collector set up and the message itself, Then I realized, I need to loop the collector but I have no clue how that works,

#

So rihgt here is the collector when it collects things right?

How would I loop the collector back on a collect without making a massive chain?

#

A larger screenshot of the area;

spark flint
#

whats with the weird images lmao

#

fancy images

novel snow
#

How could I make this collector loop itself so I could keep it from just collecting it once? So it opens a new collector on it collecting input but without making it a massive loop

novel snow
spark flint
#

nope sorry

#

no clue what collectors are

novel snow
#

And here I was thinking I got a response to the code question I sent only for it to be a scam link sadAngry

spark flint
#

lmao

cinder patio
#

because of it the collector only collects one interaction and stops

novel snow
#

Yeah but I then also want it to reset the timer so it starts back at 45 seconds

opaque seal
#

it would be much easier to remove the max 1 and handle the timer yourself

#

@novel snow

novel snow
quartz kindle
#

dont use a collector

#

use the promise version instead

novel snow
#

Wait

#

There is one?

#

But what if the user abandons the message?

quartz kindle
#

awaitMessageComponents or something

novel snow
#

But what if the user like abandons the message?

#

Like he just forgets about it or some shite

quartz kindle
#

there is a timer on that too

novel snow
#

Since I want it within the command file itself to keep things organised

#

Hmmmmmm

#

How would that work?

quartz kindle
#

its much better for question-answer types of commands

#
const sent = await message.channel.send(...)
const answer = await sent.awaitMessageComponent(...)
if(!answer) { return await message.channel.send(...) }
const sent2 await message.channel.send(...)
const answer2 = await sent.awaitMessageComponent(...)
if(!answer2) { return await message.channel.send(...) }
console.log(answer, answer2)
#

something like that, i havent used it myself

bright thorn
#

i get something like this type of error

npm ERR! code 128
npm ERR! An unknown git error occurred
npm ERR! command git --no-replace-objects ls-remote ssh://git@github.com/distubejs/prism-media.git
npm ERR! command-line line 0: unsupported option "accept-new".
npm ERR! fatal: Could not read from remote repository.
npm ERR!
npm ERR! Please make sure you have the correct access rights
npm ERR! and the repository exists.

npm ERR! A complete log of this run can be found in:
npm ERR!     /root/.npm/_logs/2021-09-14T10_50_05_449Z-debug.log
root@ip-172-31-37-83:/home/ubuntu/real# npm i discord.js
npm ERR! code 128
npm ERR! An unknown git error occurred
npm ERR! command git --no-replace-objects ls-remote ssh://git@github.com/distubejs/prism-media.git
npm ERR! command-line line 0: unsupported option "accept-new".
npm ERR! fatal: Could not read from remote repository.
npm ERR!
npm ERR! Please make sure you have the correct access rights
npm ERR! and the repository exists.

npm ERR! A complete log of this run can be found in:
npm ERR!     /root/.npm/_logs/2021-09-14T10_50_26_042Z-debug.log
#

on npm install

novel snow
quartz kindle
#

its in the example

earnest phoenix
#

Is there an equivalent of that in detritus

pale vessel
#

no

earnest phoenix
#

well can i make it myself

storm night
#

hey! do you know the command I have to use to implement the f1 template on my server?? thanks!

storm night
#

ye

earnest phoenix
#

command for a server template?

#

can bots even create servers

lyric mountain
#

what even is f1

#

formula 1?

earnest phoenix
#

idk

storm night
#

Yes, I was looking and they have a template that can be used which is the one I would like but I don't know what command I have to use to implement it in my event.

#

for example

earnest phoenix
#

That's not even an official discord website

#

@scenic kelp looks like a dbl wrongserver

worn sonnet
#

Can someone answer this pls?

earnest phoenix
worn sonnet
#

Yep Ik but thought i'll share here too

scenic kelp
#

probably should have pinged for that but oh well

haughty tundra
#

does anyone use heroku here? particularly heroku postgres one

tidal nymph
lyric mountain
#

hard limit no, but you should refrain from keeping too many active at once

tidal nymph
#

do you know any solution for this?

lyric mountain
#

the way I recommend is creating a handler for reaction events and listening to reaction events

#

idk how to explain, but basically have a single listener which pass the event to a handler containing the actual actions

#

if you know java I can show u an example

tidal nymph
#

ahh I see what you mean, it works like reaction role right

lyric mountain
#

basically, but you won't use collectors at all

#

you store functions in a map and retrieve once a reaction event is fired

tidal nymph
#

aight I wasnt thinking deep enough lul but yea ig thats what im gonna use then

#

thanks โค๏ธ

lyric mountain
#

np

quartz kindle
#

dont use reactions tho

#

use buttons

#

its so much easier and you can store the pagination information inside the buttons themselves

tidal nymph
opaque seal
tidal nymph
#

oh okay, let me try it then, because I rmb it was broken when I tried it lol, thanks anyway

#

like it was fine on v12 but not v13 for me hehe xd guess its working now

atomic cairn
#

S

simple stump
#

I'm trying to insert something into a SQL database, however I get the error that gameid doesn't have a default value. I'm a bit confused, since I made gameid be a primary key.
Code:

let sql;
            sql = `INSERT INTO games (winnerid, loserid, winnerelo, loserelo) VALUES ('${id}', '${id2}', '${round1}', '${round2}')`;
            console.log("Inserting game...");
            const notSetEmbed = new Discord.MessageEmbed()
                .setColor('#10D365')
                .setTitle(winnerName + ' won against ' + loserName + ".")
                .addFields(
                    { name: 'Winner: ' + winnerName, value: 'ELO change: ' + p1 + " > " + round1 + ". +" + eloChange },
                    { name: 'Loser: ' + loserName, value: 'ELO change: ' + p2 + " > " + round2 + ". -" + negChange },
                )
                .setTimestamp()
            // Send the embd.
            message.guild.channels.cache.get("883834087125700659").send({ embeds: [notSetEmbed] });
            con.query(sql);

SQL:

CREATE TABLE `games` (
  `winnerid` varchar(255) NOT NULL,
  `loserid` varchar(255) NOT NULL,
  `winnerelo` int(255) NOT NULL,
  `loserelo` int(255) NOT NULL,
  `gameid` int(11) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;


ALTER TABLE `games`
  ADD PRIMARY KEY (`gameid`);
COMMIT;
lyric mountain
#

you're not assigning anything to gameid

#

winnerid, loserid, winnerelo, loserelo = 4 fields but you declared 5 not nulls without default values

#

also don't use varchar(255) on mysql

#

use varchar(191)

#

I'm a bit confused, since I made gameid be a primary key.
making it a primary key will only define a constraint to it, you still need to supply a value or use AUTO_INCREMENT

earnest phoenix
#

Is it possible to use serverless functions to recieve interactions?

lyric mountain
#

serverless?

earnest phoenix
#

yes

#

im just messing around im not tryna host an entire bot

haughty tundra
#

sorry for not providing details ahead

lyric mountain
#

are u manipulating the database through heroku?

brave garnet
#

today im not asking anything. dont ask me to ask. if something - currently watching memes, shitposts, checking socials and playing games ONLY. bye

#

and im also making backup of my bot page in topgg to be able to delete it after ban from here

wheat mesa
#

Quick question

#

Who asked mmLol

brave garnet
#

noone. im not here

solemn latch
#

https://i.woo.pics/71461da00b.webp
It seems some users are not realizing they need to click "Test" before clicking "Next".

Should I just highlight the test button, or make the next button a "Test and Next" button?

wheat mesa
#

Test and Next

#

Or maybe some popup like โ€œWarning: you have not tested yet. Continue?โ€

#

Seems like you already have something similar to that though

solemn latch
#

Id like to avoid people not testing here, as people will just fail to fill the webhook url properly and then get more confused 3 pages down when nothing works

wheat mesa
#

Yeah fair

#

I mean the thing you have now seems pretty self explanatory, you have to click โ€œTestโ€ before you can continue

#

Like that text says

solemn latch
#

Apparently its not enough still.
I might just leave everything exactly how it is(enable next too), but make the next button test on this page if they havent tested.
if the test fails just dont go to the next page and give the correct error

wheat mesa
#

Yeah

urban slate
#

i have a 300mbps connection but my bots ping is really high any fix for that?

solemn latch
#

where is it being hosted?

urban slate
#

its like 500

urban slate
solemn latch
#

like country?
discord text servers are all in the US iirc

urban slate
#

india

#

oh ok

solemn latch
#

well there you go

urban slate
#

got it

cosmic forum
#

Hello, I recently updated to Discord.js v13, however I keep getting the following error:

solemn latch
cosmic forum
#

let me check

#

v12.22.4

solemn latch
cosmic forum
#

ah ok

#

How would I change the discord.js version back to v12?

urban slate
cosmic forum
#

via services

urban slate
#

nah i cant be bothered for all that stuff, i have never done that

#

rn node . feels heaven

solemn latch
urban slate
#

just cause how simple it is

solemn latch
#

any vps can run node

urban slate
#

oo wait

cosmic forum
#

so ima have to stick with it sadly

solemn latch
#

others are on v13 djs on repl

urban slate
#

idk if it is vps

solemn latch
#

depends

urban slate
#

it runs like cpanel or something

#

i have no experience doing this lol

cosmic forum
solemn latch
#

@cosmic forum

cosmic forum
#

however

#

the problem persists

solemn latch
#

I dont know replit as I use a VPS, so cant really help with it. but many people have updated nodejs on replit

cosmic forum
#

ah

#

well i mean, do u know what could be causing the token error?

solemn latch
#

wrong nodejs version

cosmic forum
solemn latch
cosmic forum
#

ah ok

lyric mountain
#

to update node on replit u gotta use timhack

pale vessel
#

Handsome man

split hazel
#

flawless soul

quartz kindle
#

lmao

lyric mountain
haughty tundra
lyric mountain
#

why don't u just use cmd line?

#

or a database manager like pgadmin or datagrip

haughty tundra
#

im using heroku cli

quartz kindle
lyric mountain
haughty tundra
#

and then when i use heroku pg:push, it actually worked and stopped right after

lyric mountain
#

you can access it remotely

signal estuary
#

How can I sort an invite to a user? So like the invite tracker.

feral aspen
#

Hey. ๐Ÿ‘‹

#

For the help thing.. is it possible to recreate this with console.log.. but some type of console. option used for this?

signal estuary
earnest phoenix
#
Regarding your Presences request, while we're happy to provide access to our privileged gateway intents to power unique, compelling, user-facing functionality, we are not ready to provide access to that data solely for basic userinfo and serverinfo functionality, or bot statistics tracking.

If you end up building another feature that relies on the presence intent, simply reach out to us and we can review again at that time!

Which Feature needs Presences intent

#

Btw this message from discord

pale vessel
#

If you're asking what feature needs that intent then you most likely don't need it

earnest phoenix
#

I need it for get user info

#

And like client.user.username

#

But discord dont allow me to use it

pale vessel
#

Yeah

pale vessel
earnest phoenix
#

what can i add so that they let me

#

Actually needs

#

I cant use this code when this presencse off

earnest phoenix
feral aspen
#

This is something that is depending on your bot.

green kestrel
feral aspen
#

Telling them features that your bot doesn't have but included in your email is basically presence hunting.

earnest phoenix
#

But they want a command really need that intent