Commit Graph

56 Commits

Author SHA1 Message Date
Luna
b4b9051793 Merge in Changes from Prism 9.2 2025-01-11 13:58:12 -06:00
Evan Goode
c32aaf244d It compiles, Yggdrasil login working except error handling 2024-10-26 00:17:24 -04:00
Evan Goode
7dbaa896a6 Merge tag '9.0' into develop
This is an intermediate/halfway commit, more refactoring is needed to
get this to build.
2024-10-25 15:34:57 -04:00
Trial97
2b949a8059
improve login account checking
Signed-off-by: Trial97 <alexandru.tripon97@gmail.com>
2024-05-22 10:53:24 +03:00
Trial97
31d0cad377
Merge branch 'develop' of https://github.com/PrismLauncher/PrismLauncher into demo 2024-05-18 16:24:22 +03:00
Trial97
09c0c11033
Add back device code flow
Signed-off-by: Trial97 <alexandru.tripon97@gmail.com>
2024-05-16 21:58:25 +03:00
Trial97
abedc6a23c
Improve login UI
Signed-off-by: Trial97 <alexandru.tripon97@gmail.com>
2024-05-15 17:25:15 +03:00
Trial97
e285a85fe8
Removed AccountTask
Signed-off-by: Trial97 <alexandru.tripon97@gmail.com>
2024-05-14 00:21:51 +03:00
Trial97
3336f8107c
Removed AuthRequest and NetAction
Signed-off-by: Trial97 <alexandru.tripon97@gmail.com>
2024-05-14 00:21:45 +03:00
Evan Goode
3e7b747926 Merge branch 'unmojang/8.2' into develop 2024-05-03 19:10:19 -04:00
Evan Goode
96b4933326 Merge Prism Launcher 8.2
Signed-off-by: Evan Goode <mail@evangoo.de>
2024-03-21 10:59:32 -04:00
BatteredBunny
187475e35f Adjusted AuthServerColumn to return authlibInjectorUrl instead of authServerUrl, make the column auto-resize
Signed-off-by: BatteredBunny <ayes2022@protonmail.com>
2024-01-23 22:38:41 +02:00
Trial97
be67067fa2
Merge branch 'develop' of https://github.com/PrismLauncher/PrismLauncher into demo 2023-11-23 16:23:56 +02:00
Evan Goode
dcc2d77ebb Fix offline accounts
Original authlib-injector work had a bug making offline accounts not
save correctly.
2023-11-16 01:15:17 -05:00
Evan Goode
cdb2f09bd4 Merge branch 'unmojang' into unmojang-8.0 2023-11-15 21:23:01 -05:00
Evan Goode
be8c8ad9ad Auto migrate Ely.by accounts to authlib-injector
Signed-off-by: Evan Goode <mail@evangoo.de>
2023-11-15 15:23:24 -05:00
Evan Goode
9430026192 Merge tag '8.0' into unmojang-8.0
Upstream changelog: https://github.com/PrismLauncher/PrismLauncher/releases/tag/8.0

(Imcomplete) list of changes in 8.0 relevant to PollyMC:
- Prism has dropped support for Mojang accounts
  - https://github.com/PrismLauncher/PrismLauncher/pull/1656
  - Added it back to PollyMC primarily since the Mojang authentication
    code is also used for authlib-injector accounts. Some users may also
    still want to be able to log in to Mojang accounts for some reason:
    https://github.com/fn2006/PollyMC/issues/115#issuecomment-1805384658,
    even if they do not provide authentication to multiplayer servers.
  - To my surprise, I could still log in to a Mojang account, get its
    skin, and launch the game. Authentication to servers, of course, did
    not work.
  - Tested: logging into authlib-injector, Mojang, and MSA accounts and
    launching the game.
- Prism has added a built-in updater for Windows and Linux that I assume
  provides similar functionality to Sparkle on macOS:
  https://github.com/PrismLauncher/PrismLauncher/pull/1268. There is a
  Launcher_UPDATER_GITHUB_REPO variable in CMakeLists.txt that specifies
  the repo checked by the updater. I have changed this to the PollyMC
  repository, and since PollyMC follows almost the same CI/release
  patterns as Prism Launcher, it might work with PollyMC, too, but I
  have not tested it yet.
- Add macOS support to Nix
  - https://github.com/PrismLauncher/PrismLauncher/pull/1485
  - Untested
- The "PollyMC-Linux-8.0.tar.gz" and similar build artifacts were
  renamed to "PollyMC-Linux-8.0-Qt5.tar.gz" to match their
  "PollyMC-Linux-8.0-Qt6.tar.gz" counterparts.
- Removed Windows MSVC Legacy builds
- Removed Quilt Beacon toggle, the beacon is now always disabled:
  https://github.com/PrismLauncher/PrismLauncher/pull/1547,
  https://github.com/PrismLauncher/meta/pull/23
- Prism removed FTB support in 7.0, but I tested creating an FTB
  instance to make sure it still works in 8.0

