MCPcopy Create free account
hub / github.com/PolyMC/PolyMC / entitlementToJSONV3

Function entitlementToJSONV3

launcher/minecraft/auth/AccountData.cpp:246–254  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

244}
245
246void entitlementToJSONV3(QJsonObject &parent, MinecraftEntitlement p) {
247 if(p.validity == Katabasis::Validity::None) {
248 return;
249 }
250 QJsonObject out;
251 out["ownsMinecraft"] = QJsonValue(p.ownsMinecraft);
252 out["canPlayMinecraft"] = QJsonValue(p.canPlayMinecraft);
253 parent["entitlement"] = out;
254}
255
256bool entitlementFromJSONV3(const QJsonObject &parent, MinecraftEntitlement & out) {
257 auto entitlementObject = parent.value("entitlement").toObject();

Callers 1

saveStateMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected