add launcher folder and some checks to it

This commit is contained in:
2026-08-23 01:20:18 +03:00
parent 2c4b594c90
commit af4230500e
13 changed files with 328 additions and 169 deletions
+13 -10
View File
@@ -14,11 +14,11 @@ struct AuthResult
bool twoFactorRequired = false;
QString error;
QString playerName; // ${auth_player_name}
QString uuid; // ${auth_uuid}, hex без дефисов
QString accessToken; // ${auth_access_token}
QString clientToken; // ${clientid}
QString userType; // ${user_type}: legacy / msa / ELYBY
QString playerName; // ${auth_player_name}
QString uuid; // ${auth_uuid}, hex без дефисов
QString accessToken; // ${auth_access_token}
QString clientToken; // ${clientid}
QString userType; // ${user_type}: legacy / msa / ELYBY
};
// Yggdrasil-клиент Ely.by плюс офлайн-режим. Все сетевые методы асинхронные:
@@ -56,16 +56,19 @@ public:
// Скачивает authlib-injector в targetDir, если его там ещё нет.
// Колбэк получает путь к jar либо текст ошибки.
void ensureAuthlibInjector(const QString &targetDir,
std::function<void(const QString &path, const QString &error)> callback);
void ensureAuthlibInjector(
const QString &targetDir,
std::function<void(const QString &path, const QString &error)> callback);
signals:
void progress(const QString &message);
private:
void postJson(const QString &endpoint,
const QJsonObject &body,
std::function<void(int status, const QJsonObject &response, const QString &transportError)> handler);
void postJson(
const QString &endpoint,
const QJsonObject &body,
std::function<void(int status, const QJsonObject &response, const QString &transportError)>
handler);
void authenticate(const QString &login,
const QString &password,