Signed-off-by: Evan Goode <mail@evangoo.de>
2023-11-15 14:37:14 -05:00
Evan Goode
b1738deffb authlib-injector: Mark correct account as in use
Fixes a bug where the wrong account could be marked as "in use" when the
game is launched if there are multiple accounts that share the same
profile ID. This can lead to the launcher trying to refresh an account
that's currently in use by the game, leading to "Invalid session" errors
in-game.

Signed-off-by: Evan Goode <mail@evangoo.de>
2023-11-15 12:11:12 -05:00
Trial97
50a4d61ded
Fixed demo mode
Signed-off-by: Trial97 <alexandru.tripon97@gmail.com>
2023-11-10 23:26:41 +02:00
LocalSpook
9d972ccc63 Localize account type in account list
Signed-off-by: LocalSpook <56512186+LocalSpook@users.noreply.github.com>
2023-10-26 13:32:33 -07:00
Trial97
7c636d4608
Removed mojang
Signed-off-by: Trial97 <alexandru.tripon97@gmail.com>
2023-09-25 17:44:04 +03:00
Evan Goode
9d442a0348 authlib-injector
* 'Custom Yggdrasil' AccountType

Signed-off-by: Evan Goode <mail@evangoo.de>

* Allow multiple accounts with the same player UUID

Signed-off-by: Evan Goode <mail@evangoo.de>

* Use correct services server URL for SkinDelete

Signed-off-by: Evan Goode <mail@evangoo.de>

* Correctly use CustomYggdrasilRefresh, add warning message

Signed-off-by: Evan Goode <mail@evangoo.de>

* Custom Yggdrasil: Readability fixes

Also made the MinecraftEntitlement for Custom Yggdrasil accounts work
just like offline accounts---instead of checking the reply from the auth
server, Custom Yggdrasil accounts are granted canPlayMinecraft and
ownsMinecraft when they are created, in MinecraftAccount.cpp.

Signed-off-by: Evan Goode <mail@evangoo.de>

* Custom Yggdrasil: Add extra confirmation dialog

Signed-off-by: Evan Goode <mail@evangoo.de>

* Add install authlib-injector button

Signed-off-by: Evan Goode <mail@evangoo.de>

* authlib-injector accounts

Signed-off-by: Evan Goode <mail@evangoo.de>

* Suggest installing authlib-injector when needed

Signed-off-by: Evan Goode <mail@evangoo.de>

* Use Unmojang metadata

Signed-off-by: Evan Goode <mail@evangoo.de>

* Use std::string for MANAGED_AGENTS, not QString

---------

Signed-off-by: Evan Goode <mail@evangoo.de>

Resolve X-Authlib-Injector-API-Location

Signed-off-by: Evan Goode <mail@evangoo.de>

Prefetch authlib-injector metadata

Resolves https://github.com/unmojang/PrismLauncher/issues/4

See https://github-com.translate.goog/yushijinhun/authlib-injector/wiki/%E5%90%AF%E5%8A%A8%E5%99%A8%E6%8A%80%E6%9C%AF%E8%A7%84%E8%8C%83?_x_tr_sl=auto&_x_tr_tl=en&_x_tr_hl=en-US#%E9%85%8D%E7%BD%AE%E9%A2%84%E8%8E%B7%E5%8F%96

Signed-off-by: Evan Goode <mail@evangoo.de>

drag-and-drop authlib-injector URL, clang-format

Resolves https://github.com/unmojang/PrismLauncher/issues/2

Signed-off-by: Evan Goode <mail@evangoo.de>
2023-09-04 19:00:18 +01:00
fn2006
65821b54e6 Remove current Ely.by implementation 2023-09-04 01:35:37 +01:00
fn2006
b6904ba50a Merge branch 'develop' of https://github.com/PrismLauncher/PrismLauncher into develop 2023-09-04 00:39:20 +01:00
Sefa Eyeoglu
73adac2501
fix: use QColorConstants in Qt 5.14+
Signed-off-by: Sefa Eyeoglu <contact@scrumplex.net>
2023-08-11 15:57:12 +02:00
maple!
97ef8e8d0e Fix transparency in skin icon
QPainter has a bug where drawing transparency to a freshly initialized, empty QPixmap causes garbage data to be drawn. This broke the rendering of the skin icon. The fix is simply to fill the QPixmap with empty transparent pixels beforehand.

