Delta-v icon indicating copy to clipboard operation
Delta-v copied to clipboard

Discord Linking AND Patreon OOC Colors for Nuclear Operatives

Open Coryler opened this issue 1 month ago • 8 comments

About the PR

Add Discord Linking through usage of a Discord Bot and Role-based Name Coloring for Nuclear Operatives, once the player is verified.

Original PR #4675

Why / Balance

From Previous PR: For Issue #4551, and personally wanted to try it.

This is a PR also including the capability of Linking you Discord Account with the Delta-V SS14 Stuff.

Note: It requires a Discord Bot and its specific Bot Token to work.

Technical details

  • Add DiscordUserLink Classes handle the Verification Process and subsequent Updating into the Databse
  • DB Migration to add Discord uId for each player
  • Verify and Unverify Command which can be called with the Discord Bot

Media

514927329-bff74a4f-0dfb-4815-bc89-e3028c5f30e2 514927336-4772ce76-324d-488f-9a97-cd98cd2ebeab

Requirements

  • [x] I have tested all added content and changes.
  • [x] I have added media to this PR or it does not require an ingame showcase.

Breaking changes

Currently Code caches Guild Members a bit late, which makes them first be cached into the Guild User List when the Discord User changes something on their profile. Might just be me specific though due to the short-time the bot is running to its next restart in my case for testing.

Might be less of a problem for the server though.

Changelog

🆑

  • add: Discord Linking
  • add: Patreon OOC Coloring for Nuclear Operatives

Coryler avatar Nov 18 '25 22:11 Coryler

Hi, this code uses my code for linking and I can safely recommend you not to use it as-is. Discord linking could be done in a similar way, with using a database entry on their player to know their discord user ID, but the way I handle this in practice on the discord side is both hasty and wildly shitcode.

I fully recommend a complete rewrite that works with upstream's Simyon264 to properly implement.

sleepyyapril avatar Nov 20 '25 02:11 sleepyyapril

Heya, thanks for letting me know @sleepyyapril. The guild member cache on netcord seems a bit wonky on it... that's what I noticed. What do you mean with upstream's Simyon264? Did upstream also have another version of linking I'm unaware of?

Coryler avatar Nov 20 '25 02:11 Coryler

@sleepyyapril Im guessing you mean this PR? https://github.com/space-wizards/space-station-14/pull/39372

ShepardToTheStars avatar Nov 20 '25 02:11 ShepardToTheStars

@sleepyyapril Im guessing you mean this PR? space-wizards/space-station-14#39372

no, that PR is unrelated. he wanted to do something similar, so id recommend just upstreaming it lmao

sleepyyapril avatar Nov 20 '25 02:11 sleepyyapril

he will NOT be finishing that :pray:

sleepyyapril avatar Nov 20 '25 02:11 sleepyyapril

Fun stuff.

ShepardToTheStars avatar Nov 20 '25 02:11 ShepardToTheStars

Either way, Ill take a look at this soon.

ShepardToTheStars avatar Nov 20 '25 02:11 ShepardToTheStars

Ok, just let me know if this needs another complete rewrite or run through.

Coryler avatar Nov 20 '25 03:11 Coryler