trigg / Discover

Yet another discord overlay for linux
GNU General Public License v3.0
651 stars 28 forks source link

Use server custom profile picture #258

Closed ErranticSam closed 9 months ago

ErranticSam commented 2 years ago

don't know if it's possible to get the profile picture we set for a certain server when we're in a vocal channel of it ?

trigg commented 2 years ago

This has been talked about before but I don't know how people envision it looking. Just a title above list with server icon & channel name?

ErranticSam commented 2 years ago

ah sorry I described the issue poorly I was talking about the Discord Nitro feature allowing you to have custom server profiles and to change your profile picture depending on the server you're on

the idea would be to display the custom profile picture of each user if they have set it

trigg commented 2 years ago

Ah yes, I didn't even know that was a feature

ErranticSam commented 2 years ago

struggling a bit on this, do you know where I could get the current voice guild ID ?

trigg commented 2 years ago

https://github.com/trigg/Discover/blob/8b507a5323b2c46080bc1f39871ec009272c535d/discover_overlay/voice_overlay.py#L490

Here we decide if we have an avatar image for the user and if not request we download one. At this point we don't know the guild id and probably don't even know channel id, but could grab that from discover.connection.current_voice

trigg commented 2 years ago

it's quite likely, but I can;t test to find out, that this information is passed in when we get any new user data.

If you're up to finding out you could add print(j) before https://github.com/trigg/Discover/blob/8b507a5323b2c46080bc1f39871ec009272c535d/discover_overlay/discord_connector.py#L375

and see what new user information this reveals. When you enter a new channel it should print a long line of info about the channel and participants in chat

ErranticSam commented 2 years ago

I found a way to get the guild ID, it's all OK ... but the feature also needs the guild avatar ID of the user


and see what new user information this reveals. When you enter a new channel it should print a long line of info about the channel and participants in chat

about this, I found informations about current channel data through 'cmd' : 'GET_CHANNEL' : the array 'voice_states' displays all the users logged in the voice channel and their data

unfortunately, there isn't the guild specific avatar ID here, I'm still searching

trigg commented 2 years ago

This happens a lot, the api used is incomplete and often features get left out of it. Good luck on finding it

ErranticSam commented 2 years ago

yeah, I created a Feature Request on the Discord API GitHub to add this guild avatar ID to the RPC https://github.com/discord/discord-api-docs/discussions/5177

wait and see ...

trigg commented 9 months ago

I believe we're not about to see this changed, will close until anything happens on the other end