XFG16 / YouTubeDiscordPresence

An extension that takes data directly from the YouTube video playing on the browser and displays it as a rich presence on Discord. Works similar to the Spotify Discord rich presence.
https://chrome.google.com/webstore/detail/youtubediscordpresence/hnmeidgkfcbpjjjpmjmpehjdljlaeaaa
MIT License
121 stars 6 forks source link

Adding Custom Activity Type #5

Closed BloodyBuster closed 1 year ago

BloodyBuster commented 1 year ago

Is it possible to add a custom activity type for the rich presence based upon application is being used. i.e instead of showing "Playing a game" is will be "Watching" on you are on youtube and "Listening" on youtube music.

image image

As far as I know something like this is technically possible since I have seen this plenty of time some bot, though I am not sure it's possible to do here as am not familiar with discord SDK

XFG16 commented 1 year ago

I'll look into it when I have time and let you know if I can find a method to make it work!

Since you seem to have gotten it to say that, would you mind sharing a code snippet of how you accomplished that?

BloodyBuster commented 1 year ago

Unfortunately this was done by using a browser extension and only work on browser version of the discord (though the status can be view in the discord client too), thus I am unable to provides anything code snippet.

Though after looking at the source code of said extension, it seems like it achieved it by doing a script injection to the browser version of discord or by modifying discord package? I am not sure. I can provide the GitHub link for the browser extension if you so desire.

XFG16 commented 1 year ago

Sure, it would be great if you could provide a reference to the extension!

BloodyBuster commented 1 year ago

https://github.com/DznDani/Nexzt

This is the link to the browser extension. Though I am somewhat skeptical if this will work by judging by just looking at that code, though there is no harm in trying, good luck!

XFG16 commented 1 year ago

image Unfortunately, I don't think this will be possible. I've tried figuring out a way for weeks, but unless you can provide me with another resource, I won't be able to implement this 😨