mirror of
https://github.com/Lawin0129/LawinServer.git
synced 2026-01-14 03:12:22 +01:00
Add "CardPack" check for llama purchasing
This commit is contained in:
4
index.js
4
index.js
@@ -3868,6 +3868,7 @@ express.post("/fortnite/api/game/v2/profile/*/client/OpenCardPack", async (req,
|
|||||||
profile.commandRevision += 1;
|
profile.commandRevision += 1;
|
||||||
|
|
||||||
catalog.storefronts.forEach(function(value, a) {
|
catalog.storefronts.forEach(function(value, a) {
|
||||||
|
if (value.name.toLowerCase().startsWith("cardpack")) {
|
||||||
catalog.storefronts[a].catalogEntries.forEach(function(value, b) {
|
catalog.storefronts[a].catalogEntries.forEach(function(value, b) {
|
||||||
if (value.offerId == req.body.offerId) {
|
if (value.offerId == req.body.offerId) {
|
||||||
catalog.storefronts[a].catalogEntries[b].itemGrants.forEach(function(value, c) {
|
catalog.storefronts[a].catalogEntries[b].itemGrants.forEach(function(value, c) {
|
||||||
@@ -3898,6 +3899,7 @@ express.post("/fortnite/api/game/v2/profile/*/client/OpenCardPack", async (req,
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
PurchasedLlama = true;
|
PurchasedLlama = true;
|
||||||
@@ -3914,6 +3916,7 @@ express.post("/fortnite/api/game/v2/profile/*/client/OpenCardPack", async (req,
|
|||||||
campaign.commandRevision += 1;
|
campaign.commandRevision += 1;
|
||||||
|
|
||||||
catalog.storefronts.forEach(function(value, a) {
|
catalog.storefronts.forEach(function(value, a) {
|
||||||
|
if (value.name.toLowerCase().startsWith("cardpack")) {
|
||||||
catalog.storefronts[a].catalogEntries.forEach(function(value, b) {
|
catalog.storefronts[a].catalogEntries.forEach(function(value, b) {
|
||||||
if (value.offerId == req.body.offerId) {
|
if (value.offerId == req.body.offerId) {
|
||||||
catalog.storefronts[a].catalogEntries[b].itemGrants.forEach(function(value, c) {
|
catalog.storefronts[a].catalogEntries[b].itemGrants.forEach(function(value, c) {
|
||||||
@@ -4116,6 +4119,7 @@ express.post("/fortnite/api/game/v2/profile/*/client/OpenCardPack", async (req,
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
fs.writeFileSync("./profiles/campaign.json", JSON.stringify(campaign, null, 2), function(err) {
|
fs.writeFileSync("./profiles/campaign.json", JSON.stringify(campaign, null, 2), function(err) {
|
||||||
|
|||||||
Reference in New Issue
Block a user