warframe-worldstate-parser 2.21.0 → 2.23.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/SentientOutpost.js +3 -1
- package/lib/Sortie.js +6 -0
- package/lib/SteelPathOffering.js +1 -1
- package/lib/SyndicateJob.js +30 -6
- package/lib/SyndicateMission.js +6 -0
- package/lib/VoidTrader.js +9 -1
- package/lib/VoidTraderItem.js +1 -1
- package/lib/VoidTraderSchedule.js +8 -0
- package/lib/WorldState.js +2 -0
- package/package.json +22 -6
- package/types/lib/Alert.d.ts +3 -3
- package/types/lib/CetusCycle.d.ts +2 -2
- package/types/lib/ChallengeInstance.d.ts +1 -1
- package/types/lib/ConclaveChallenge.d.ts +3 -3
- package/types/lib/ConstructionProgress.d.ts +1 -1
- package/types/lib/DailyDeal.d.ts +3 -3
- package/types/lib/DarkSector.d.ts +8 -8
- package/types/lib/Fissure.d.ts +2 -2
- package/types/lib/FlashSale.d.ts +3 -3
- package/types/lib/GlobalUpgrade.d.ts +3 -3
- package/types/lib/Invasion.d.ts +7 -7
- package/types/lib/Mission.d.ts +4 -4
- package/types/lib/News.d.ts +1 -1
- package/types/lib/Nightwave.d.ts +5 -5
- package/types/lib/NightwaveChallenge.d.ts +2 -2
- package/types/lib/PersistentEnemy.d.ts +2 -2
- package/types/lib/Reward.d.ts +1 -1
- package/types/lib/SentientOutpost.d.ts +1 -1
- package/types/lib/Simaris.d.ts +2 -2
- package/types/lib/Sortie.d.ts +10 -5
- package/types/lib/SortieVariant.d.ts +2 -2
- package/types/lib/SyndicateJob.d.ts +13 -9
- package/types/lib/SyndicateMission.d.ts +8 -3
- package/types/lib/VoidTrader.d.ts +6 -3
- package/types/lib/VoidTraderItem.d.ts +2 -2
- package/types/lib/VoidTraderSchedule.d.ts +10 -0
- package/types/lib/WeeklyChallenge.d.ts +3 -3
- package/types/lib/WorldEvent.d.ts +7 -7
- package/types/lib/WorldState.d.ts +1 -1
package/lib/SentientOutpost.js
CHANGED
|
@@ -40,9 +40,11 @@ const sat = () => {
|
|
|
40
40
|
* @property {Date} previous.expiry When the mission became or becomes inactive
|
|
41
41
|
*/
|
|
42
42
|
class SentientOutpost {
|
|
43
|
-
constructor(data
|
|
43
|
+
constructor(data, {
|
|
44
44
|
translator, locale, sentientData, logger,
|
|
45
45
|
}) {
|
|
46
|
+
// eslint-disable-next-line no-param-reassign
|
|
47
|
+
if (!data) data = '{"sfn":000}';
|
|
46
48
|
const node = (data.match(/\d{3}/g) || ['000'])[0];
|
|
47
49
|
const id = `CrewBattleNode${node}`;
|
|
48
50
|
if (node === '000') {
|
package/lib/Sortie.js
CHANGED
|
@@ -78,6 +78,12 @@ class Sortie extends WorldstateObject {
|
|
|
78
78
|
*/
|
|
79
79
|
this.faction = translator.sortieFaction(data.Boss, locale);
|
|
80
80
|
|
|
81
|
+
/**
|
|
82
|
+
* The sortie's faction
|
|
83
|
+
* @type {string}
|
|
84
|
+
*/
|
|
85
|
+
this.factionKey = translator.sortieFaction(data.boss, 'en');
|
|
86
|
+
|
|
81
87
|
/**
|
|
82
88
|
* Whether or not this is expired (at time of object creation)
|
|
83
89
|
* @type {boolean}
|
package/lib/SteelPathOffering.js
CHANGED
|
@@ -15,7 +15,7 @@ function getFirstDayOfWeek() {
|
|
|
15
15
|
|
|
16
16
|
function getLastDayOfWeek() {
|
|
17
17
|
const last = new Date(getFirstDayOfWeek());
|
|
18
|
-
last.setUTCDate(last.getUTCDate() +
|
|
18
|
+
last.setUTCDate(last.getUTCDate() + 6);
|
|
19
19
|
last.setUTCHours(23);
|
|
20
20
|
last.setUTCMinutes(59);
|
|
21
21
|
last.setUTCSeconds(59);
|
package/lib/SyndicateJob.js
CHANGED
|
@@ -5,7 +5,7 @@ const fetch = require('node-fetch');
|
|
|
5
5
|
const WorldstateObject = require('./WorldstateObject');
|
|
6
6
|
|
|
7
7
|
const apiBase = process.env.API_BASE_URL || 'https://api.warframestat.us';
|
|
8
|
-
const bountyRewardRegex = /Tier([ABCDE])Table([ABC])Rewards/i;
|
|
8
|
+
const bountyRewardRegex = /(?:Tier([ABCDE])|Narmer)Table([ABC])Rewards/i;
|
|
9
9
|
const ghoulRewardRegex = /GhoulBountyTable([AB])Rewards/i;
|
|
10
10
|
|
|
11
11
|
/**
|
|
@@ -75,17 +75,20 @@ const getBountyRewards = async (i18n, isVault, raw) => {
|
|
|
75
75
|
return [];
|
|
76
76
|
};
|
|
77
77
|
|
|
78
|
+
const FIFTY_MINUTES = 3000000;
|
|
79
|
+
|
|
78
80
|
/**
|
|
79
81
|
* Represents a syndicate daily mission
|
|
80
82
|
* @extends {WorldstateObject}
|
|
81
83
|
*/
|
|
82
84
|
class SyndicateJob extends WorldstateObject {
|
|
83
85
|
/**
|
|
84
|
-
* @param
|
|
85
|
-
* @param
|
|
86
|
-
* @param
|
|
87
|
-
* @param
|
|
88
|
-
* @param
|
|
86
|
+
* @param {Object} data The syndicate mission data
|
|
87
|
+
* @param {Date} expiry The syndicate job expiration
|
|
88
|
+
* @param {Object} deps The dependencies object
|
|
89
|
+
* @param {Object} timeDate Time/Date functions
|
|
90
|
+
* @param {Translator} translator The string translator
|
|
91
|
+
* @param {string} locale Locale to use for translations
|
|
89
92
|
*/
|
|
90
93
|
constructor(data, expiry, { translator, timeDate, locale }) {
|
|
91
94
|
super({ _id: { $oid: data.JobCurrentVersion ? data.JobCurrentVersion.$oid : `${(data.jobType || '').split('/').slice(-1)[0]}${expiry.getTime()}` } }, { timeDate });
|
|
@@ -141,6 +144,27 @@ class SyndicateJob extends WorldstateObject {
|
|
|
141
144
|
* @type {string|null}
|
|
142
145
|
*/
|
|
143
146
|
this.locationTag = data.locationTag;
|
|
147
|
+
|
|
148
|
+
/**
|
|
149
|
+
* End time for the syndicate mission.
|
|
150
|
+
* Should be inherited from the Syndicate, but some are timebound.
|
|
151
|
+
* @type {Date}
|
|
152
|
+
*/
|
|
153
|
+
this.expiry = expiry;
|
|
154
|
+
|
|
155
|
+
/**
|
|
156
|
+
* What time phase this bounty is bound to
|
|
157
|
+
* @type {string}
|
|
158
|
+
*/
|
|
159
|
+
this.timeBound = undefined;
|
|
160
|
+
if (data.jobType && data.jobType.toLowerCase().includes('narmer')) {
|
|
161
|
+
if (data.jobType.toLowerCase().includes('eidolon')) {
|
|
162
|
+
this.timeBound = 'day';
|
|
163
|
+
this.expiry = new Date(this.expiry.getTime() - FIFTY_MINUTES);
|
|
164
|
+
} else {
|
|
165
|
+
this.timeBoound = 'night';
|
|
166
|
+
}
|
|
167
|
+
}
|
|
144
168
|
}
|
|
145
169
|
}
|
|
146
170
|
|
package/lib/SyndicateMission.js
CHANGED
|
@@ -67,6 +67,12 @@ class SyndicateMission extends WorldstateObject {
|
|
|
67
67
|
*/
|
|
68
68
|
this.syndicate = translator.syndicate(data.Tag, locale);
|
|
69
69
|
|
|
70
|
+
/**
|
|
71
|
+
* The syndicate that is offering the mission
|
|
72
|
+
* @type {string}
|
|
73
|
+
*/
|
|
74
|
+
this.syndicateKey = translator.syndicate(data.Tag, 'en');
|
|
75
|
+
|
|
70
76
|
/**
|
|
71
77
|
* The nodes on which the missions are taking place
|
|
72
78
|
* @type {Array.<string>}
|
package/lib/VoidTrader.js
CHANGED
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
const WorldstateObject = require('./WorldstateObject');
|
|
4
4
|
const VoidTraderItem = require('./VoidTraderItem');
|
|
5
|
+
const VoidTraderSchedule = require('./VoidTraderSchedule');
|
|
5
6
|
|
|
6
7
|
/**
|
|
7
8
|
* Represents a void trader
|
|
@@ -53,7 +54,7 @@ class VoidTrader extends WorldstateObject {
|
|
|
53
54
|
* The void trader's name
|
|
54
55
|
* @type {string}
|
|
55
56
|
*/
|
|
56
|
-
this.character = data.Character.replace('Baro\'Ki Teel', 'Baro Ki\'Teer');
|
|
57
|
+
this.character = data.Character ? data.Character.replace('Baro\'Ki Teel', 'Baro Ki\'Teer') : '';
|
|
57
58
|
|
|
58
59
|
/**
|
|
59
60
|
* The node at which the Void Trader appears
|
|
@@ -94,6 +95,13 @@ class VoidTrader extends WorldstateObject {
|
|
|
94
95
|
* @type {string}
|
|
95
96
|
*/
|
|
96
97
|
this.endString = this.getEndString();
|
|
98
|
+
|
|
99
|
+
this.initialStart = timeDate.parseDate(data.InitialStartDate);
|
|
100
|
+
this.completed = data.Completed;
|
|
101
|
+
this.schedule = data.ScheduleInfo
|
|
102
|
+
? data.ScheduleInfo
|
|
103
|
+
.map((i) => new VoidTraderSchedule(i, { timeDate, translator, locale }))
|
|
104
|
+
: [];
|
|
97
105
|
}
|
|
98
106
|
|
|
99
107
|
/**
|
package/lib/VoidTraderItem.js
CHANGED
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
*/
|
|
9
9
|
class VoidTraderItem {
|
|
10
10
|
/**
|
|
11
|
-
* @param {Object} data The
|
|
11
|
+
* @param {Object} data The void trader item data
|
|
12
12
|
* @param {string} data.ItemType Worldstate Item i18n path
|
|
13
13
|
* @param {string} data.PrimePrice Ducat cost of the item
|
|
14
14
|
* @param {string} data.RegularPrice Credit price of the item
|
package/lib/WorldState.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "warframe-worldstate-parser",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.23.1",
|
|
4
4
|
"description": "An Open parser for Warframe's Worldstate in Javascript",
|
|
5
5
|
"types": "./types/main.d.ts",
|
|
6
6
|
"main": "main.js",
|
|
@@ -8,8 +8,10 @@
|
|
|
8
8
|
"test": "test"
|
|
9
9
|
},
|
|
10
10
|
"dependencies": {
|
|
11
|
-
"node-fetch": "^2.6.1"
|
|
12
|
-
|
|
11
|
+
"node-fetch": "^2.6.1"
|
|
12
|
+
},
|
|
13
|
+
"peerDependencies": {
|
|
14
|
+
"warframe-worldstate-data": ">=1.0"
|
|
13
15
|
},
|
|
14
16
|
"devDependencies": {
|
|
15
17
|
"@types/chai": "^4.2.11",
|
|
@@ -18,15 +20,15 @@
|
|
|
18
20
|
"@types/sinon-chai": "^3.2.5",
|
|
19
21
|
"chai": "^4.2.0",
|
|
20
22
|
"coveralls": "^3.1.0",
|
|
21
|
-
"eslint": "^
|
|
22
|
-
"eslint-config-airbnb-base": "^
|
|
23
|
+
"eslint": "^8.2.0",
|
|
24
|
+
"eslint-config-airbnb-base": "^15.0.0",
|
|
23
25
|
"eslint-plugin-import": "^2.20.1",
|
|
24
26
|
"greenkeeper-lockfile": "^1.15.1",
|
|
25
27
|
"mocha": "^9.0.2",
|
|
26
28
|
"nyc": "^15.1.0",
|
|
27
29
|
"precommit-hook": "^3.0.0",
|
|
28
30
|
"rewire": "^5.0.0",
|
|
29
|
-
"sinon": "^
|
|
31
|
+
"sinon": "^12.0.1",
|
|
30
32
|
"sinon-chai": "^3.5.0",
|
|
31
33
|
"typescript": "^4.0.5"
|
|
32
34
|
},
|
|
@@ -131,5 +133,19 @@
|
|
|
131
133
|
"text"
|
|
132
134
|
],
|
|
133
135
|
"skip-full": true
|
|
136
|
+
},
|
|
137
|
+
"clean-package": {
|
|
138
|
+
"remove": [
|
|
139
|
+
"devDependencies",
|
|
140
|
+
"scripts",
|
|
141
|
+
"release",
|
|
142
|
+
"eslintIgnore",
|
|
143
|
+
"eslintConfig",
|
|
144
|
+
"pre-commit",
|
|
145
|
+
"nyc",
|
|
146
|
+
"mocha",
|
|
147
|
+
"clean-package",
|
|
148
|
+
"directories"
|
|
149
|
+
]
|
|
134
150
|
}
|
|
135
151
|
}
|
package/types/lib/Alert.d.ts
CHANGED
|
@@ -13,7 +13,7 @@ declare class Alert extends WorldstateObject {
|
|
|
13
13
|
* @param {Reward} Reward The Reward parser
|
|
14
14
|
* @param {string} locale Locale to use for translations
|
|
15
15
|
*/
|
|
16
|
-
constructor(data: any, { mdConfig, translator, timeDate, Mission, Reward, locale, }:
|
|
16
|
+
constructor(data: any, { mdConfig, translator, timeDate, Mission, Reward, locale, }: MarkdownSettings);
|
|
17
17
|
/**
|
|
18
18
|
* The markdown settings
|
|
19
19
|
* @type {MarkdownSettings}
|
|
@@ -24,7 +24,7 @@ declare class Alert extends WorldstateObject {
|
|
|
24
24
|
* The mission that the players have to complete
|
|
25
25
|
* @type {Mission}
|
|
26
26
|
*/
|
|
27
|
-
mission:
|
|
27
|
+
mission: MarkdownSettings;
|
|
28
28
|
/**
|
|
29
29
|
* ETA string (at time of object creation)
|
|
30
30
|
* @type {String}
|
|
@@ -49,7 +49,7 @@ declare class Alert extends WorldstateObject {
|
|
|
49
49
|
* Get the alert's reward
|
|
50
50
|
* @returns {Reward}
|
|
51
51
|
*/
|
|
52
|
-
getReward():
|
|
52
|
+
getReward(): Reward;
|
|
53
53
|
/**
|
|
54
54
|
* Get a string indicating how much time is left before the alert expires
|
|
55
55
|
* @returns {string}
|
|
@@ -11,8 +11,8 @@ declare class CetusCycle extends WorldstateObject {
|
|
|
11
11
|
* @param {TimeDateFunctions} deps.timeDate The time and date functions
|
|
12
12
|
*/
|
|
13
13
|
constructor(bountiesEndDate: Date, { mdConfig, timeDate }: {
|
|
14
|
-
mdConfig:
|
|
15
|
-
timeDate:
|
|
14
|
+
mdConfig: MarkdownSettings;
|
|
15
|
+
timeDate: TimeDateFunctions;
|
|
16
16
|
});
|
|
17
17
|
/**
|
|
18
18
|
* The markdown settings
|
|
@@ -9,7 +9,7 @@ declare class ChallengeInstance {
|
|
|
9
9
|
* @param {Translator} deps.translator The string translator
|
|
10
10
|
* @param {string} deps.locale Locale to use for translations
|
|
11
11
|
*/
|
|
12
|
-
constructor(data: any, { translator, locale }:
|
|
12
|
+
constructor(data: any, { translator, locale }: Dependency);
|
|
13
13
|
/**
|
|
14
14
|
* Type of challenge
|
|
15
15
|
* @type {string}
|
|
@@ -13,9 +13,9 @@ declare class ConclaveChallenge extends WorldstateObject {
|
|
|
13
13
|
* @param {string} deps.locale Locale to use for translations
|
|
14
14
|
*/
|
|
15
15
|
constructor(data: any, { mdConfig, translator, timeDate, locale, }: {
|
|
16
|
-
mdConfig:
|
|
17
|
-
translator:
|
|
18
|
-
timeDate:
|
|
16
|
+
mdConfig: MarkdownSettings;
|
|
17
|
+
translator: Translator;
|
|
18
|
+
timeDate: TimeDateFunctions;
|
|
19
19
|
locale: string;
|
|
20
20
|
});
|
|
21
21
|
/**
|
|
@@ -10,7 +10,7 @@ declare class ConstructionProgress extends WorldstateObject {
|
|
|
10
10
|
* @param {MarkdownSettings} deps.mdConfig The markdown settings
|
|
11
11
|
*/
|
|
12
12
|
constructor(data: any, { mdConfig, timeDate }: {
|
|
13
|
-
mdConfig:
|
|
13
|
+
mdConfig: MarkdownSettings;
|
|
14
14
|
});
|
|
15
15
|
/**
|
|
16
16
|
* The markdown settings
|
package/types/lib/DailyDeal.d.ts
CHANGED
|
@@ -12,9 +12,9 @@ declare class DailyDeal {
|
|
|
12
12
|
* @param {string} deps.locale Locale to use for translations
|
|
13
13
|
*/
|
|
14
14
|
constructor(data: any, { mdConfig, translator, timeDate, locale, }: {
|
|
15
|
-
mdConfig:
|
|
16
|
-
translator:
|
|
17
|
-
timeDate:
|
|
15
|
+
mdConfig: MarkdownSettings;
|
|
16
|
+
translator: Translator;
|
|
17
|
+
timeDate: TimeDateFunctions;
|
|
18
18
|
locale: string;
|
|
19
19
|
});
|
|
20
20
|
/**
|
|
@@ -16,12 +16,12 @@ declare class DarkSector extends WorldstateObject {
|
|
|
16
16
|
* @param {string} deps.locale Locale to use for translations
|
|
17
17
|
*/
|
|
18
18
|
constructor(data: any, { mdConfig, translator, timeDate, Mission, DarkSectorBattle, Reward, locale, }: {
|
|
19
|
-
mdConfig:
|
|
20
|
-
translator:
|
|
21
|
-
timeDate:
|
|
22
|
-
Mission:
|
|
23
|
-
DarkSectorBattle:
|
|
24
|
-
Reward:
|
|
19
|
+
mdConfig: MarkdownSettings;
|
|
20
|
+
translator: Translator;
|
|
21
|
+
timeDate: TimeDateFunctions;
|
|
22
|
+
Mission: Mission;
|
|
23
|
+
DarkSectorBattle: DarkSectorBattle;
|
|
24
|
+
Reward: Reward;
|
|
25
25
|
locale: string;
|
|
26
26
|
});
|
|
27
27
|
/**
|
|
@@ -96,7 +96,7 @@ declare class DarkSector extends WorldstateObject {
|
|
|
96
96
|
* The dark sector's mission
|
|
97
97
|
* @type {?Mission}
|
|
98
98
|
*/
|
|
99
|
-
mission:
|
|
99
|
+
mission: Mission;
|
|
100
100
|
battlePayReserve: any;
|
|
101
101
|
/**
|
|
102
102
|
* The battle pay per mission offered to players
|
|
@@ -127,6 +127,6 @@ declare class DarkSector extends WorldstateObject {
|
|
|
127
127
|
* The history of the dark sector
|
|
128
128
|
* @type {Array.<DarkSectorBattle>}
|
|
129
129
|
*/
|
|
130
|
-
history: Array<
|
|
130
|
+
history: Array<DarkSectorBattle>;
|
|
131
131
|
}
|
|
132
132
|
import WorldstateObject = require("./WorldstateObject");
|
package/types/lib/Fissure.d.ts
CHANGED
|
@@ -12,8 +12,8 @@ declare class Fissure extends WorldstateObject {
|
|
|
12
12
|
* @param {string} deps.locale Locale to use for translations
|
|
13
13
|
*/
|
|
14
14
|
constructor(data: any, { translator, timeDate, locale }: {
|
|
15
|
-
translator:
|
|
16
|
-
timeDate:
|
|
15
|
+
translator: Translator;
|
|
16
|
+
timeDate: TimeDateFunctions;
|
|
17
17
|
locale: string;
|
|
18
18
|
});
|
|
19
19
|
/**
|
package/types/lib/FlashSale.d.ts
CHANGED
|
@@ -12,9 +12,9 @@ declare class FlashSale {
|
|
|
12
12
|
* @param {string} deps.locale Locale to use for translations
|
|
13
13
|
*/
|
|
14
14
|
constructor(data: any, { translator, mdConfig, timeDate, locale, }: {
|
|
15
|
-
mdConfig:
|
|
16
|
-
translator:
|
|
17
|
-
timeDate:
|
|
15
|
+
mdConfig: MarkdownSettings;
|
|
16
|
+
translator: Translator;
|
|
17
|
+
timeDate: TimeDateFunctions;
|
|
18
18
|
locale: string;
|
|
19
19
|
});
|
|
20
20
|
/**
|
|
@@ -12,9 +12,9 @@ declare class GlobalUpgrade {
|
|
|
12
12
|
* @param {string} deps.locale Locale to use for translations
|
|
13
13
|
*/
|
|
14
14
|
constructor(data: any, { translator, timeDate, mdConfig, locale, }: {
|
|
15
|
-
translator:
|
|
16
|
-
timeDate:
|
|
17
|
-
mdConfig:
|
|
15
|
+
translator: Translator;
|
|
16
|
+
timeDate: TimeDateFunctions;
|
|
17
|
+
mdConfig: MarkdownSettings;
|
|
18
18
|
locale: string;
|
|
19
19
|
});
|
|
20
20
|
/**
|
package/types/lib/Invasion.d.ts
CHANGED
|
@@ -20,10 +20,10 @@ declare class Invasion extends WorldstateObject {
|
|
|
20
20
|
* @param {string} deps.locale Locale to use for translations
|
|
21
21
|
*/
|
|
22
22
|
constructor(data: any, { mdConfig, translator, timeDate, Reward, locale, }: {
|
|
23
|
-
mdConfig:
|
|
24
|
-
translator:
|
|
25
|
-
timeDate:
|
|
26
|
-
Reward:
|
|
23
|
+
mdConfig: MarkdownSettings;
|
|
24
|
+
translator: Translator;
|
|
25
|
+
timeDate: TimeDateFunctions;
|
|
26
|
+
Reward: Reward;
|
|
27
27
|
locale: string;
|
|
28
28
|
});
|
|
29
29
|
/**
|
|
@@ -51,7 +51,7 @@ declare class Invasion extends WorldstateObject {
|
|
|
51
51
|
* The attacker's reward
|
|
52
52
|
* @type {Reward}
|
|
53
53
|
*/
|
|
54
|
-
attackerReward:
|
|
54
|
+
attackerReward: Reward;
|
|
55
55
|
/**
|
|
56
56
|
* The attacking faction
|
|
57
57
|
* @type {string}
|
|
@@ -66,7 +66,7 @@ declare class Invasion extends WorldstateObject {
|
|
|
66
66
|
* The defender's reward
|
|
67
67
|
* @type {Reward}
|
|
68
68
|
*/
|
|
69
|
-
defenderReward:
|
|
69
|
+
defenderReward: Reward;
|
|
70
70
|
/**
|
|
71
71
|
* The defending faction
|
|
72
72
|
* @type {string}
|
|
@@ -76,7 +76,7 @@ declare class Invasion extends WorldstateObject {
|
|
|
76
76
|
* Invasion defender
|
|
77
77
|
* @type {Partipant}
|
|
78
78
|
*/
|
|
79
|
-
defender:
|
|
79
|
+
defender: Partipant;
|
|
80
80
|
/**
|
|
81
81
|
* Whether this invasion is against the infestation
|
|
82
82
|
* @type {boolean}
|
package/types/lib/Mission.d.ts
CHANGED
|
@@ -12,9 +12,9 @@ declare class Mission {
|
|
|
12
12
|
* @param {string} deps.locale Locale to use for translations
|
|
13
13
|
*/
|
|
14
14
|
constructor(data: any, { mdConfig, translator, Reward, locale, }: {
|
|
15
|
-
mdConfig:
|
|
16
|
-
translator:
|
|
17
|
-
Reward:
|
|
15
|
+
mdConfig: MarkdownSettings;
|
|
16
|
+
translator: Translator;
|
|
17
|
+
Reward: Reward;
|
|
18
18
|
locale: string;
|
|
19
19
|
});
|
|
20
20
|
/**
|
|
@@ -47,7 +47,7 @@ declare class Mission {
|
|
|
47
47
|
* The mission's reward
|
|
48
48
|
* @type {?Reward}
|
|
49
49
|
*/
|
|
50
|
-
reward:
|
|
50
|
+
reward: Reward;
|
|
51
51
|
/**
|
|
52
52
|
* The minimum level of the enemies in the mission
|
|
53
53
|
* @type {number}
|
package/types/lib/News.d.ts
CHANGED
|
@@ -11,7 +11,7 @@ declare class News extends WorldstateObject {
|
|
|
11
11
|
* @param {TimeDateFunctions} deps.timeDate The time and date functions
|
|
12
12
|
* @param {locale} deps.locale Locale to use for determining language
|
|
13
13
|
*/
|
|
14
|
-
constructor(data: any, { mdConfig, timeDate, locale }:
|
|
14
|
+
constructor(data: any, { mdConfig, timeDate, locale }: Dependency);
|
|
15
15
|
/**
|
|
16
16
|
* The markdown settings
|
|
17
17
|
* @type {MarkdownSettings}
|
package/types/lib/Nightwave.d.ts
CHANGED
|
@@ -15,11 +15,11 @@ declare class Nightwave extends WorldstateObject {
|
|
|
15
15
|
* @param {string} deps.locale Locale to use for translations
|
|
16
16
|
*/
|
|
17
17
|
constructor(data: any, { mdConfig, translator, timeDate, Mission, Reward, locale, }: {
|
|
18
|
-
mdConfig:
|
|
19
|
-
translator:
|
|
20
|
-
timeDate:
|
|
21
|
-
Mission:
|
|
22
|
-
Reward:
|
|
18
|
+
mdConfig: MarkdownSettings;
|
|
19
|
+
translator: Translator;
|
|
20
|
+
timeDate: TimeDateFunctions;
|
|
21
|
+
Mission: Mission;
|
|
22
|
+
Reward: Reward;
|
|
23
23
|
locale: string;
|
|
24
24
|
});
|
|
25
25
|
/**
|
|
@@ -12,8 +12,8 @@ declare class NightwaveChallenge extends WorldstateObject {
|
|
|
12
12
|
* @param {string} deps.locale Locale to use for translations
|
|
13
13
|
*/
|
|
14
14
|
constructor(data: any, { translator, timeDate, locale, }: {
|
|
15
|
-
translator:
|
|
16
|
-
timeDate:
|
|
15
|
+
translator: Translator;
|
|
16
|
+
timeDate: TimeDateFunctions;
|
|
17
17
|
locale: string;
|
|
18
18
|
});
|
|
19
19
|
/**
|
|
@@ -12,8 +12,8 @@ declare class PersistentEnemy extends WorldstateObject {
|
|
|
12
12
|
* @param {string} deps.locale Locale to use for translations
|
|
13
13
|
*/
|
|
14
14
|
constructor(data: any, { mdConfig, translator, timeDate, locale, }: {
|
|
15
|
-
mdConfig:
|
|
16
|
-
translator:
|
|
15
|
+
mdConfig: MarkdownSettings;
|
|
16
|
+
translator: Translator;
|
|
17
17
|
locale: string;
|
|
18
18
|
});
|
|
19
19
|
/**
|
package/types/lib/Reward.d.ts
CHANGED
|
@@ -20,7 +20,7 @@ export = SentientOutpost;
|
|
|
20
20
|
* @property {Date} previous.expiry When the mission became or becomes inactive
|
|
21
21
|
*/
|
|
22
22
|
declare class SentientOutpost {
|
|
23
|
-
constructor(data:
|
|
23
|
+
constructor(data: any, { translator, locale, sentientData, logger, }: {
|
|
24
24
|
translator: any;
|
|
25
25
|
locale: any;
|
|
26
26
|
sentientData: any;
|
package/types/lib/Simaris.d.ts
CHANGED
|
@@ -11,8 +11,8 @@ declare class Simaris {
|
|
|
11
11
|
* @param {string} deps.locale Locale to use for translations
|
|
12
12
|
*/
|
|
13
13
|
constructor(data: any, { mdConfig, translator, locale }: {
|
|
14
|
-
mdConfig:
|
|
15
|
-
translator:
|
|
14
|
+
mdConfig: MarkdownSettings;
|
|
15
|
+
translator: Translator;
|
|
16
16
|
locale: string;
|
|
17
17
|
});
|
|
18
18
|
/**
|
package/types/lib/Sortie.d.ts
CHANGED
|
@@ -15,11 +15,11 @@ declare class Sortie extends WorldstateObject {
|
|
|
15
15
|
* @param {string} deps.locale Locale to use for translations
|
|
16
16
|
*/
|
|
17
17
|
constructor(data: any, { mdConfig, translator, timeDate, sortieData, SortieVariant, locale, }: {
|
|
18
|
-
mdConfig:
|
|
19
|
-
translator:
|
|
20
|
-
timeDate:
|
|
18
|
+
mdConfig: MarkdownSettings;
|
|
19
|
+
translator: Translator;
|
|
20
|
+
timeDate: TimeDateFunctions;
|
|
21
21
|
sortieData: any;
|
|
22
|
-
SortieVariant:
|
|
22
|
+
SortieVariant: SortieVariant;
|
|
23
23
|
locale: string;
|
|
24
24
|
});
|
|
25
25
|
/**
|
|
@@ -37,7 +37,7 @@ declare class Sortie extends WorldstateObject {
|
|
|
37
37
|
* The sortie's variants
|
|
38
38
|
* @type {Array.<SortieVariant>}
|
|
39
39
|
*/
|
|
40
|
-
variants: Array<
|
|
40
|
+
variants: Array<SortieVariant>;
|
|
41
41
|
/**
|
|
42
42
|
* The sortie's boss
|
|
43
43
|
* @type {string}
|
|
@@ -48,6 +48,11 @@ declare class Sortie extends WorldstateObject {
|
|
|
48
48
|
* @type {string}
|
|
49
49
|
*/
|
|
50
50
|
faction: string;
|
|
51
|
+
/**
|
|
52
|
+
* The sortie's faction
|
|
53
|
+
* @type {string}
|
|
54
|
+
*/
|
|
55
|
+
factionKey: string;
|
|
51
56
|
/**
|
|
52
57
|
* Whether or not this is expired (at time of object creation)
|
|
53
58
|
* @type {boolean}
|
|
@@ -12,8 +12,8 @@ declare class SortieVariant {
|
|
|
12
12
|
* @param {string} deps.locale Locale to use for translations
|
|
13
13
|
*/
|
|
14
14
|
constructor(data: any, { mdConfig, translator, locale, }: {
|
|
15
|
-
mdConfig:
|
|
16
|
-
translator:
|
|
15
|
+
mdConfig: MarkdownSettings;
|
|
16
|
+
translator: Translator;
|
|
17
17
|
sortieData: any;
|
|
18
18
|
locale: string;
|
|
19
19
|
});
|
|
@@ -5,16 +5,14 @@ export = SyndicateJob;
|
|
|
5
5
|
*/
|
|
6
6
|
declare class SyndicateJob extends WorldstateObject {
|
|
7
7
|
/**
|
|
8
|
-
* @param
|
|
9
|
-
* @param
|
|
10
|
-
* @param
|
|
11
|
-
* @param
|
|
12
|
-
* @param
|
|
8
|
+
* @param {Object} data The syndicate mission data
|
|
9
|
+
* @param {Date} expiry The syndicate job expiration
|
|
10
|
+
* @param {Object} deps The dependencies object
|
|
11
|
+
* @param {Object} timeDate Time/Date functions
|
|
12
|
+
* @param {Translator} translator The string translator
|
|
13
|
+
* @param {string} locale Locale to use for translations
|
|
13
14
|
*/
|
|
14
|
-
constructor(data: any, expiry: Date, { translator, timeDate, locale }:
|
|
15
|
-
translator: any;
|
|
16
|
-
locale: string;
|
|
17
|
-
});
|
|
15
|
+
constructor(data: any, expiry: Date, { translator, timeDate, locale }: any);
|
|
18
16
|
/**
|
|
19
17
|
* Array of strings describing rewards
|
|
20
18
|
* @type {Array.<String>}
|
|
@@ -51,5 +49,11 @@ declare class SyndicateJob extends WorldstateObject {
|
|
|
51
49
|
* @type {string|null}
|
|
52
50
|
*/
|
|
53
51
|
locationTag: string | null;
|
|
52
|
+
/**
|
|
53
|
+
* What time phase this bounty is bound to
|
|
54
|
+
* @type {string}
|
|
55
|
+
*/
|
|
56
|
+
timeBound: string;
|
|
57
|
+
timeBoound: string;
|
|
54
58
|
}
|
|
55
59
|
import WorldstateObject = require("./WorldstateObject");
|
|
@@ -13,9 +13,9 @@ declare class SyndicateMission extends WorldstateObject {
|
|
|
13
13
|
* @param {string} deps.locale Locale to use for translations
|
|
14
14
|
*/
|
|
15
15
|
constructor(data: any, { mdConfig, translator, timeDate, locale, }: {
|
|
16
|
-
mdConfig:
|
|
17
|
-
translator:
|
|
18
|
-
timeDate:
|
|
16
|
+
mdConfig: MarkdownSettings;
|
|
17
|
+
translator: Translator;
|
|
18
|
+
timeDate: TimeDateFunctions;
|
|
19
19
|
locale: string;
|
|
20
20
|
});
|
|
21
21
|
/**
|
|
@@ -35,6 +35,11 @@ declare class SyndicateMission extends WorldstateObject {
|
|
|
35
35
|
* @type {string}
|
|
36
36
|
*/
|
|
37
37
|
syndicate: string;
|
|
38
|
+
/**
|
|
39
|
+
* The syndicate that is offering the mission
|
|
40
|
+
* @type {string}
|
|
41
|
+
*/
|
|
42
|
+
syndicateKey: string;
|
|
38
43
|
/**
|
|
39
44
|
* The nodes on which the missions are taking place
|
|
40
45
|
* @type {Array.<string>}
|
|
@@ -13,9 +13,9 @@ declare class VoidTrader extends WorldstateObject {
|
|
|
13
13
|
* @param {string} deps.locale Locale to use for translations
|
|
14
14
|
*/
|
|
15
15
|
constructor(data: any, { mdConfig, translator, timeDate, locale, }: {
|
|
16
|
-
mdConfig:
|
|
17
|
-
translator:
|
|
18
|
-
timeDate:
|
|
16
|
+
mdConfig: MarkdownSettings;
|
|
17
|
+
translator: Translator;
|
|
18
|
+
timeDate: TimeDateFunctions;
|
|
19
19
|
locale: string;
|
|
20
20
|
});
|
|
21
21
|
/**
|
|
@@ -50,6 +50,9 @@ declare class VoidTrader extends WorldstateObject {
|
|
|
50
50
|
* @type {string}
|
|
51
51
|
*/
|
|
52
52
|
endString: string;
|
|
53
|
+
initialStart: any;
|
|
54
|
+
completed: any;
|
|
55
|
+
schedule: any;
|
|
53
56
|
}
|
|
54
57
|
import WorldstateObject = require("./WorldstateObject");
|
|
55
58
|
import VoidTraderItem = require("./VoidTraderItem");
|
|
@@ -7,7 +7,7 @@ export = VoidTraderItem;
|
|
|
7
7
|
*/
|
|
8
8
|
declare class VoidTraderItem {
|
|
9
9
|
/**
|
|
10
|
-
* @param {Object} data The
|
|
10
|
+
* @param {Object} data The void trader item data
|
|
11
11
|
* @param {string} data.ItemType Worldstate Item i18n path
|
|
12
12
|
* @param {string} data.PrimePrice Ducat cost of the item
|
|
13
13
|
* @param {string} data.RegularPrice Credit price of the item
|
|
@@ -19,7 +19,7 @@ declare class VoidTraderItem {
|
|
|
19
19
|
ItemType: string;
|
|
20
20
|
PrimePrice: string;
|
|
21
21
|
RegularPrice: string;
|
|
22
|
-
}, { translator, locale }:
|
|
22
|
+
}, { translator, locale }: Dependency);
|
|
23
23
|
item: any;
|
|
24
24
|
ducats: number;
|
|
25
25
|
credits: number;
|
|
@@ -12,9 +12,9 @@ declare class WeeklyChallenge extends WorldstateObject {
|
|
|
12
12
|
* @param {TimeDateFunctions} deps.timeDate The time and date functions
|
|
13
13
|
*/
|
|
14
14
|
constructor(data: any, { timeDate, translator }: {
|
|
15
|
-
mdConfig:
|
|
16
|
-
translator:
|
|
17
|
-
timeDate:
|
|
15
|
+
mdConfig: MarkdownSettings;
|
|
16
|
+
translator: Translator;
|
|
17
|
+
timeDate: TimeDateFunctions;
|
|
18
18
|
});
|
|
19
19
|
challenges: any;
|
|
20
20
|
}
|
|
@@ -31,10 +31,10 @@ declare class WorldEvent extends WorldstateObject {
|
|
|
31
31
|
* @param {string} deps.locale Locale to use for translations
|
|
32
32
|
*/
|
|
33
33
|
constructor(data: any, { mdConfig, translator, timeDate, Reward, locale, }: {
|
|
34
|
-
mdConfig:
|
|
35
|
-
translator:
|
|
36
|
-
timeDate:
|
|
37
|
-
Reward:
|
|
34
|
+
mdConfig: MarkdownSettings;
|
|
35
|
+
translator: Translator;
|
|
36
|
+
timeDate: TimeDateFunctions;
|
|
37
|
+
Reward: Reward;
|
|
38
38
|
locale: string;
|
|
39
39
|
});
|
|
40
40
|
/**
|
|
@@ -102,7 +102,7 @@ declare class WorldEvent extends WorldstateObject {
|
|
|
102
102
|
* The event's rewards
|
|
103
103
|
* @type {Reward[]}
|
|
104
104
|
*/
|
|
105
|
-
rewards:
|
|
105
|
+
rewards: Reward[];
|
|
106
106
|
/**
|
|
107
107
|
* Whether or not this is expired (at time of object creation)
|
|
108
108
|
* @type {boolean}
|
|
@@ -130,7 +130,7 @@ declare class WorldEvent extends WorldstateObject {
|
|
|
130
130
|
* Progress Steps, if any are present
|
|
131
131
|
* @type {ProgessStep[]}
|
|
132
132
|
*/
|
|
133
|
-
progressSteps:
|
|
133
|
+
progressSteps: ProgessStep[];
|
|
134
134
|
/**
|
|
135
135
|
* Total of all MultiProgress
|
|
136
136
|
* @type {Number}
|
|
@@ -200,7 +200,7 @@ type InterimStep = {
|
|
|
200
200
|
/**
|
|
201
201
|
* Reward for reaching the step
|
|
202
202
|
*/
|
|
203
|
-
reward:
|
|
203
|
+
reward: Reward;
|
|
204
204
|
/**
|
|
205
205
|
* Amount of players at this step
|
|
206
206
|
*/
|