insomniac-eeper / BTTDRichDiscordPresence

BepInEx mod to add Rich Discord Presence to the game Back to the Dawn.
MIT License
1 stars 0 forks source link

[BUG] Reconnecting w/ Discord after dropped connection doesn't update presence on connect #6

Closed insomniac-eeper closed 1 month ago

insomniac-eeper commented 1 month ago

Describe the bug If the mod reconnects to a discord client after dropped connection (in this case done via forcefully stopping discord) it will not set the presence on connect, rather it will wait until presence has been updated.

To Reproduce

  1. Start game with Discord running in the background
  2. Wait until presence is set to main menu
  3. End discord task
  4. Observe client warnings in BepInEx logs
  5. Restart Discord
  6. Observe successful connection with client
  7. Observe no status update

Expected behavior Expected behavior would be to send last set game state on a successful connect. This should not cause issues with mod startup since we define a default value for game state before any hooks have had the opportunity to run.

Screenshots N/A

Desktop (please complete the following information):