From 21da6d89658aef25c1def27dc5fa2c4055e6a6f9 Mon Sep 17 00:00:00 2001 From: Shokara Date: Mon, 4 Jan 2021 20:05:46 -0500 Subject: add offline account support I added the offline patch from my MultiMC repo[1]. The only change I made compared to my fork was adding an extra sentence in the account adder dialog that the password needs to be blank for an offline account. Signed-off-by: Shokara --- api/logic/minecraft/auth/MojangAccount.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'api/logic/minecraft/auth/MojangAccount.h') diff --git a/api/logic/minecraft/auth/MojangAccount.h b/api/logic/minecraft/auth/MojangAccount.h index 7006435e..92679076 100644 --- a/api/logic/minecraft/auth/MojangAccount.h +++ b/api/logic/minecraft/auth/MojangAccount.h @@ -77,6 +77,9 @@ public: /* construction */ //! Creates an empty account for the specified user name. static MojangAccountPtr createFromUsername(const QString &username); + //! Creates an offline account for the specified user name. + static MojangAccountPtr createFromUsernameOffline(const QString &username); + //! Loads a MojangAccount from the given JSON object. static MojangAccountPtr loadFromJson(const QJsonObject &json); -- cgit v1.2.3