Merge pull request #40 from PRO100KatYT/main

Some Winterfest, Halloween, Battle Bus and Questline stuff
This commit is contained in:
Lawin0129
2021-11-28 15:38:50 +00:00
committed by GitHub

View File

@@ -961,6 +961,30 @@ express.get("/fortnite/api/calendar/v1/timeline", async (req, res) => {
"activeSince": "2020-01-01T00:00:00.000Z" "activeSince": "2020-01-01T00:00:00.000Z"
}]; }];
if (seasondata.season == 3) {
activeEvents.push(
{
"eventType": "EventFlag.Spring2018Phase1",
"activeUntil": "9999-01-01T00:00:00.000Z",
"activeSince": "2020-01-01T00:00:00.000Z"
},
{
"eventType": "EventFlag.Spring2018Phase2",
"activeUntil": "9999-01-01T00:00:00.000Z",
"activeSince": "2020-01-01T00:00:00.000Z"
},
{
"eventType": "EventFlag.Spring2018Phase3",
"activeUntil": "9999-01-01T00:00:00.000Z",
"activeSince": "2020-01-01T00:00:00.000Z"
},
{
"eventType": "EventFlag.Spring2018Phase4",
"activeUntil": "9999-01-01T00:00:00.000Z",
"activeSince": "2020-01-01T00:00:00.000Z"
})
}
if (seasondata.season == 4) { if (seasondata.season == 4) {
activeEvents.push( activeEvents.push(
{ {
@@ -1003,6 +1027,15 @@ express.get("/fortnite/api/calendar/v1/timeline", async (req, res) => {
"activeSince": "2020-01-01T00:00:00.000Z" "activeSince": "2020-01-01T00:00:00.000Z"
}) })
} }
if (req.headers["user-agent"].includes("Release-5.10")) {
activeEvents.push(
{
"eventType": "EventFlag.BirthdayBattleBus",
"activeUntil": "9999-01-01T00:00:00.000Z",
"activeSince": "2020-01-01T00:00:00.000Z"
})
}
if (seasondata.season == 6) { if (seasondata.season == 6) {
activeEvents.push( activeEvents.push(
@@ -1022,6 +1055,20 @@ express.get("/fortnite/api/calendar/v1/timeline", async (req, res) => {
"activeSince": "2020-01-01T00:00:00.000Z" "activeSince": "2020-01-01T00:00:00.000Z"
}) })
} }
if (req.headers["user-agent"].includes("Release-6.20") || req.headers["user-agent"].includes("Release-6.21")) {
activeEvents.push(
{
"eventType": "EventFlag.LobbySeason6Halloween",
"activeUntil": "9999-01-01T00:00:00.000Z",
"activeSince": "2020-01-01T00:00:00.000Z"
},
{
"eventType": "EventFlag.HalloweenBattleBus",
"activeUntil": "9999-01-01T00:00:00.000Z",
"activeSince": "2020-01-01T00:00:00.000Z"
})
}
if (seasondata.season == 7) { if (seasondata.season == 7) {
activeEvents.push( activeEvents.push(
@@ -1081,7 +1128,7 @@ express.get("/fortnite/api/calendar/v1/timeline", async (req, res) => {
} }
// Credits to Silas for three of these event flags and credits to uni for testing on 11.31 // Credits to Silas for three of these event flags and credits to uni for testing on 11.31
if (req.headers["user-agent"].includes("Release-11.31")) { if (req.headers["user-agent"].includes("Release-11.31") || req.headers["user-agent"].includes("Release-11.40")) {
activeEvents.push( activeEvents.push(
{ {
"eventType": "EventFlag.Winterfest.Tree", "eventType": "EventFlag.Winterfest.Tree",
@@ -1094,7 +1141,12 @@ express.get("/fortnite/api/calendar/v1/timeline", async (req, res) => {
"activeSince": "2020-01-01T00:00:00.000Z" "activeSince": "2020-01-01T00:00:00.000Z"
}, },
{ {
"eventType": "EventFlag.Phoenix.Winterfest", "eventType": "EventFlag.LTE_WinterFest2019",
"activeUntil": "9999-01-01T00:00:00.000Z",
"activeSince": "2020-01-01T00:00:00.000Z"
},
{
"eventType": "EventFlag.HolidayDeco",
"activeUntil": "9999-01-01T00:00:00.000Z", "activeUntil": "9999-01-01T00:00:00.000Z",
"activeSince": "2020-01-01T00:00:00.000Z" "activeSince": "2020-01-01T00:00:00.000Z"
}, },
@@ -1102,6 +1154,16 @@ express.get("/fortnite/api/calendar/v1/timeline", async (req, res) => {
"eventType": "EventFlag.Season11.Frostnite", "eventType": "EventFlag.Season11.Frostnite",
"activeUntil": "9999-01-01T00:00:00.000Z", "activeUntil": "9999-01-01T00:00:00.000Z",
"activeSince": "2020-01-01T00:00:00.000Z" "activeSince": "2020-01-01T00:00:00.000Z"
},
{
"eventType": "EventFlag.Season11.WinterFest.Quests.Phase1",
"activeUntil": "9999-01-01T00:00:00.000Z",
"activeSince": "2020-01-01T00:00:00.000Z"
},
{
"eventType": "EventFlag.Season11.WinterFest.Quests.Phase2",
"activeUntil": "9999-01-01T00:00:00.000Z",
"activeSince": "2020-01-01T00:00:00.000Z"
}) })
} }
@@ -5941,6 +6003,11 @@ function getContentPages(req) {
contentpages.dynamicbackgrounds.backgrounds.backgrounds[0].stage = "seasonx"; contentpages.dynamicbackgrounds.backgrounds.backgrounds[0].stage = "seasonx";
contentpages.dynamicbackgrounds.backgrounds.backgrounds[1].stage = "seasonx"; contentpages.dynamicbackgrounds.backgrounds.backgrounds[1].stage = "seasonx";
} }
if (req.headers["user-agent"].includes("Release-11.31") || req.headers["user-agent"].includes("Release-11.40")) {
contentpages.dynamicbackgrounds.backgrounds.backgrounds[0].stage = "Winter19";
contentpages.dynamicbackgrounds.backgrounds.backgrounds[1].stage = "Winter19";
}
} catch (err) {} } catch (err) {}
return contentpages; return contentpages;