Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Discord improvements #374

Draft
wants to merge 3 commits into
base: master
Choose a base branch
from
Draft

Discord improvements #374

wants to merge 3 commits into from

Conversation

Bios-Marcel
Copy link
Member

@Bios-Marcel Bios-Marcel commented Dec 26, 2024

TODO:

  • Hide players per IP option completly
  • Prevent rejoin after kick
  • Optionally include discord script IF the client has a discord instance cookie
    • We need to forward all the query parameters, otherwise the SDK can't authenticate

Maybe:

  • Automatically associate a randomly joined public lobbies with the activity?

@Bios-Marcel Bios-Marcel changed the title wip Discord improvements Dec 26, 2024
@Bios-Marcel Bios-Marcel force-pushed the wip_discord_improvements branch from cd26ecd to 81a68f5 Compare December 28, 2024 15:27
@Bios-Marcel
Copy link
Member Author

Okay ... so the discord sdk needs all the parameters.

Passing them through as query parameters was too annoying.
The Discord SDK was made for SPAs, which scribble.rs isn't.

To solve this we use a modified DiscordSDK and cookies.

HOWEVER ... it seems that this also won't work, as the DiscordSDK relies on messages posted to the iframe, after its blocking scripts have loaded.

This can probably be solved two ways:

A: Load the script in index and save the data we need
B: Save the message and replay it.

B would probably be better though, as we can keep using the connection for other stuff in the future.

@Bios-Marcel Bios-Marcel force-pushed the wip_discord_improvements branch from 81a68f5 to 34ebc5b Compare January 2, 2025 15:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant