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

Add host URL setting to achievements config #12531

Merged

Conversation

LillyJadeKatrin
Copy link
Contributor

The Host URL setting in the RetroAchievements config will, if set, be used as the host URL for all server requests for achievements. This allows for an easy switch to the RetroAchievements staging server for testing.

The Host URL setting in the RetroAchievements config will, if set, be used as the host URL for all server requests for achievements. This allows for an easy switch to the RetroAchievements staging server for testing.
@@ -38,6 +38,9 @@ void AchievementManager::Init()
{
if (!m_is_runtime_initialized && Config::Get(Config::RA_ENABLED))
{
std::string host_url = Config::Get(Config::RA_HOST_URL);
if (!host_url.empty())
rc_api_set_host(host_url.c_str());
Copy link
Member

Choose a reason for hiding this comment

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

Just wondering, does this properly handle cases where the entered URL is not a valid achievement endpoint (or otherwise unavailable/unaccessible)?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

You'll get an error in the logger and otherwise it will function basically identically to just not having a connection at all.

@lioncash lioncash merged commit 97160dd into dolphin-emu:master Jan 24, 2024
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
3 participants