@wise-old-man/utils 2.0.11 → 2.0.13
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/dist/index.d.ts +5 -0
- package/dist/index.js +9 -2
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -1972,6 +1972,11 @@ declare class PlayersClient extends BaseAPIClient {
|
|
|
1972
1972
|
* @returns The player's details, including the latest snapshot.
|
|
1973
1973
|
*/
|
|
1974
1974
|
getPlayerDetails(username: string): Promise<PlayerDetails>;
|
|
1975
|
+
/**
|
|
1976
|
+
* Fetches a player's details by ID.
|
|
1977
|
+
* @returns The player's details, including the latest snapshot.
|
|
1978
|
+
*/
|
|
1979
|
+
getPlayerDetailsById(id: number): Promise<PlayerDetails>;
|
|
1975
1980
|
/**
|
|
1976
1981
|
* Fetches a player's current achievements.
|
|
1977
1982
|
* @returns A list of achievements.
|
package/dist/index.js
CHANGED
|
@@ -338,6 +338,13 @@ class PlayersClient extends BaseAPIClient {
|
|
|
338
338
|
getPlayerDetails(username) {
|
|
339
339
|
return this.getRequest(`/players/${username}`);
|
|
340
340
|
}
|
|
341
|
+
/**
|
|
342
|
+
* Fetches a player's details by ID.
|
|
343
|
+
* @returns The player's details, including the latest snapshot.
|
|
344
|
+
*/
|
|
345
|
+
getPlayerDetailsById(id) {
|
|
346
|
+
return this.getRequest(`/players/id/${id}`);
|
|
347
|
+
}
|
|
341
348
|
/**
|
|
342
349
|
* Fetches a player's current achievements.
|
|
343
350
|
* @returns A list of achievements.
|
|
@@ -1835,7 +1842,7 @@ const BossProps = lodash.mapValues({
|
|
|
1835
1842
|
[Boss.NIGHTMARE]: { name: 'Nightmare' },
|
|
1836
1843
|
[Boss.PHOSANIS_NIGHTMARE]: { name: "Phosani's Nightmare" },
|
|
1837
1844
|
[Boss.OBOR]: { name: 'Obor', minimumValue: 5, isMembers: false },
|
|
1838
|
-
[Boss.PHANTOM_MUSPAH]: { name: 'Phantom Muspah'
|
|
1845
|
+
[Boss.PHANTOM_MUSPAH]: { name: 'Phantom Muspah' },
|
|
1839
1846
|
[Boss.SARACHNIS]: { name: 'Sarachnis' },
|
|
1840
1847
|
[Boss.SKOTIZO]: { name: 'Skotizo', minimumValue: 5 },
|
|
1841
1848
|
[Boss.SCORPIA]: { name: 'Scorpia' },
|
|
@@ -1855,7 +1862,7 @@ const BossProps = lodash.mapValues({
|
|
|
1855
1862
|
[Boss.WINTERTODT]: { name: 'Wintertodt' },
|
|
1856
1863
|
[Boss.ZALCANO]: { name: 'Zalcano' },
|
|
1857
1864
|
[Boss.ZULRAH]: { name: 'Zulrah' }
|
|
1858
|
-
}, props => (Object.assign(Object.assign({}, props), { type: exports.MetricType.BOSS, measure: exports.MetricMeasure.KILLS, isMembers: 'isMembers' in props ? props.isMembers : true, minimumValue: 'minimumValue' in props ? props.minimumValue :
|
|
1865
|
+
}, props => (Object.assign(Object.assign({}, props), { type: exports.MetricType.BOSS, measure: exports.MetricMeasure.KILLS, isMembers: 'isMembers' in props ? props.isMembers : true, minimumValue: 'minimumValue' in props ? props.minimumValue : 45 })));
|
|
1859
1866
|
const ActivityProps = lodash.mapValues({
|
|
1860
1867
|
[Activity.LEAGUE_POINTS]: { name: 'League Points' },
|
|
1861
1868
|
[Activity.BOUNTY_HUNTER_HUNTER]: { name: 'Bounty Hunter (Hunter)' },
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wise-old-man/utils",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.13",
|
|
4
4
|
"description": "A JavaScript/TypeScript client that interfaces and consumes the Wise Old Man API, an API that tracks and measures players' progress in Old School Runescape.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"wiseoldman",
|