Skip to content

feat(modpacks): restore support for ftb modpacks, and fetch official curseforge api key #149

Merged
notwindstone merged 16 commits intoFreesmTeam:developfrom
LunisCandle:pack-apis
Feb 15, 2026
Merged

feat(modpacks): restore support for ftb modpacks, and fetch official curseforge api key #149
notwindstone merged 16 commits intoFreesmTeam:developfrom
LunisCandle:pack-apis

Conversation

@LunisCandle
Copy link
Contributor

No description provided.

Based upon the implementation by @evan-goode in FJord, without the popup on first launch.
Remove the Prism Launcher CurseForge key, as we have access to the official one.
Removes the message above CurseForge modpacks as manually downloading mods is not required with the official API.
Copy link
Member

@s0me1newithhand7s s0me1newithhand7s left a comment

Choose a reason for hiding this comment

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

since all builds are failed i recommend to convert this PR to draft
ty

@notwindstone notwindstone self-assigned this Feb 12, 2026
@LunisCandle LunisCandle marked this pull request as draft February 12, 2026 16:29
@notwindstone
Copy link
Member

@LunaisLazier @so5iso4ka @s0me1newithhand7s could you review my changes? launcher is building now

@notwindstone
Copy link
Member

image

are we deadass

it worked here though

image

@notwindstone
Copy link
Member

tested on windows 10, everything works

@LunisCandle
Copy link
Contributor Author

So the api key shows in settings?

@notwindstone
Copy link
Member

@LunaisLazier yes

@LunisCandle LunisCandle marked this pull request as ready for review February 12, 2026 23:45
@s0me1newithhand7s
Copy link
Member

cachix is a bitch ignore this pls idc about cachix cache since garnix ci is better

Copy link
Member

@s0me1newithhand7s s0me1newithhand7s left a comment

Choose a reason for hiding this comment

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

k


const auto& keyByteArray = block.mid(startIndex, finalIndex - startIndex);
m_result = QString{ keyByteArray };
qDebug() << "Fetched Flame API key: " << m_result;
Copy link
Member

Choose a reason for hiding this comment

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

I think it's worth using qCDebug(authCredentials()) here.


const auto& block = qUncompress(res);
if (block.isEmpty()) {
emitFailed("Couldn't decompress Curseforge app data.");
Copy link
Member

Choose a reason for hiding this comment

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

missing return after emitFailed()

const QByteArray preceding{ precedingString };
const auto& precedingIndex = block.indexOf(preceding);
if (precedingIndex == -1) {
emitFailed(QString("Couldn't find string '%1'.").arg(precedingString));
Copy link
Member

Choose a reason for hiding this comment

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

and here

const auto& startIndex = precedingIndex + preceding.size();
const auto& finalIndex = block.indexOf(QByteArray{ "\"" }, startIndex);
if (finalIndex == -1) {
emitFailed("Couldn't find closing \" for cfCoreApiKey value.");
Copy link
Member

Choose a reason for hiding this comment

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

and here

#endif
this, [this](QNetworkReply::NetworkError error) {
qCritical() << "Network error: " << error;
emitFailed(m_reply->errorString());
Copy link
Member

Choose a reason for hiding this comment

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

and here

as it is no longer supported

Signed-off-by: so5iso4ka <so5iso4ka@icloud.com>
Signed-off-by: so5iso4ka <so5iso4ka@icloud.com>
Signed-off-by: so5iso4ka <so5iso4ka@icloud.com>
Signed-off-by: so5iso4ka <so5iso4ka@icloud.com>
Signed-off-by: so5iso4ka <so5iso4ka@icloud.com>
@notwindstone notwindstone merged commit 58e04b1 into FreesmTeam:develop Feb 15, 2026
16 of 18 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants