#๐งฉ-plugin-development
1 messages ยท Page 23 of 1
no
gotta mess with fonts or line break w/hidden overflow if you want to hide it or something
.timeStampInline > :first-child {}
should work
is there any way to change the text color of each channel so it matches with the emoji background?
for example, this to pink and the one above to slight greenish
jokes on you, devtools displays it funny, it's actually one element child
text nodes aren't considered as children in css anyway
it's actually just the content of the parent element
i think it does work now
why did it pick the heart when the flower is right there? silly discord
someone posted something earlier about a bar on the left hand side of a channel and i cant find it for the life of me
cute = ๐ i guess
the channel type thing?
yeah i decided to get rid of it
this?
yes
i decided that uh i no longer need this
search my name in this channel, there should be a text file with the css
Thom uwu made it to be a straight stripe and i changed it to little dots
actually here it is
didnt work fo rme
you need to enable the experiment
oh shit yeah
smh
.
yeah, I took 3 snippets and mashed them together to get just the lines
:P
still
/* In case you want to change the shape of channel indicators */
.iconContainer-21RCa3 {
width: 6px;
height: 6px;
margin-right: 10px !important;
margin-left: 8px !important;
margin: 0px;
border-radius: 100%;
}
/* Color for unread channels */
.unread-36eUEm {
background-color: #f3d56a; /* Change color here */
width: 6px;
height: 6px;
top: 12px;
margin-left: 10px !important;
margin: 0px;
border-radius: 100%;
}
ill restart hang on
this one
yeah no its not working fo rme
it takes a second to "find" the emojis but they won't show up so the lines will just appear after a bit
assuming you have the css and the experiments set to treatment 1
yeah, sometimes the lines will disappear because discord is being silly
but they come back after a bit
or if you stay on that server for a minute or two
#๐ง-discord-changes just refuses
I like it
might have to push the text inwards a little bit
a lot easier to read quickly since it's very obvious where one section starts and the other one ends
center for sure
center looks weird with emoji
but looks amazing without emoji
i keep a backup in vs code
it has a funny about message author but the stacktrace goes to discord code lmao tf
fetches fine regardless of that funky
(i just copied the fetch from msglinkembeds lol)
kinda real
i should finish third party plugin pr
or well i guess i did but this happens lol
ig i could use that for message notes too but fuckkk that plugin i am never finishing it
nightmare
I'm convinced this is never going to happen, it's a myth
mith
**fakeDeafen.ts: **
import { Devs } from "@utils/constants";
import definePlugin from "@utils/types";
import { Toasts } from "@webpack/common";
export default definePlugin({
name: "FakeDeafen",
description: "make ppl think u ae deafen!!!!!!!!!!",
authors: [Devs.Ven],
async start() {
activate();
},
stop() {
},
activate() {
console.log("you're gullible");
}
});
read what it says under activate
because discord sucks
why dont we add to the official cache
well we can still add to the original
wait what original
LMAO
i think just as a abackup, not sure
dunno where this decided to pop up
funky side effect
cause author works fine in notif as seen on the left 
djs
basicaly
Okay that goes pretty hard ngl
Square does go hard wow
Also feels more consistent with the rest of this theme I'm making, so I figured it'd end up looking a fair bit cleaner
I'm stuck with basic accent color change for now, Spotify vencord wave has ruined me
Ohh F
Yeah when I tried to add it, I just ended up with the wave above the player and couldn't even be bothered to troubleshoot it, so I'm sticking with a more simplistic one
I was afraid frosted glass and glow elements would be too taxing on my computer
Been thinking of trying to find a way to get a song's album cover's average colour and use that for the background in some way, but that project kinda got put aside lol
Fully understandable, blur filters, especially backdrop filter blur, can be uhhhh-
Probably have to use something more advanced than just css for that
bruh
Outdated meme format but still
I'm not gonna kill my integrated graphics
On my 1660 Super might I add, it's surprisingly capable for the price
On my ultra thin laptop (mistake)
I mean I'm running the theme on my school laptop just fine rn lol
Iris Xe having a hard time loading 2 discord clients at once
(After removing the backdrop blur over the background and just blurring it by itself instead)
Iris Xe holding up strong for me on this thing
Try devtool colors
So it's certainly possible to keep it well optimized enough
Wait wdym
Devtools has a thing where you can inspect certain color variables (elements using them will be highlighted in pink)
I ticked a few of those color checkboxes and heard the laptop fan screaming
Hovering over it does nothing for me, strange
In devtools, you click the >> symbol to select Colors
??
Don't see anything about colours in any of those that I see
how do i use this lol
You don't
ok my bad
but how do i install 3rd party stuff in general?
#1032200195582197831 pins
yeah i read it but it doesn't explain it
idk maybe im stupid
Read the docs
I will show you once I get home (in 5-6 hours)
e- alr
you mean this one?
https://github.com/Vendicated/Vencord/blob/main/docs/1_INSTALLING.md
**1_INSTALLING.md: **
> **Warning**
> These instructions are only for advanced users. If you're not a Developer, you should use our [graphical installer](https://github.com/Vendicated/VencordInstaller#usage) instead.
# Installation Guide
Welcome to Megu's Installation Guide! In this file, you will learn about how to download, install, and uninstall Vencord!
## Sections
- [Installation Guide](#installation-guide)
- [Sections](#sections)
- [Dependencies](#dependencies)
- [Installing Vencord](#installing-vencord)
- [Updating Vencord](#updating-vencord)
- [Uninstalling Vencord](#uninstalling-vencord)
## Dependencies
- Install Git from https://git-scm.com/download
- Install Node.JS LTS from here: https://nodejs.dev/en/
## Installing Vencord
Install `pnpm`:
> :exclamation: This next command may need to be run as admin/root depending on your system, and you may need to close and reopen your terminal for pnpm to be in your PATH.
```shell
npm i -g pnpm
... (69 lines left)
it doesn't have anything to do with the 3rd party plugins idk
the folder has 2 files
oh ty
can i use them without compiling?
no
@tight epoch this is what I meant
Oh that menu, I was thinking of the chromium dev tools menu 

Like what I did? 
And yeah, goes very hard
This little corner will be the death of me
I think .base-2jDfDU {}
will fix it
If you just remove the border-top-left-radius there
Which part of the css does that? ๐
The spacing?
After looking further into it, you might need to do this on .sidebar-1tnWFu as well-
Yeah
I want to switch over to the desktop version of vencord but the top bar of the app conflicts with my theme
So I thought this might fix that
These two rules should be what you need, not sure tho so feel free to make your own thing with it
/* Cozy spacing around everything in the app (basically turns everything into a floating window type thing over a background you can then figure out how to style, or you can see it as adding a border around the whole app, idunno. Anyway snippet by @DeadVoxels#3520 */
:root {
--spacing: 8px; /*put whatever you want in these, imo 8px works best tho */
--radius: 8px;
}
.bg-1QIAus, .app-2CXKsg, .appMount-2yBXZl {
background: none;
}
body {
/* Custom BG / border stuff goes here, you might have to do it another way tho idunno, I'm sure whoever uses this can figure that part out */
}
.base-2jDfDU {
margin: var(--spacing);
border-top-right-radius: var(--radius);
border-bottom-right-radius: var(--radius);
border-bottom-left-radius: 0px;
border-top-left-radius: 0px;
}
.container-1eFtFS {
margin: var(--spacing);
width: calc(100vw - calc(var(--spacing) * 2));
background: var(--background-tertiary-alt);
border-radius: calc(var(--radius) * 2);
}
.guilds-2JjMmN {
margin-top: var(--spacing);
margin-bottom: var(--spacing);
margin-left: var(--spacing);
margin-right: calc(var(--spacing)*-2);
background: var(--background-primary);
border-top-left-radius: var(--radius);
border-bottom-left-radius: var(--radius);
}
Well, three rules with the :root for var definition, but uh yeah
Thanks! Iโll try it out later
Np!
There just added guilds list stuff and things for the background/border because I forgor
ended up just adding a margin-top to fix, thanks any way though!
thank you deadvoxels for the help
i'm now changing all random color variables back to one standard
is there a way to edit the top bar of the vencord desktop app?
i can edit the name and color
but not to the style of frosted glass
for now it will stay like this
/* -- Custom Discord Bar name -- */
.wordmarkWindows-2dq6rw svg {
display: none;
}
.wordmarkWindows-2dq6rw::after {
content: 'Name'; /* Change the name here */
display: block;
position: relative;
margin-top: -2px;
width: 100%;
height: 16px;
line-height: 16px;
font-family: var(--font-header);
font-size: 14px;
font-weight: 600;
color: red; /* whatever color */
}
.wordmark-2u86JB {
width: 100%;
text-align: center;
}
do I need to root it?
it's just the default bar
reloading didn't work
fully restarted the client and still nothing
i remember only having that snippet for the name
wait is this for the discord app(with vencord) or the vencord app?
Finally I can remove that plugin
wha?
Raw Text
why finally
:OOOOOOOOOOOOOOOOOOOOOOOOO
Ooh nice
teach me ๐ฅบ
does anybody know how I could like add those notfis things on the app where it changes on the taskbar
here's an interesting question
how do i find the color string of a user who is not yet cached
or, better yet, how do i update every chat message component when i do have them cached
im gonna ask like 100 questions at once
so first this
then how do I give my discord a background
then how to I remove
this ugly piece of shit
then how this i fix this from overlapping
then how do I change the icons for when discord is loading up and for the application
done
react state + subscribe to member store
not possible to change that
last but not least how do I get rizz
only works in normal discord
Fuck
rip
what about for role edits
not on the member, like actually editing the roles
cause then i need to rerender every single message with that role
hmmm
at the moment getting the color is this
getColor(userId: string, { channelId, guildId }: { channelId?: string; guildId?: string; }) {
if (!(guildId ??= ChannelStore.getChannel(channelId!)?.guild_id)) return null;
return GuildMemberStore.getMember(guildId, userId)?.colorString ?? null;
},
it doesnt care about roles, just what the member's colorstring is
so i guess this is about to get a whole lot more complicated
https://x.lewisakura.moe/23/05/DiscordCanary_2023-05-13_13-03-52.png but hey, its a start at least
:root {
--background-primary: black !important;
{
my brain is poo
hol up
I mean like an image
I understand nothing with coding
like how they did it in anotheranimetheme
just yoink the code from the theme itself
time to go deep diving
channel name emo
channel name emo
great channel name
@The Commie Axolotl#0001
i love discord
@floral plaza
regarding ur widgets pr
it looks fine for me on firefox & firefox nightly
what ff version & system r u using?
I'm using 112.0.2 (64-bit) on MacOS 13.0
i checked and even without stylus/my userChrome styles it still displays like this
i need help
@client.command()
async def listen_for_cards(ctx):
def check(message):
return message.author.id == 646937666251915264 and "/card.webp" in message.content and ("is dropping 3 cards!" in message.content or "I'm dropping 3 cards since this server is currently active!" in message.content)
try:
message = await client.wait_for('message', check=check, timeout=3600.0)
await on_message(message)
except asyncio.TimeoutError:
pass
async def on_message(message):
# Check if the server already has a main "drops" role
if message.guild.id in drops_roles:
role_id = drops_roles[message.guild.id]
role = message.guild.get_role(role_id)
# Delete any duplicate "drops" roles
for r in message.guild.roles:
if r.name == "drops" and r.id != role_id:
await r.delete()
# If main "drops" role doesn't exist, create it and store its ID in drops_roles
else:
role = await message.guild.create_role(name="drops", reason="To be used for card drops pings.")
drops_roles[message.guild.id] = role.id
# Send message to the role
try:
drops_message = await message.channel.send(f"{role.mention} new cards have dropped!")
opt_in_message = await message.channel.send("React with  to opt-in or  to opt-out.")
await drops_message.delete(delay=15)
await opt_in_message.delete(delay=7)
await opt_in_message.add_reaction('')
await opt_in_message.add_reaction('')
# Wait for reactions
def check(reaction, user):
return user != client.user and reaction.message == opt_in_message and str(reaction.emoji) in ['', '']
while True:
try:
reaction, user = await client.wait_for('reaction_add', timeout=7, check=check)
except asyncio.TimeoutError:
break
if str(reaction.emoji) == '':
await user.add_roles(role)
opt_in_confirmation_message = await message.channel.send(f"{user.mention} you have opted in to receive card pings!")
await opt_in_confirmation_message.delete(delay=3)
elif str(reaction.emoji) == '':
await user.remove_roles(role)
opt_out_confirmation_message = await message.channel.send(f"{user.mention} you have opted out of card pings.")
await opt_out_confirmation_message.delete(delay=3)
except Exception as e:
print(f"An error occurred: {e}")
await message.channel.send("An error occurred while processing this message.") # notify user that an error occurred```
that's so weird
i wonder if that's somehow a macos thing?

use cogs :3
I think I have reading issues
I read this as "I like cogs" and didn't see a problem with it for a solid plenty of seconds
go to sleep
I was even like "haha, sounds like 'I like cocks'"
It's 1:41 PM and I woke up a couple of hours ago
but I will indeed go to sleep
h
is that from silly ah karuto or whatever bot
maybee
a
someone merege this alrready!
https://github.com/Vencord/Installer/pull/40
i'll take a look in a bit!
could you mark the review comments as resolved where applicable?
ok
got a question
how plugins are able to set "Listening to" status
and have dynamic title
but other rpc makers can only be set to "playing a game" and have a static title
Plugins are able to set Listening to status' because they are able to set it in the client itself, meanwhile rpc makers that rely on external apps have to use the rpc api
Which in turn have some limitations
^
External programs can only communicate with your discord instance, and the code listening to external rich presence only allows playing
o so it just skips the rpc api
and do the stuff directly
the plugin skips that one step and directly communicates with the discord gateway
so it can do other statuses
it's technically kinda risky because it's very obvious for everyone else you shouldn't be able to have such a presence, but at the same time u won't get banned for it 
what is
log.Fatal("Discord " + branch + " is not installed on your pc")
in fmt
is there not fmt.Fatal
ok thanks
that's a question xd
if there isn't, you can just ```go
fmt.Println("stuff")
os.Exit(1)
"undifined"
ok suggests are done. now, time to implent the "--dir" flag
ok. can someone help me test out the " -dir" flag of this https://github.com/Vencord/Installer/pull/40
did u test it urself?
From my past experience, vencord did not sit right with betterDiscord
working on cs50x again and for some reason I need to do form submissions in vanilla javascript
this is so horrible
manually queryselector-ing and preventing form events
how do i change the spacing for channels? it actually looks normal for other servers with a lot of channels like vencord but in some servers with a few channels the spacing looks weird. i tried to revert it using css but can't seem to manipulate / revert it properly. this is basically the code i've been tying to fix it with--
.channelName-3KPsGw {
padding: 4px;
}```
images for reference:
(1st pic: **weird spacing w/o many channels**)
(2nd pic: **normal spacing w/ many channels**)
and one more question, how do you make it so the channel highlights when you're in that specific channel? i know it's an original discord feature but it got removed when i started tweaking some things in css.
it now just shows the invite button for me instead of highlighting the whole channel i'm in:
that got messed up by the channel emojis update and since there is now nothing to indicate whether a channel is selected or not in the dom you cant fix it with css
since i disabled it, does that mean it's unfixable now?
you could just reenable it and hide the emojis with css
okay okay makes sense
oh that's why mine works then lol
thank you, works perfectly fine now
discord fucked up the text color, but you can circumvent it with some border and background instead
you are looking at changing these variables first:
:root{
--channels-default: some color;
--interactive-hover: some brighter color;
--interactive-active: some brighter color;
}
And for the selected channel:
/* Selected Channel */
#app-mount .containerDefault-YUSmu3.selected-2TbFuo .content-1gYQeQ {
background: some color;
border: 1px solid some brighter color;
}
thank you!
np!
wdym?
alright. the installer seems to work now. time to merge it
https://github.com/Vencord/Installer/pull/40
I joke, keep typing
@dull magnet hi, I encountered a problem that the script GifPaste won't let me select an animated avatar from the gif list
somehow even after full client restart it finds possible place to paste gif's url 
||I joined here only to get hilarious stickers, so please tell me if this notification is enough or ||shall I open an issue on the githab page?
thank you in advance for the answer 
there is already an opened issue for that
why do people unironically use the gif picker for picking avatars
I realized that with banners lol
nuh uh
nuh uh beocord
Mmmm square channel menu with emojis ๐คค
alright. the installer seems to work now. time to merge it
https://github.com/Vencord/Installer/pull/40
@dull magnet
How come yours looks different than mine
https://cdn.discordapp.com/attachments/1032770730703716362/1107811128895082516/Screenshot_2023-05-16-07-24-45-79_572064f74bd5f9fa804b05334aa4f912.jpg
because you are on mobile....
did you read this
Didn't get what it meant
then why not say that xD
Sorry
what i meant is that with that in place, it will never get to the lines below
in the lines below you have extra logic for dir
Wait why did I merge your suggestion in the first place?
I mean like if they did not pass any flags it would just supposed to go through the rest of the function
what?
the first block handles the dir != "" logic
and always returns or exits
the next 2 blocks are thus dead code you should remove
yes but im gonna play overwatch now
not for ven
fun fact its called bencord because ben owns it
omg bencord
Why is coding so hard ๐ญ when it doesn't work I do not know what's wrong and when it works I don't know how it's working
Update: ven slept at 5:30
isn't 6 the time to wake up ... 
Will this break my discord like last time ;-;
instead of downloading the theme im just gonna css it
gl to anybody whos gonna read the whole thing
nvm it broke again
for a moment I thought it would work
Hooray I did it
I figured out why its being
odd...
Truly a discord moment of all time

Stickers tab and status emoji picker tho, man I gotta get those fixed as well
@dull magnet github actions is completely insane
??? the one in production is the same
oh
it's complaining if I change order to what is is on production
okay whatever I fixed it somehow
my vscode was crazy
vsc does wonders
i love
my favorite
deafen
why is it over there
yeah i think some random snippet i found a while ago broke
Custom favs server icon because yes
Code for it is scuffed asf tho because it's like 4 different paths so afaik I can't replace the path d: on the original, so I just made it the background on the svg itself 
Still, I like how it looks and it works well enough soo-
:has is so cool
<body>
<section id="theme-switcher">
<h2>Theme</h2>
<label>
<input name="theme" type="radio" id="theme-light" checked>
Light
</label>
<label>
<input name="theme" type="radio" id="theme-dark">
Dark
</label>
<label>
<input name="theme" type="radio" id="theme-black">
Black
</label>
</section>
</body>
<style>
body:has(#theme-light:checked) {
background: white;
color: black;
}
body:has(#theme-dark:checked) {
background: grey;
color: white;
}
body:has(#theme-black:checked) {
background: black;
color: white;
}
</style>
0 js

Conditional and attribute selectors my beloved
Come to think of it In curious how much of a site's behaviour could be done with pure css
people have already been making insane stuff with inline styles
this is a zelda minigame where the only interactive element type used is a collapsible summary
everything is set in the style attribute, with a ton of calc's
https://cohost.org/Corncycle/post/362844-div-style-line-hei
coquest!
firefox and chrome only (desktop recommended)
Welcome to my post! Pretty neat, huh? Press A again to close signs!
This thing is so ridiculously hacked together! I'm surprised it's functional at all!
Everything in this post is raw HTML with inline css!
That means I can put anything I want in here! On this last screen I'm going to put ...
Geeez
amazing
css programminf ๐คฏ
func IsAdmin() bool {
// most sane windows code, copy pasted from https://github.com/golang/go/issues/28804#issuecomment-505326268
var sid *windows.SID
// Although this looks scary, it is directly copied from the
// official windows documentation. The Go API for this is a
// direct wrap around the official C++ API.
// See https://docs.microsoft.com/en-us/windows/desktop/api/securitybaseapi/nf-securitybaseapi-checktokenmembership
err := windows.AllocateAndInitializeSid(
&windows.SECURITY_NT_AUTHORITY,
2,
windows.SECURITY_BUILTIN_DOMAIN_RID,
windows.DOMAIN_ALIAS_RID_ADMINS,
0, 0, 0, 0, 0, 0,
&sid)
if err != nil {
fmt.Println("SID Error: ", err)
return false
}
defer windows.FreeSid(sid)
token := windows.Token(0)
isMember, err := token.IsMember(sid)
if err != nil {
fmt.Println("Token Membership Error: ", err)
return false
}
return token.IsElevated() || isMember
}
windows moment lmao
windoes
yeah :(
Done!
Hey at least they didn't use general
coding is even worse
but i banned them cause they also dmed me lol

probably just a troll
or 10 iq
bruh moment
Biggest brain move
I will message the server owner and beg for Nitro
I will beg for money
I will give you $10 and you'll give me Nitro 
coding or something
Else if
this code is honestly so cursed
I had to use a clone
nvm apparently that doesn't even work
I fucking hate
stuff like this is what stresses me out with Rust tbh
I don't get what the hell I'm supposed to do
i mean
the error is pretty self explanatory
you already have a mutable reference so you can't make another immutable reference
iter_mut() takes a mutable reference
also the iter_mut is obsolete iirc
I know what the problem is
for mut &npc in nps {}
I don't know how to fix it for what I'm trying to do
show code
it's this lol
where's the error
it didn't show for some reason, but uh
oh in clone
yeah but that feels so... cursed
why
if you clone in the loop you clone once per element
if you clone outside you only clone once
in any case
the reason I avoided it was because of the filter
why not just use an indexed loop?
wdym by that
that will solve all your issues
i in 0..npcs.len()?
yes
it gave the same error
now you're not holding a reference to npcs
so you don't have these issues
and don't have to clone
I recently tried that and it was doing the same thing
that means you're doing something wrong
it shouldn't
change it to indices and it should work
if you still get errors just show and i can help

for i in 0..npcs.len() {
let mut npc = &mut npcs[i];
if npc.biome_preferences.loves.contains(&biome) {
npc.buying_modifier *= 0.88;
npc.selling_modifier *= 1.14;
} else if npc.biome_preferences.likes.contains(&biome) {
npc.buying_modifier *= 0.94;
npc.selling_modifier *= 1.06;
} else if npc.biome_preferences.dislikes.contains(&biome) {
npc.buying_modifier *= 1.06;
npc.selling_modifier *= 0.94;
} else if npc.biome_preferences.hates.contains(&biome) {
npc.buying_modifier *= 1.12;
npc.selling_modifier *= 0.89;
}
for neighbor in npcs.iter().filter(|n| n.npc_type != npc.npc_type) {
if npc.neighbor_preferences.loves.contains(&neighbor.npc_type) {
npc.buying_modifier *= 0.88;
npc.selling_modifier *= 1.14;
} else if npc.neighbor_preferences.likes.contains(&neighbor.npc_type) {
npc.buying_modifier *= 0.94;
npc.selling_modifier *= 1.06;
} else if npc.neighbor_preferences.dislikes.contains(&neighbor.npc_type) {
npc.buying_modifier *= 1.06;
npc.selling_modifier *= 0.94;
} else if npc.neighbor_preferences.hates.contains(&neighbor.npc_type) {
npc.buying_modifier *= 1.12;
npc.selling_modifier *= 0.89;
}
}
that doesn't work
same error on .iter()
change the second loop to also an indexed loop
same thing
I don't have a choice
you do
I'm modifying npc
for each one?
- npc.buying_modifier *= 0.88;
+ npcs[i].buying_modifier *= 0.88;
what's the issue with that
Dunno, I would've thought it was an efficiency issue
do you know how array indexing works
it literally just adds the offset to an address and accesses it
arrays are just a chunk of memory that holds all items, to access the nth element of an array at address p you just need to *(p + n * itemSize)
obviously rust also has bound checks and stuff but the compiler can likely optimise those away
tldr dw it's extremely efficient
true
but I think it's good now
enum
does it implement copy
it does
#[derive(Copy, Clone, PartialEq)]
pub enum NPCType {
Guide,
Merchant,
Nurse,
Demolitionist,
DyeTrader,
Angler,
Zoologist,
Dryad,
Painter,
Golfer,
ArmsDealer,
Tavernkeep,
Stylist,
GoblinTinkerer,
WitchDoctor,
Clothier,
Mechanic,
PartyGirl,
Wizard,
TaxCollector,
Truffle,
Pirate,
Steampunker,
Cyborg,
SantaClaus,
Princess,
}
then you can change the second loop to ```rs
for u ... {
let type = npcs[u].npc_type;
if ...contains(&type)
i think it should work
u probably can't use type as variable name
this works cause it makes a copy of npc_type so it's not holding a reference to the element
as soon as you hold a reference to anything in the array and try to modify the array, rust gets pissy
which makes sense for memory safety but is hella annoying to deal with
you can say that again
this is why i don't like rust that much
memory safety is nice but a pain to work with
i like how go is memory safe but isn't super annoying about it
oh God, I have a new problem
ugh I don't even know how to describe this one
I have a HashMap of instances of NPC, and I want to create Towns of NPCs, but I need to clone them so that multiple towns don't have the same exact NPC...
Is there a way i can change locally user's display name with css having their ID? Or is it not possible with css?
yes
.avatar-2e8lTP[src*="343383572805058560"] ~ h3 span[class*="username-h_Y3Us"] {
visibility: hidden;
}
.avatar-2e8lTP[src*="343383572805058560"] ~ h3 span[class*="username-h_Y3Us"]:before {
visibility: visible;
position: absolute;
content: "meow";
}
vee has become meow
sorta
๐ฅด but hey, proves it's possible
thanks
Whatcha doing with the terraria npcs?
I'm working on a little town/pylon setup thingy
like the best combinations of NPCs to get the best sell/buy prices and stuff
Oo
When it's done i wanna use it
That's always something i wing
Generally just look up their likes and build a house in that biome
this was a version I wrote in Python some time ago
and it includes modded NPCs
but ๐ฅด
how's that? ๐ง
Idk digs up old memories of min-max overviews of percentages next to what I should buy next
ah
Id install js scripts using tamper monkey it was a great time
idk I like this kinda stuff though
at least when the language I'm using isn't being mean
Lol
Silver lining at least rust when it's mean tells you exactly why it's being mean
I'm probably going to have this program output to JSON so I can prettify the output with Python and Rich
the main reason I'm writing this in Rust is because Python was too slow
and the calculations became so complex that it'd take like days and days (if not exponentially longer) to calculate the best setups
something people often fail to account for is the fact that Terraria biomes can be mixed
I am gonna save this for sure
underground snow, for example, can lead to overall increase in happiness
It's true. I do not account for that
not to mention something silly like hallow underground snow
and when you add modded NPCs, the number of iterations once again increases exponentially
Ofc ofc
any1 wanna help me make aplugin that reverts all custom userprofiles? i hate how wide & colorful they are, i'd want to revert them to 300px width & all backgrounds to be default, maybe keep banners
i would do it with css but there are soo many edge cases & different variants, themed with banner, non-themed with banner, themed, etc etc & can break easily, i figure it might be easier to modify the component itself?
i don't really know any react tho
like i know svelte and i have done some contributions to react code like plugins here or other stuff elsewhere, but idk where i'd start to make this plugin
It would be much harder to modify the component itself
and patching discord is a very different side of react than normal react
react internals my behated
what the fuck
var elements = document.querySelectorAll("*");
for (var i = 0; i < elements.length; i++) {
var element = elements[i];
var elementName = element.tagName.toLowerCase();
var elementText = document.createTextNode(elementName);
var elementLabel = document.createElement("span");
elementLabel.style.background = "#000";
elementLabel.style.color = "#fff";
elementLabel.style.position = "relative";
elementLabel.style.zIndex = "9999";
elementLabel.style.padding = "2px 4px";
elementLabel.style.marginRight = "4px";
elementLabel.appendChild(elementText);
element.insertBefore(elementLabel, element.firstChild);
element.style.outline = "1px solid #" + (~~(Math.random() * 16777215)).toString(16);
}
do not use
var elements = document.querySelectorAll("*");
for (var i = 0; i < elements.length; i++) {
var element = elements[i];
element.addEventListener("mouseover", displayElementInfo);
element.addEventListener("click", displayElementInfo);
}
function displayElementInfo(event) {
event.stopPropagation();
var element = event.target;
var elementId = element.id;
var elementName = element.tagName.toLowerCase();
var elementText = document.createTextNode(elementId || elementName);
var elementLabel = document.createElement("span");
elementLabel.style.background = "#000";
elementLabel.style.color = "#fff";
elementLabel.style.position = "relative";
elementLabel.style.zIndex = "9999";
elementLabel.style.padding = "2px 4px";
elementLabel.style.marginRight = "4px";
elementLabel.appendChild(elementText);
element.insertBefore(elementLabel, element.firstChild);
element.style.outline = "1px solid #" + (~~(Math.random() * 16777215)).toString(16);
element.addEventListener("mouseleave", removeElementInfo);
element.addEventListener("blur", removeElementInfo);
}
function removeElementInfo(event) {
event.stopPropagation();
var element = event.target;
element.style.outline = "";
var elementLabel = element.querySelector("span");
if (elementLabel) {
elementLabel.remove();
}
}
this even worse
you can hover over the spans lol
for (const element of elements) {} > element = elements[i]
easy solution to being able to hover over the span is setting the style.pointerEvents attribute to none
aside from unnecessary type casting that's vscode being weird, that shouldn't be an error
what the-
TIL: don't enable this with the default value of 180 days because it's literally impossible to delete anything
yo
with css would it be possible to change all discord emojis to apples ones
i remember doing this like 2yrs ago on powercord some how
uh yes
how would i do so
why not
idk it worked fine when i used it a couple years ago
pre made
it mightve been a plugin idk
i doubt it matters tho right?
because the plugin would prollly just be importing some css or some shit
so can i just import this and it works
yes or paste to theme
it works
nvm it works thakns
how can i create my own plugin
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/label I was not ready for this cursed knowledge that javascript has goto
I can see that it helps with nested loops, but what else?
anything you'd use a goto for
let's you skip parts of the code early
which you normally wouldn't be able to do without extracting the logic into a different function or deeply nesting ifs
okay, I don't like goto but you have a point
here's an example https://github.com/vendicated/vencord/blob/main/src/plugins/fakeNitro.tsx#L638-L667
**fakeNitro.tsx: **Lines 638-667
stickerBypass: {
if (!settings.enableStickerBypass)
break stickerBypass;
const sticker = StickerStore.getStickerById(extra.stickers?.[0]!);
if (!sticker)
break stickerBypass;
if (sticker.available !== false && ((this.canUseStickers && this.hasPermissionToUseExternalStickers(channelId)) || (sticker as GuildSticker)?.guild_id === guildId))
break stickerBypass;
let link = this.getStickerLink(sticker.id);
if (sticker.format_type === 2) {
this.sendAnimatedSticker(link, sticker.id, channelId);
return { cancel: true };
} else {
if ("pack_id" in sticker) {
const packId = sticker.pack_id === "847199849233514549"
// Discord moved these stickers into a different pack at some point, but
// Distok still uses the old id
? "749043879713701898"
: sticker.pack_id;
link = `https://distok.top/stickers/${packId}/${sticker.id}.gif`;
}
extra.stickers!.length = 0;
messageObj.content += " " + link + `&name=${encodeURIComponent(sticker.name)}`;
}
}
previously this was done via deeply nested if statements
god we still haven't moved away from distok
@cedar olive didnt u wanna migrate it to assets
this actually helps a lot with understanding it, I can see why it's useful here
I guess I learned a new thing today
i think most js devs still consider using it this way to be poor style
i personally like it 
the more normal use case for labels are nested for loops where you need to break or continue the outer loop early from inside the inner loop
**webpack.ts: **Lines 282-292
outer:
for (const key in mod) {
const member = mod[key];
for (const newName in mappers) {
// if the current mapper matches this module
if (mappers[newName](member)) {
exports[newName] = member;
continue outer;
}
}
}
like here
yeah
I gave up though
I couldnt get it to work on windows
wait what?
oh do you mean the program
why? why do u even need it
aren't only very few broken
for transforming the lotties into gif
yes but i already did all of them
I was going to redo all since we are likely missing some

don't think so
discord didn't add any afaik
i can send u json mapping of all stickers in #assets if u want
sticker id to file id
can you check if there any missing?
and maybe try regenerating the broken ones
do u not have a linux vps or smth u could do this on anyway
cuz the program hates me

tbh compiling c++ on windows is painful
without visual studio
linux is way better for that
oh ye I got that working
it was another problem opening the program with bash
it kept saying there was no file with the program name
(in the right directory)
I have to input my address ๐ญ
(I dont actually have much problem with it lmao)
look at how other plugins do it
how can i access settings before i save them
i want to do something with that are in input form settings before i save them for example log them in console after i click button
plugin settings
have you figured how to access settings at first?
yes
then just do it before you update them lol
uhh i dont know how to describe it more
so
i have two inputs in my plugin settings
and
1 button
that would console log content of that inputs
but i dont know how to access that settings before i save them
im trying onChange but it doesnt seem to work
i dont know why onchange doesnt work
how hard is porting something from better discord to vencord
we kinda wanna port over a plugin but we're not too good at coding
just know python and gdscript but if its not tooooo hard we could learn
vencord uses typescript
what plugin
it depends a lot on the plugin
unrelated but it's kinda funny that a plugin adding accessibility related stuff has such a terribly accessible README

should i use settings or options?
is there difference?
as I said it's deprecated
It's going to be removed in the future
settings are way more powerful
i would use them but i cant find any example
identical api but settings are strongly typed and better
in any case, porting this would be non trivial. if you don't know js you should probably just request it as you will likely not get very far
there are a lot of plugins using settings?
a lot of the code in there is also fairly messy so it should optimally be rewritten instead of ported "verbatim"
its definePluginSettings?
yeahhh
i see, I'll ask them about it
ya
them? the author?
(talking about the image headers with no alt text)
yeah
its a bit strange
wdk if they're gonna port it tho tbh cause like
i dont think they've even updated it in a long time
we'd make our own version but that is way beyond our abilities
making a discord bot, would using python be best? as that's the only language I'm inherently familiar with
if not, which would you suggest?
If thatโs the language you know best, use that
discord.py has a ton of users and examples and stuff, so youโre in good company if you go with that
alright thank you
might be worth using it as an opportunity to learn a new language
but if you're not interested in that then just use python
it doesn't matter at all what language u use, just use whatever you're most comfy with 
but using a scripting language has some benefits such as hot reload and eval
which?
but don't let that deter u from using other languages

there are great libraries for all sorts of languages
many people write their bots in c# or java/kotlin
i personally always either use typescript or go
yeah I was thinking that
i've not written in anything other than rust in recent memory personally
maybe a bit of JS/TS for some frontend stuff
my condolences
the brain damage has clearly already set in
He's brain-damaged in more ways than that.
nuhuh
malbolge is the best language of all time
incorrect because english exists
english is known to be not one of the best languages
nuhuh
yuhuh
truly one of the languages
one of the languages ever
what the fuck
i knew malbodge was bad but that looks more like when a cat walks on a keyboard
yeah that language is kinda fucked
bad linux
mac strategy:
- take linux
- make it worse
- sell it as apple product
- profit in unreasonable amounts
and they dont on linux?
depends
nuhuh they actually took bsd
Because the attempts of newbies trying to react patch had resulted in awful stuff, it's also to avoid react crashes because most people are even confused which button to click in our 3-step installer
We are thinking of adding apis that use react patching internally
react patching is kinda confusing at start
cant blame
also when component rerenders does the element you inserted stay there
if you use an observer, yes
if you have dozens of plugins that all use their own observer
doesn't performance go to shit
how does even observer work
Dom mutation observers
considering devilbro has 3 trillion plugins it doesnt matter ig 
they watch the dom and call your callback every time some element changes
hmm
nice
yeah but you cant get every developer to understand webpcak,webpack search,exports
patchs blabla
How can I check if my code works?
by running it
We have a main observer
in the new rosebox update we will have forbidden all fun
only banner remains
it wasn't even that hard to implement like i thought so
only had to handle themed & unthemed separately, did minimal changes to the banner & forced some background colors
around 50-70 lines of scss
codong
is there any vscode extension that adds hints to these
basically like
margin: top/bottom 6px left/right 16px;
cause I CAN NEVER REMEMBER
trbl
trouble
that's how i remember it
bc it's a trouble to remember it
or you get in trouble if you dont
its stupid ik
np
if you hover over the property key does vscode not give you a little preview of docs with that data?
it doesnt
hm, the syntax hint is pretty useless, that's frustrating
yes
Yop
I remember hunting for an extension too
But i ended up just resigning myself to looking it up every time
That or making it colored and setting different numbers
the shorthands are always:
1value = all
2values = top+bottom left+right
4values = top bottom left right
iirc
they are clockwise
top right bottom left
but still i don't want to have to always think
i just want inline hints
and 3values = top left+right bottom
yeah for some reason remembering it's clockwise or counter-clockwise doesn't stick in my head
maybe trouble will
i hate when there is space i cannot utilize ๐ฅฒ
does anyone here know haskell
I want to do something multiple times in a loop
but it keeps complaining about main being a [IO ()] instead of a IO ()
Haskell is for people much smarter than me alas
Improving profile popouts, panels, etc
Liking this so far
Very nice
Very clean, me like
you are beyond help... may God have mercy on you
wtf fellow swede??
pronouns...
Oh wehhh, pronouns, how horrible
soft hands
Indeedo 
liberal mjuk hands
No clue
Go cry a river.
[Reply to:](#๐งฉ-plugin-development message) pronouns...
hmm?
you're personality is your fetish
vban @green vessel troll
Done!
he dmed me racist & homophobic shit who could have seen this coming

you're
Twist surprising absolutely nobody.
[Reply to:](#๐งฉ-plugin-development message) he dmed me racist & homophobic shit who could have seen this coming
<:WHโฆ

i don't have pronouns people just scream instead of saying my name
i don't know why, it's actually quite disturbing
/j
rewritten my rosebox discord css for the 3rd time now lol. been maintaining it since 2020.
you can import using this link: https://kraxen72.github.io/rosebox/discord/dist/main.css
if you like it, feel free to donate. my ko-fi link is in my about-me (on discord)
Made a tool that allows me to share a specific region of my screen on Discord 

Ok
i wanna add a binary search plugin debug function to vencord
basically uses binary search to figure out which plugin is causing an issue


aka
- disable half the plugins & restart discord
- if not fixed, we know it's in the still enabled half, if fixed we know it's in the disabled half
- use this info to exclude half the plugins and go to step 1
what if two plugins are somehow conflicting with each other
actually so real
its gonna be super joever if there are multiple broken plugins
yeah but it wouldnt be super accurate
if one broken plugin is on the first half and another on the second half you just explode i think
solution: shuffle plugins 
i think overall, accounting for multiple broken plugins, it would be more effective to try them all in sequence
ven bisect 
how often do we expect multiple broken plugins to be the issue
because if you just make the assumption that it'll happen, then you force the search to go from O(log n) to O(n) which is wayyy slower
computers are fast now itll be fine
it represents how many times the user will need to check if the error still exists too
with the current number of plugins it'll take at worst 7 tries to find a bad plugin with binary search but at worst 114 tries with checking plugins one by one
what is this shit ass font
"oh yeah lets make a ligature to turn 2 fs into one big and one small one because funny"
any subsequent fs after an f are small
fffff
not even that, just in the message editor
I might be wrong, but is this not being adjusted to the l that comes after so they're the same height?
any way to put the status (online/offline/dnd) on ppls avatars in chat?
PlatformIndicators kinda does that
define kinda
Something like this
i found the src code for my old discord bot
in c#
its kinda cool
it has a massive foundation and very little usable features
lol
i think its epic
same
how does c# work?
Wait, people don't test on production?
it works
yes?





@crude iron
