Skip to content

Fetch the player name from itch.io#21285

Merged
PunkPun merged 1 commit into
OpenRA:bleedfrom
Mailaender:itch-player-name
Jul 28, 2024
Merged

Fetch the player name from itch.io#21285
PunkPun merged 1 commit into
OpenRA:bleedfrom
Mailaender:itch-player-name

Conversation

@Mailaender

Copy link
Copy Markdown
Member

Closes #14708

Comment thread OpenRA.Mods.Common/Widgets/Logic/IntroductionPromptLogic.cs Outdated
Comment thread OpenRA.Mods.Common/ItchIntegration.cs Outdated
@pchote

pchote commented Jan 7, 2024

Copy link
Copy Markdown
Member

It might make sense to make this use an interface so that the discord module can implement it too?

@Mailaender

Copy link
Copy Markdown
Member Author

If the Discord API supports it, I will do that as a followup pull request.

abcdefg30
abcdefg30 previously approved these changes Jan 8, 2024

@abcdefg30 abcdefg30 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Codes changes lgtm so far.

If the Discord API supports it, I will do that as a followup pull request.

I think we need to/should add a ExternalNameProvider class which implements IGlobalModData, and that class can then calls the integrations for itch, Discord, etc. I'm ok with not changing this here though, it should be a simple enough change in IntroductionPromptLogic.

There DiscordRpcClient offers a way to get the display and user names of the current user, so DiscordService can return it (client.CurrentUser.Username/DisplayName).

@anvilvapre

Copy link
Copy Markdown
Contributor

Please don't even start extra threads if the api key is not set.

@teinarss

Copy link
Copy Markdown
Contributor

Please don't even start extra threads if the api key is not set.

This will be done on the threadpool, which is already created elsewhere in the code. So im pretty sure no new thread will be created in this case.

@PunkPun PunkPun added this to the Next Release milestone Jan 21, 2024
PunkPun
PunkPun previously approved these changes Feb 9, 2024

@PunkPun PunkPun left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, untested

Comment thread OpenRA.Mods.Common/ItchIntegration.cs Outdated
@Mailaender Mailaender dismissed stale reviews from PunkPun and abcdefg30 via 78c8c85 July 7, 2024 18:39
@PunkPun PunkPun merged commit ff276b4 into OpenRA:bleed Jul 28, 2024
@PunkPun

PunkPun commented Jul 28, 2024

Copy link
Copy Markdown
Member

changelog

@Mailaender Mailaender deleted the itch-player-name branch July 29, 2024 10:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

For new Itch installs, grab the player's name from Itch.

7 participants