#development
1 messages · Page 105 of 1
Display avatar URL will give the avatar URL of the guild as well
If the user has a guild avatar URL
Or not avatar at all and just a default avatar
I'd rather use the display avatar
Though to get your bot's avatar, just avatar url should be good
idk why, but this happens (music warning)
it only happens on that page
i can't show code cuz it's big :skul
whatever ur using doesn't have support for xml
that's the problem, what's that i'm using? LMAO
i checked here and there is nothing related to lib JIMP
pretty much, the url ur fetching is returning a XML file, which whatever ur using does not support
does other songs return xml too?
then it's returning an image inside a xml
try printing the received data if u know how to reproduce
actually i found what package is getting error
so, that package uses jimp
but i still confused on how it says that the image url returned xml
it might not even be a xml, just wrong mime
yes
maybe that
i'll handle errors
to avoid restart
idk
ok, I just found out what it was
an image url was returning an error, I just changed it.
Ty @lyric mountain
yw
about to start a c++ rabbit hole

First project will be rewriting an audio service I depend on into cpp
real
my condolences
Go learn Rust
I'm crying trying to learn how to install deps
like how the fuck can I not build uWebsocket
(I mean, I know why, because it tries to do rm which isn't valid on windows)
like this is not understandable at all
I'm tossing in the towel for today and gonna leave it to tomorrow me to figure out how to install dependencies cleanly
I'm very sure I'm doing something horribly wrong because it says it supports windows. I believe it, but like. what the fuuuuck why is this insanely complicated
I now have time to reflect on why I wanted to learn it in the first place and realized that I need an interpreted language in order to support a plugin system like I currently do and cpp wouldnt be able to work like how I have it at all
so I struggled for nothing

me trying to interact with windows kernel:
I'm assuming your bot just wasn't able to respond within 3 seconds of receiving the interaction
Also, account generation is something that will get you banned sooner or later
I don't know how that would help you
Reading the documentation, I'm sure there is an option in discord.py to defer interactions
It doesn't change anything, it's all in the documentation
It's even on reddit, just search for it
@lyric mountain what’s the best way of storing resources that I need for my game to run? Right now I’m using new File("path/to/image/image.jpg") but this is a bad idea since I wouldn’t have the source code folder inside of the final compiled jar
I saw something about .getResource() online but I don’t really understand how to use it or how I should be doing this
Perhaps I shouldn’t be storing my images folder within my source code directory and instead separate from it? I’ll eventually need to package them alongside a jar file though so not sure still
That's for what the resources folder is made for
Located under src/main next to the java folder
Then yes, you can use functions to get the resource
use the resources folder yes
to retrieve them u use getClass().getClassLoader().getResource("relative/to/root")
u can also use without getClassLoader(), but I like having it relative to root (without it'll be relative to class)
I can’t seem to get that to work (I’m in my test/java folder and I have a resources folder in test/resources
??
don't use test for that btw
I’ll have to debug more when I get home
Why not?
I’m using it as an isolated way of testing my engine
this is not nearly the same thing
minecraft wrappers have a whole framework around it
look at how I imported my sprites waffle, there I use the resources folder
might help u find out why yours isn't working
Alright I will in a couple hours
also, the structure is very important, make sure your folder sequence is correct
iirc it's src/main/java/resources
for test it's src/test/java/resources
ah
actually, no, I wrote it wrong lul
scr/main/resources was correct
can replace main with test
does anyone know why it sometimes returns nothin? this only happens when using zlib compression streams, on both I use an fs readstream, when not compressing I write each chunk & else I pipe it into compression and then write each chunk (js)
src/main/java/com/company/app/Main.java :)
@lyric mountain so I’ve looked at your example and tried the same thing, but getClass().getClassLoader().getResource("ship.jpg") returns null
The file name is correct and my folder structure is like
test
java
java files
resources
resource files
put the resources in main folder
see if it works
it's a guess cuz test is for unit tests, so I suppose it "borrows" the resources folder from the main path
Gg
Still no luck
Yup
com.waffle
I apologize for the quality, working at school rn but this is my structure
no no no
src/main - src/test
inside each you create the java/resources folders
and then inside java you create com.waffle
Agh
I’ll probably have to fix this file structure on a proper IDE when I get home
This is a mess on replit, basically impossible to do it
it is
src
├ main
│ ├ java
│ │ └ com.waffle
│ └ resources
└ test
├ java
│ └ com.waffle
└ resources
same structure sir
Src/main/java
you don't have a test folder because nobody unit tests a minecraft mod
most ides will create it since it's recommended to unit test
it's useful if your mod uses a lot of math
my tests are people using my stuff and reporting issues 
can someone help with the question i asked earlier?
No
☹️ 🫡
hey guys suppose we have 1100 as a binary number. we will then sign extend it with 001100
would the msb be 0 now?
instead on 1
so the msb would still be 1?
no idea, but the value doesn't change at all
cuz i need to know whether we have a carry flag for the alu
just how 099 is still 99 in decimal
but there it looks whether the msb has a carry out
Afaik
ah, so that's what "most significant" means
then yeah, it'll always be the first non-zero bit
or the last, in this case
since binary goes rtl
msb would be 8 (in decimal) I think
1 would be the first bit (1)
idk why msb would be relevant for flags, like, u just get the individual bit values
based on the msb we can check whether we have the carry out flag
if the msb has a carry out, it will have the carry flag. else it won't .
no idea what that means
didn't you get this at cs?
no, deepest we got was C
and they never talked abt bitflags, had to learn it on my own
You’re in a pretty deep area of CS
Generally speaking most programs don’t go this far down low level unless you specifically opt for it
chitty is basically wielding a shovel already
zeros do count for most significant bits
the ground is way up
as long as you have a fixed bit size
yeah cs in the netherlands doesn't mean coding apparently. Learned it the hard way
the number 255's most significant bit is 1 if its an 8 bit number, and 0 if its a 16 bit number for example
Carry flag is just if the, e.g., addition has an additional 1 at the beginning in fixed size registers
1001
+0111
-----
0000 CF=1
So you do have a MSB as being 0
The register will just contain 0000 while the CF will be set
owh we learned it differently. They told us that we have a carry if the msb has a carry out
Probably the same with different words
yeah indeed
A CF is already happening when doing 1+1 in the middle of an addition for example
It's just more important when it will lead to an 'overfloe' of the register size
So it sets the CF to 1 and stores the result without that additional 1 at the beginning of the result
yeah indeed, ah i see.
just the only thing throwing me off was detecting where the msb is located
because we could have 0011 for example.
Hey! Would it be possible to swap an sqlite database (easily) to a PlanetScale or another one (Online), so I can fix this hosting error and I can get arid of sqlite
would that 0 count as the msb, or would the left 1 be the msb?
sqlite is good af, why do you wanna get rid of it xd
I'm having hosting errors lol, and the other host that I dont have issues with doesn't support sqlite sadly
No idea honestly
Maybe 1 if CF=0 and 0 if CF=1?
anyway the only way to migrate between different databases is to run a script that reads all rows from the old one and inserts all rows in the new one
(By errors I self host at the moment and my WiFi keeps being weird due to storms, work on it ect..)
whahahahah alrighty, i will try to ask my teacher if i get to see him this week. Thanks for the help
if you're going from "sql -> sql" then it should be little effort to migrate the database
if you are, tho, going from "sql -> nosql" then it'll be a huge effort
sqlite is so basic that its types are supported by any sql db that follows the standards
I'm planning on keeping sql it will just be ran on PlanetScale site (which supports it)
Otherwise I'd say it's always 0 because you explicitly have 0011 and 0 being the left most bit
Probably makes more sense as it should be constant
idk what planestcale is, but can't u self host a db?
also, sqlite is file-based, why would it error from wifi issues?
Yes, but it won't work on the other site, I am hosting on, due to the current self hosting issue.
It not the database, its the fact i can't keep uptime due to internet, so there isn't a point so of thing

u should get a vps
Recommendations??
galaxygate, hetzner, contabo
google compute engine is free if you have a credit card
only ones I know that are cheap
I personaly use contabo, haven't had issues with it since they changed their infra
im on hetzner, cant complain
Would you know how to transfer the database data tho?
the only way is as i said, make a script that reads all rows and inserts them in the new db
sqlite doesnt have an online interface from which to extract data
so you cant import it directly
tyy
you need to read the file yourself
If you want you can generate SQL queries from existing data with IDEs like WebStorm etc.
Connect to the SQLite database file and then you can dump the data and schemas of your database in SQL queries which can be used with other databases
i wouldn't really recommend galaxygate as the customer service from what i experienced was mwuah
constantly getting flagged for suspicious activity when creating an account or buying a vps, long ticket times. They might have changed it already tho
a signed computation, if we have a number like: 1001 it would be -1 right and 0001 1?
and 8 would be 01000, whereas -8 would be 10111+1 = 11000
signed numbers must know the bit size in advance
1001 is -1 only if you know for sure its a 4 bit number
if its an 8 bit number, -1 would be 10000001
Depends what technique you use
Could also very well be 11111110
Sign magnitude vs 1's complement
you still need to know the bit size in advance no?
Also 2's complement but forgot how that one works
No because you just need to invert them
unless there is such a thing as a variable bit signed number
where the sign bit can be anywhere
Oh yeah remember the 2's complement now, it's just adding 1 to the result of the 1's complement
yeah indeed
the bit size would still be needed right
oowh no, because it just looks at the msb my bad
the msb basically is a dummy value in signed computations as it just tells us whether it's positive/negative right
yes
Dump it
pff fuck my live
thats why you need to know the bit size, to know what position the sign number actually is in
Sqlite database dumps will be in plain sql, which can be restored in any sql db
yeah, cuz we can talk about 1100 *which is negative 4, but if we don't specify what the bitstring size is, we could also for example have 01100
most* Any with some changes needed
ye
I'm afraid of the database that can't restore a plain sql dump
bro i had to create a whole cpu in digital
Well, SQLite data types are not the same as every SQL database
So SQLite queries may not work at all
and some sql queries are also different
That as well
Postgres is known to be different for example
With small changes you can then get your queries to work for the targeted database
With simple queries you may not need any changes
day 2 of c++
I want to die
CMake seems to be the only valid option for dep resolution
which is fine, but why is this such a struggle to setup and find up to date info
I've already installed so many other "solutions" that were "recommended"
u managed to find the compiler, which is already a good thing
c++ was reallyyy fun tho, especially the insertion sort, heap sort, selection sort and bubble sort
I was using another compiler already
without git dep support
these alghorithms were the best that have ever happened in my life.
those are concepts that exist in any lang
it's just that most people don't bother to implement their own sorting algos
idk why things are so non standard because cpp has had so much time to standardize something
see that door right on the end of the alley? the one written "WinAPI"?
ye, don't go near it
even trying to figure out good software to host a web service isn't black and white because people recommend one by MS which isn't being maintained anymore and I had to dig a lot deeper to find uWebSocket
which I used in js and was amazing
still decided to make my own server software tho
The next question becomes how do my users cleanly install this shit regardless of platform
do I just include whole ass repos in my repo so they can build it
that's not a door, that's a straight up deep dark pit that you can't see the bottom of
should I buy a 2nd monitor when I'm in uni for comp sci
is it worth it
c++ is platform-dependent
hmm not really needed i think? I did invest in a macbook tho, that retina screen is just to0 crispy
but so far, i've had numerous problems regarding coding on mac tho, so yeah also a downside
tbh I'm just going to throw linux on my first gaming laptop I got a while back and use that for on the go programming/notes in college
hm, mark java as sources folder
and resources as resources folder
but yeah, that's correct
alright, and if I wanted to use ship.jpg from my Player class, how would I do that?
oh fuck setting java as sources folder made my IDE go bananas
lmao
if u get resources from getClassLoader() it'll always be relative to root
regardless of where ur acessing it
that's why I prefer over relative paths
are u using intellij?
yeah
I think it's cus I changed the package names all around
else intellij will think u have 2 modules
it automatically did stuff like this, I'm changing it back around to see if it fixes
The imports are all fucked around because they're not in the right packages cus of this
hahahaha
after changing packages around
seems good
mark test as test
publish it as a header-only library, that way anyone can use it simply by including it
thats what most open source c++ libs try to do, if they are small enough
perfect, got the resources working now, thanks @lyric mountain 🙂
otherwise for big libs, they are usually compiled separately then statically linked
yw
I find it funny how oddly specific the settings are
anyone know how to get audio to overlap itself in java? I'm making an audio system right now and I can't for the life of me figure out how to allow a sound effect to play over itself: ```java
public class SoundEffect {
private InputStream inputStream;
private AudioInputStream audioStream;
private Clip audioClip;
private DataLine.Info info;
private long clipTime;
private boolean overlapClip;
public SoundEffect(String pathToResource) throws UnsupportedAudioFileException, IOException, LineUnavailableException {
inputStream = getClass().getClassLoader().getResourceAsStream(pathToResource);
audioStream = AudioSystem.getAudioInputStream(inputStream);
AudioFormat format = audioStream.getFormat();
info = new DataLine.Info(Clip.class, format);
audioClip = (Clip) AudioSystem.getLine(info);
audioClip.addLineListener(new SoundClipListener());
audioClip.open(audioStream);
}
public void start() {
if(overlapClip) {
// What can I do to play both clips at once here instead of restarting the currently playing clip?
} else if(!audioClip.isRunning()) {
audioClip.setMicrosecondPosition(0);
audioClip.start();
}
}
}
(Also this is meant for short-form sound effects, hence why it's being stored in-memory)
Well ya see, you just play them both at the same time

perhaps open multiple streams
btw, don't forget to close the streams when ur no longer using them
Yup, I’ve got a close method for that
how do i know the connection between the mongoDB and the client user?
how do i know the ram usage of the bot? how much is left? what is the total of the ram?
how do i know the cpu usage of the bot? how much is left? what is the total of the ram?
So, I'm sure there is a guide on the Internet on how to connect a bot with a MongoDB. Look for the right one for your language
As for the ram/cpu consumption, I personally use htop on VPS. I can see exactly how much ram and cpu my bots use
👀 client to db connections, or bot to db?
there should exist no "mongodb and the client user", all database transactions should be done by the bot
depends on your language
depends on your language
oh
nodejs
bot to db
js then, node is the framework
A Computer Science portal for geeks. It contains well written, well thought and well explained computer science and programming articles, quizzes and practice/competitive programming/company interview Questions.
oh
in that site u can find the other stuff
hey how do i reverse the 2 complement result?
the what
so spose we get 1001 as a result of a two complement computation
which is calculated by flipping all the bits and adding a 1 to it,
i thought about reflipping then -1 but it seems to be wrong af
so u want 0110?
no not really
i try to find the a positive number from a negative number
obtained by the two's complement
idk how to help with that
guys is there anything on the youtube api to get video events
what events
Ok, so I'm learning discord.jsV14 and this is the code snippet i have from the tutorial so far:
module.exports = {
name: "verify",
async execute(interaction) {
// Get the verification role
const role = await interaction.member.guild.roles.cache.find(
(role) => role.id === "999398259095240756"
);
// Add the role to the member
await interaction.member.roles.add(role);
// Create a button for the user to press
const verifyButton = new MessageButton()
.setCustomId("verify_button")
.setLabel("Verify")
.setStyle("SUCCESS");
// Create an action row to contain the button
const row = new MessageActionRow().addComponents(verifyButton);
// Send a message with the button to the user
await interaction.reply({
content: "Press the button to verify!",
components: [row],
ephemeral: true,
});
// Await a button interaction from the user
const filter = (i) =>
i.customId === "verify_button" && i.user.id === interaction.user.id;
const buttonInteraction = await interaction.channel.awaitMessageComponent({
filter,
time: 15000,
});
// If the user pressed the button, update the original message to show that they have been verified
if (buttonInteraction) {
await interaction.editReply({
content: "You have been verified!",
components: [],
});
} else {
await interaction.editReply({
content: "Verification timed out!",
components: [],
});
}
},
};
One question though, how the hell do I see the button 😅
The message is edited to "You have been verified!"?
Also, I'm not entirely sure if it's possible to edit a message that is "ephemeral" into a regular one
hmm, ill check thanks
Hmm how do I know if the user has voted for the bot?
#topgg-api question and read https://docs.top.gg
Can I know what language should I use to code a discord bot?
Preferably the one you are most familiar with
but what if Im starting new?
Then JavaScript is usually recommended. It's fairly simple for beginners and there are plenty of tutorials on the internet
Can I know the difference of javascript and node.js?
I keep seeing it appear along with python while researching this topic
JavaScript is the language and node.js is the framework for JavaScript
JavaScript is a programming language, used for making websites interactive and dynamic. It usually runs in the browser.
Node.js is like JavaScript's cool cousin. It lets you use JavaScript outside of the browser, like for running servers and building back-end stuff. (including dc bots)
So node.js is like an extended version of javascript?
Then is there any difference in terms of how the code works between javascript and node.js?
well, Google is very useful for that
ok Thx for the info
there is no difference in terms of pure javascript
but node.js does offer its own extra tools, just like browsers also have their own browser-only extra tools
Hi
I'm making a library for PHP to make it Object Oriented in an almost total way.
Here is an example of array and string handling with my idea:
$array = new NextArray();
$array->add('hola');
$array->add('uwuwuw');
$array->add('Fox');
echo $array(1); // OUTPUT: 'uwuwuw'
$array->set(1, 'Top.gg is awesome');
echo $array(1); // OUTPUT: 'Top.gg is awesome'
I have also implemented string management:
$string = new NextString();
$string->set('FoxWorn3365 is beautiful');
$array = $string->explode(' ');
$array->values(); // OUTPUT: [ [0] => "FoxWorn3365], [1] => "is", [2] => "beautiful"
echo $string; // OUTPUT: 'FoxWorn3365 is beautiful'
if ($string->contains('FoxWorn')) {
echo "{$string} contains 'FoxWorn'";
} else {
echo "{$string} is horrible!";
}
For the second case, here is how it should have been done without the oop library:
$string = 'FoxWorn3365 is beautiful';
$array = explode(' ', $string);
var_dump($array); // OUTPUT: [ [0] => "FoxWorn3365], [1] => "is", [2] => "beautiful"
echo $string; // OUTPUT: 'FoxWorn3365 is beautiful'
if (stripos($string, 'FoxWorn') !== false) {
echo "{$string} contains 'FoxWorn'";
} else {
echo "{$string} is horrible!";
}
What do you think?
Could it be useful or is it better to stay in the world of classical PHP?
Small spoiler: with this lib arrays are handled as objects so they require less memory
poor PHP
could be useful yes, but its hard to say people will actually use it
ik
people tend to prefer native way of doing things instead of a third party thing that basically does the same thing you can already do natively but with a different syntax
but then again, people also use lodash and shit they dont need for no reason
I had the opportunity to talk to people who were doing this:
composer require <LOTS OF LIBRARIES>
and after that they didn't even include the autoload.php
Google does
https://github.com/top-gg/php-sdk/pull/4
Still waiting for revisions 👀
Maybe, as mentioned before, someone who knows PHP could take a look at it and then gives an opinion
It isn't, that's correct
Why do you think it should be one
Do you even know what your constant DB is after you've assigned it that value?
const DB = { '735808489775038505': true }
Object.keys(DB).forEach((e) => console.log(e, DB[e]))```
you are working with an object here, you need to convert it to an array first
Object.keys turns DB into an array with its keys
Good thanks
just like always
instead of providing a string as message argument provide an object with the embeds key
just a tip btw, if ur going to get only the keys consider storing it as an array to begin with
{ "something": true } can be stored as ["something"]
that way u remove the middleman (Object.keys())
this should work like <array>.map(), right?
ugh, ; return
was about to say that
I have removed it already
xD
well yeah, it should but...why are u making a custom impl?
to have more customization about what the end user gets to do with the data
how would it be more customizable?
well I can add more and remove stuff
like in my case I dont want the user to modify data so I removed that part
wdym "modify data"?
you know, like in a map the .set function to change the contents
they can still do that tho
well if they really wanted to yes they could but it isnt made "easy"
its like a mix of an array and a map
const map = {}
map.map((k, v) => map[k] = 123)
so you're not directly extending Map, you're creating a separate class that has both array and map methods
yes
kiiiiiiiiiiiiiiiiiiiiiiiiiiiinda
possible yes
js can do anything
the question is if its the right tool for the job
the lag will be unbearable
Me... working on a code snipped to take over the world
u could try other langs
FakE out for another 6 months
anything can be made in any lang
it just happened that python is usually chosen for that
yes, you've discovered why AI is such a complex area
take over the world by driving a truck
you don't simply put "efficient" and "JS" in the same sentence
Why people always assume I'm doing that? 
because you're always driving something
lmao

you know what, why dont you do wardriving
best to take some courses on that area
I think I made the code look 10x worse
then maybe in what, a couple years you'll be able to write one
I'm already using my gsm, Bluetooth and wlan jammer to annoy people by parking close to their houses
xD
:P
neural networks
ofc not only that, but mostly
like, if u want to make an AI from zero don't expect to finish it anytime soon
training? you wont even run the project for a long period
training is the last of the last of the steps
why not just ```js
return Object.keys(this.data).filter(k => !excluded.includes(k)).map(callback);
oh
actually you want to execute .map on the values right, then .map(k => callback(this.data[k]))
this is it then, correct?
like, to put in perspective, the whole world, every country investing billions into AI research (for warfare ofc) was able to make chatgpt just now
training is the easy part, the hard part is developing a training method that actually works
it's virtually impossible for a single normal human to be able to develop an AI from zero during lifetime
it is, but still nowhere close of being a true AI
and it's been what, 50 years of AI research?
yes
if you want to expose the array parameter as an array of keys yes
might not be what people expect tho
what I mean is, it's a gargantuan task to even make a "simple" chatbot
I guess they would expect an object, right?
datasets are mostly useless outside their projects
it wasn't few years
AI research started loooooong ago
remember him?
there's also a little niche site called Google
it mostly uses machine learning to get relevant results
AI was among us for a long time already, they just weren't as talkable as chatgpt
all those little advancements led to what we have now
lmao
it wasn't a sudden jump
pretty much
like, u can make a retrieval-based chatbot, but it won't be a fluid as you might want
yes, but they're paid
ChatGPT was just way more public than the rest of AI/ML research
yeah, making an AI by yourself would be as easy as carving a CPU out of a silicon nugget with a chisel
brb gonna do that now
:^)
wanna bet it'll use tensorflow?
a masterclass that teaches you to use existing third party libs
jenious
using existing libraries, not actually from scratch using your own code
how to make chatgpt in 5 minutes
1 - grab chatgpt api token
2 - send requests to chatgpt
3 - show the user the answer and claim u made it
gn
I wanna build a 2.4GHz jammer to stop the music my roommate plays every day at 10 am
I'm just tired of always hearing the same 5 songs
Hey guys
hi
Why use a jammer when you can just be voltrex and bomb him
That way he won't know it's me
yah
that's actually kind of racist .-.
😐
👀
Polska?
Nie, pisz po angielsku bo to anglojęzyczny serwer
yes piss in english
lol
Can Anyone tell me what is the best location to host my discord bot with lowest ping? here's are the locations
The closest to where Discord is hosting their API
Which is, with some small thinking, pretty obvious
lol
united states of the americas
what site are you using by the way choose united states
I cant tell u
it is a host 🙂
tell me what will happen😀
shhhh they are under nda 

uhm is top.gg's background url broken?
it only allows this format
but the new format has a /a/ in the middle
the top.gg page doesn't allow that?
Are you sure about this it does say "Bot Hosting" on the dropdown
yes
🥰
can someone answer my question tho
i asked awhile ago
No
no
elon musk please
What is your question?
i will reply to it
Wdym by events
Have you tried reading the docs for youtube api?
Yes, But No 🙂
wym but no
think
https://developers.google.com/youtube/v3/guides/push_notifications this looks to be what you want
They will hack me
national defense !1!1!1!1!1
Its another revolutionary free bot host
doesnt want everyone to know about it
is there a javascript library for this
LMAO
looks complicated
💀
I use GalaxyGate. Please steal it from me 😮
omg!
Have you even tried googling for one
I just googled this shit I know nothing about it
So I cant say if there is or isnt a lib
if its too complicated dont do it
^
Would result in way less asking in this discord for help
You don't port forward for webhooks...
i don't?
I mean if its not shown to the public then sure ig
but a discord webhook would work fine
Depends the port you want to use
If you host that webhook on your laptop and expect google to reach it, won't work without PF
i was told it was bad to forward a port on my home internet
ok Miyuka no offence, but you are bringing this conversation backwards not forwards
videos
how
reading the docs
docs of what
And is one of those questions about posting a message when a YouTuber posts a new video or what
if it sends a webhook then that means it expects a webhook url
Fair nuf
first!!!!!!!
@river flicker
You said that the ?kanal-kilit command is not working, if I delete this command, will the bot be added to top gg?
There are 69420 bots doing that already, time to make it 69421
https://ifttt.com/search/query/youtube discord I've used ifttt for youtube -> discord webhooks b4, idk if its still the norm
DM the reviewer
ok and
It is
this ain't a public bot
but I doubt battleless would use IFTTT
this will be for me only
he hates complicated things but also seems to hate things that will make his life easier

what is ifttt
...and don't search on your own
this
I just linked it above
time to google this
I just invented it
well I provided what you need
Best would be IFTTAANDOYO
yeah but i don't want to forward a port
If this then ask and don't search on your own
IFTTD
not my fault its too complicated when it tells you exactly what to do
if this then delete
so this is a bad solution
a vps is your solution then
Assuming this works how it says then it is incredibly easy to do
Let me guess, you're engaging in your first conversation with this human being
Oh absolutely not. I lurk here all the time without speaking. I've seen the convos.
😐
Interesting 
does anyone know
😢😢
but me reading through the docs figured out how it works rather easily
chads make a request to the list of videos every second and if there's a new one then post it
twitter api is better

i know how it works
Then fucking do it

i don't want to forward a port i've said this multiple times
Then use a vps... oh wait testing would be annoying
yes i do

yes imma have to put the code on the vps every time just to test
wait wat testing is annoying on a vps lmao
I've answered your question after you continuously asked for an answer
it's literally the same as testing locally 
if you dont like my answer go find your own
You know how easy it is...
Use the goddamn remote coding feature IDEs offer jeez
yes i appreciate that but i wonder if there's another way
this is not ideal
I wonder if you can google it cause im not wasting anymore time
We say we use 10% of our brain only
ok you don't need to 🙌
Feel like people use 0.01%
https://github.com/pubsubhubbub/node-pubsubhubbub btw this is a lib for the pubsubhub
which I also found on the youtube docs
9 year old code slaps
ong
Var
idk how to use this
google it
no i'd just prefer to not have to deal with ports
with the twitter api i didn't have to
why with youtube ☹️
ngrok
Different companies...
ngrokdeez
dietz nutz

so why can't youtube implement twitters solution
it works well
Let me ask the ceo of youtube real quick
what is this
port tunneler
because people who use the youtube api using pubsubhub actually have the commitment to buy a vps or port forward
imagine using ngrok
ok but twitter api is better cus u don't need to do all that
cool
yeah
yk
ngl
imagine there being another good solution
oh yes, VPS! good idea
ngrok rocks
if someone has another solution pls let me know
vps

bro
you wont get a better one
ive been through this
But testing is annoying!1!1!1!1
so many times
something Aurel wishes he had
testing will be difficult
then run a vscode dev server on it
my brain is slowly becomming mush
test on the machine directly, ez
But I don't know!1!!1!11
i'm not taking 3 minutes every time i want to restart my app and test
you only commit to github like... when the code is fully completed.
wat
just directly connect to your vps with an ide
you could make your life so much easier by just googling how to do that
Refer to messages above
that seems like an unideal solution
Already suggested that
unideal?
Don't know their reply though 
Now you gotta be trolling
Impossibel!!1!!1!1!
literally, just
- get a vps
- run a vscode dev server on it, or just connect to it with ssh to have it setup itself
- profit
Man never trolled in his entire life
I definitely have
i like trolling in rust
So would you rather waste 3m to test something or connect directly to the project on your vps and code that way
literally develop on the machine you're gonna prod on

bro what
absolutely
how do u want me to develop on my vps
literally
it's weak
read my last messages
The same way everyone does
it has only command line
ok? still possible
Are you fucking dumb
no
Apparently so
lmao love how you guys actually keep trying
this literally allows you to code on your vps
At this point this guy should be blacklisted from the dev channel
^
literally, no dealing with portforwarding either
Voted
this is very bad
i have not broken any rules
i don't desverse a ban
I'd be able to unblock him because then I won't see messages either way
trying to help you is like teaching a brick wall to walk
what's the point in blocking me if your going to read my messages anyways
gonna list off your solutions here again
- get a vps, work on it using remote development
- portforward, which is not secure in itself
- ngrok to just tunnel
Also love how my 13 blocked people are from this server only 
well because you guys are turning me in the wrong direction
No we aren't....
Or just use ifttt
is another
or ifttt yes
unless you dont wanna depend on another service
then we're back on a vps
a vps then
because it's the wrong answer
then there's no way to do it yourself
are you sure he even has 3$ for a vps
☹️
yes
tell me
Its not the wrong fucking answer
what is your goal again
you are just the wrong fucking person to tell it to
i'm spending $14 a month on a do vps
"himself"
You would think, the people who are trying to help you, probably with beyond more development experience than you, is giving you the wrong answers.
describe your goal in a short, yet descriptive sentence
Can probably change the SO logo to be OpenAI logo
I need this
in reality all we ever do is copy stack overflow
thats 90% of development
nub
Aint no way fake and tim show up at the same time
the other 10 are documentation
My name jesf
this some voodoo shit
Uhh
Some dark voice told me to open Discord
hax
🏃♂️ i want to do something when someone uploads a youtube video
❌ i don't wanna do port forwarding or all this extra stuff
👬 i'm just looking for an alternative to what nicole sent bc of the above issue
✍️ this is descriptive enough?
depends the abbreviation
javascript efficient serialization format
has JavaScript in its name
my JESF
sucks
my name jesf
i want to do something when someone uploads a youtube video
referring to for example a webhook or what do you mean
Hey tim the joke is copywritten, I'll need 1000 robux
like, get events for when a video was uploaded?
^
im a pirate
D:
:^)
Nope you don't
i have no money
yes thats what he wants.
you took all my 40 cents
yeah
that was an answer already
"too complicated"
man aurel being a parrot 
there's no other way around it if you want to do it yourself, as that is what youtube supports
shush
IMPORTANT NOTE: The PubSubHubbub protocol has now been adopted by the W3C and published as a Recommendation. It's also been renamed WebSub for clarity and concision. Please consider upgrading all older PubSubHubbub implementations to WebSub.
ahem I mean
WebSub
xD
but yes
"WebSub" is what youtube uses, theres no other way around it if you wanna "do it yourself"
Anything is better than pubblubbsubbaubhub
youtube still calls it PubSubHub tim so blame youtube for the wrong name
mainly referring to the protocol itself tho, but probably
Shh logical connections aren't allowed here
ofc not
pubsubhubbub is a great name tho, why did they change it
stupid old dudes and their "professionalism"
deciding the future of js/web
smh
Dunno why but my dirty me is speaking it differently than it is written down giving it another meaning

yes
yeah nothing around WebSub as mentioned
see, that's what happens when someone answers their questions
battleless 9 times out of 10:
"how do you do X? nevermind i'll just do Y"
nah, bae just wrote cursed code and took 4x longer to understand what you're saying
battle takes NaNx longer to understand and refuses to show any code
@lyric mountain do you know how to compile something to a jar file? I’ve tried a few times but I keep getting cannot find class com.waffle.Main when I try to run it
IntelliJ > Build Artifacts
Via command line
(Also tried Intellij at home, couldn’t get it to work with creating a jar)
Wait I think I might’ve gotten it to work by a miracle
Damn it
I got it to work on replit, but when I downloaded it on to this PC I’m getting invalid or corrupt jarfile: path/to/jar/file
I ran jar cvmf MANIFEST.MF TestJar.jar -C build . -C PlayBrew/src/test/resources .
It works on replit when doing java -jar TestJar.jar but I get that error when I attempt to double click open it on a windows computer
ngl
someone explain this behaviour to me
isn't data() essentially the same, except without the data-
or are return values cached?
my god jquery

nestjs 
working with bootstrap to make a dashboard to test out stuff
cool, site isnt made/hosted with nodejs
but with python flask using gunicorn

becoming even worse
i havent used jquery since like 2012
real
cry
so does everyone else that is in a mentally sane state 
That's what happens if you double click a jar file that is not an executable
Ok so I think my problem is that replit is somehow corrupting the jarfile upon downloading it
What do you have in that manifest file
Main-Class: com.waffle.Main
It works just fine on replit running with the java command
Yes
So it will on Windows when using the cmd
An element's data-* attributes are retrieved the first time the data() method is invoked upon it, and then are no longer accessed or mutated (all values are stored internally by jQuery).
fair enough yeah
create an artifact yes
Something is going wrong with the download, when I try to view the jar’s contents with jar tf TestJar.jar (only getting problems on windows, using this command on replit’s side is working just fine) I’m getting invalid CEN header
wotheck
what kind of design idea is that
Unfortunately no, same thing happens with the command line
Since jQuery 1.4.3, data-* attributes are used to initialize jQuery data
it wasnt even supposed to be like this
Yeah then Replit doesn't like you downloading the file 
Maybe the encoding is different?
sense much
But even then it shouldn’t matter
so easy fix is, just use attr
Since they’re just bytes
the whole concept around .data() is to store data in jsland but associated with html somehow, only since 1.4.3 does it use data- attributes because they thought "why not" i guess
so basically, .attr is html, .data is not html, it just uses html by accident
So don't use data and remove it from your brain
Something is being majorly fucked
Using the data() method to update data does not affect attributes in the DOM. To set a data-* attribute value, use attr
This works perfectly fine on replit
What if you just open the JAR file
As an archive pretty much
With 7zip or whatever
Also in a hex editor - e.g. xxd
On windows:
Uh, I’ll try opening on notepad? Can’t really install programs on this school computer though unfortunately
Can you send over the JAR or also not possible?
Not sure if notepad has hex view, if it has yeah
Otherwise use PowerShell
Has a function Format-Hex iirc
Doing that gave me a very large output
I expected that