Signed-off-by: maple! <averyrudelphe@gmail.com>
2023-08-10 15:32:47 +02:00
fn2006
847430b113 Merge branch 'release-7.x' of https://github.com/PrismLauncher/PrismLauncher into develop 2023-08-10 10:09:08 +01:00
Sefa Eyeoglu
1d638e018a
chore: update license headers
Signed-off-by: Sefa Eyeoglu <contact@scrumplex.net>
2023-08-04 19:41:47 +02:00
Sefa Eyeoglu
1d468ac35a
chore: reformat
Signed-off-by: Sefa Eyeoglu <contact@scrumplex.net>
2023-08-02 18:35:35 +02:00
TheKodeToad
648a69594f Fix token "0" being replaced
Signed-off-by: TheKodeToad <TheKodeToad@proton.me>
(cherry picked from commit f505d43fc0)
2023-07-24 18:41:43 +00:00
TheKodeToad
f505d43fc0 Fix token "0" being replaced
Signed-off-by: TheKodeToad <TheKodeToad@proton.me>
2023-07-24 13:43:26 +01:00
Sefa Eyeoglu
f8fcb98c68
fix: generate predictable UUIDs for offline accounts
Signed-off-by: Sefa Eyeoglu <contact@scrumplex.net>
2023-07-18 10:07:35 +02:00
fn2006
a951bd1c3e Merge branch 'develop' of https://github.com/PrismLauncher/PrismLauncher into develop 2023-05-30 17:59:26 +01:00
Rachel Powers
12f0d51c0c Fix: signal/slot macro -> func pointer & network fixes
- convert qt connect calls to use function pointers instead of the signal/slot macros wherever practical (UI classes were mostly left alone, target was tasks and processes)
- give signals an explicit receivers to use the static method over the instance method wherever practical
- ensure networks tasks are using the `errorOccured` signal added in Qt5.15 over the deprecated `error` signal
- ensure all networks tasks have an sslErrors signal connected
- add seemingly missing `MinecraftAccount::authSucceeded` connection for `MSAInteractive` login flow

Signed-off-by: Rachel Powers <508861+Ryex@users.noreply.github.com>
2023-04-17 18:23:18 -07:00
fn2006
1821081521 Merge branch 'develop' of https://github.com/PrismLauncher/PrismLauncher into develop 2023-02-05 22:11:58 +00:00
flow
29f7ea752f
refactor: make shared_qobject_ptr ctor explicit
This turns issues like creating two shared ptrs from a single raw ptr
from popping up at runtime, instead making them a compile error.

Signed-off-by: flow <flowlnlnln@gmail.com>
2023-01-25 16:57:51 -03:00
Fintan Martin
763627ee65 Merge branch 'develop' of https://github.com/PolyMC/PolyMC into rebase 2022-08-22 11:58:41 +01:00
fn2006
0170e8b177 Add Ely.by accounts (#17)
* Initial Ely.by support

* Fix profile pictures for Ely.by

* Disable upload and delete skin buttons for Ely.by accounts

* Port UltimMC's authlib injector to PollyMC
2022-08-19 12:22:38 +01:00
flow
362ecdb583
refactor+fix: use QSharedPointer for shared_qobject_ptr
Signed-off-by: flow <flowlnlnln@gmail.com>
2022-08-04 15:33:51 -03:00
Sefa Eyeoglu
ff2cd50bfa
refactor: replace QRegExp with QRegularExpression
Signed-off-by: Sefa Eyeoglu <contact@scrumplex.net>
2022-07-10 12:17:52 +02:00
flow
5da87d1904
fix: add missing connections to the abort signal
Beginning with efa3fbff39, we separated
the failing and the aborting signals, as they can mean different
things in certain contexts. Still, some places are not yet changed to
reflect this modification. This can cause aborting of progress dialogs
to not work, instead making the application hang in an unusable satte.

This goes through some places where it's not hooked up yet, fixing their
behaviour in those kinds of situation.
2022-06-22 20:20:39 -03:00
Sefa Eyeoglu
a160bd0062
chore: add license header to files I modified 2022-03-19 12:46:56 +01:00
Sefa Eyeoglu
9c71f364d2
feat(accounts): add disabled account state 2022-02-18 12:32:24 +01:00
bexnoss
9d23ac562f Add offline mode support 2022-01-30 02:35:56 +01:00
Lenny McLennington
55597b458c
Revert "Merge pull request #50 from bexnoss/offline-mode"
This reverts commit b4f750e7db, reversing
changes made to b19e315615.
2022-01-17 03:45:47 +00:00
Lenny McLennington
f55297eca9
Revert "Merge pull request #81 from bexnoss/fix-msa-account-refresh"
This reverts commit 0bc8baf117, reversing
changes made to 81fe41a038.
2022-01-17 03:45:33 +00:00
bexnoss
5f9270ed4b Fix MSA account refresh 2022-01-16 23:30:17 +01:00
bexnoss
a1ff3b1ee3 Add offline mode support 2022-01-12 14:26:02 +01:00
Petr Mrázek
d37003b1de NOISSUE fix builds, make account refresh queue user friendly 2021-12-04 02:10:14 +01:00
Petr Mrázek
3c46d8a412 GH-4071 Heavily refactor and rearchitect account system
This makes the account system much more modular
and makes it treat errors as something recoverable,
unless they come directly from the MSA refresh token
becoming invalid.
2021-12-04 01:18:05 +01:00