mirror of
https://github.com/maxswa/osrs-json-hiscores.git
synced 2025-10-15 10:19:04 +00:00
Compare commits
26 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
cc9aae8ced | ||
|
|
12882b4e34 | ||
|
|
b17a8b9299 | ||
|
|
50f2c19257 | ||
|
|
d892f8e67b | ||
|
|
af5664ae6e | ||
|
|
20c5c2f730 | ||
|
|
04e59cff04 | ||
|
|
ad2249ba76 | ||
|
|
5c52bfd883 | ||
|
|
947d994cdf | ||
|
|
130446ab74 | ||
|
|
f96e7e3e2d | ||
|
|
90d66b6b2c | ||
|
|
14cedb5877 | ||
|
|
4703812b52 | ||
|
|
a11ac96f68 | ||
|
|
f97caa6a15 | ||
|
|
e7e54741d2 | ||
|
|
062e5e02b2 | ||
|
|
ed7036f9c0 | ||
|
|
74aba3e818 | ||
|
|
09fe7ed539 | ||
|
|
7a78e1ea0a | ||
|
|
7a4163aed2 | ||
|
|
85464d02fe |
1
.gitattributes
vendored
Normal file
1
.gitattributes
vendored
Normal file
@@ -0,0 +1 @@
|
|||||||
|
*.html linguist-vendored
|
||||||
96
README.md
96
README.md
@@ -3,6 +3,7 @@
|
|||||||
[](https://www.npmjs.com/package/osrs-json-hiscores)
|
[](https://www.npmjs.com/package/osrs-json-hiscores)
|
||||||
[](https://npm-stat.com/charts.html?package=osrs-json-hiscores)
|
[](https://npm-stat.com/charts.html?package=osrs-json-hiscores)
|
||||||
[](https://github.com/maxswa/osrs-json-hiscores/blob/master/src/types.ts)
|
[](https://github.com/maxswa/osrs-json-hiscores/blob/master/src/types.ts)
|
||||||
|
[](https://github.com/maxswa/osrs-json-hiscores/actions/workflows/main.yml?query=branch%3Amain)
|
||||||
|
|
||||||
**The Old School Runescape API wrapper that does more!**
|
**The Old School Runescape API wrapper that does more!**
|
||||||
|
|
||||||
@@ -118,53 +119,54 @@ Activities consist of all levels of clue scrolls as well as minigames and bosses
|
|||||||
|
|
||||||
### Bosses
|
### Bosses
|
||||||
|
|
||||||
| Boss Name | Param |
|
| Boss Name | Param |
|
||||||
| -------------------------------- | :----------------------------: |
|
| --------------------------------- | :----------------------------: |
|
||||||
| Abyssal Sire | `abyssalSire` |
|
| Abyssal Sire | `abyssalSire` |
|
||||||
| Alchemical Hydra | `alchemicalHydra` |
|
| Alchemical Hydra | `alchemicalHydra` |
|
||||||
| Barrows Chests | `barrows` |
|
| Barrows Chests | `barrows` |
|
||||||
| Bryophyta | `bryophyta` |
|
| Bryophyta | `bryophyta` |
|
||||||
| Callisto | `callisto` |
|
| Callisto | `callisto` |
|
||||||
| Cerberus | `cerberus` |
|
| Cerberus | `cerberus` |
|
||||||
| Chambers Of Xeric | `chambersOfXeric` |
|
| Chambers Of Xeric | `chambersOfXeric` |
|
||||||
| Chambers Of Xeric Challenge Mode | `chambersOfXericChallengeMode` |
|
| Chambers Of Xeric: Challenge Mode | `chambersOfXericChallengeMode` |
|
||||||
| Chaos Elemental | `chaosElemental` |
|
| Chaos Elemental | `chaosElemental` |
|
||||||
| Chaos Fanatic | `chaosFanatic` |
|
| Chaos Fanatic | `chaosFanatic` |
|
||||||
| Commander Zilyana | `commanderZilyana` |
|
| Commander Zilyana | `commanderZilyana` |
|
||||||
| Corporeal Beast | `corporealBeast` |
|
| Corporeal Beast | `corporealBeast` |
|
||||||
| Crazy Archaeologist | `crazyArchaeologist` |
|
| Crazy Archaeologist | `crazyArchaeologist` |
|
||||||
| Dagannoth Prime | `dagannothPrime` |
|
| Dagannoth Prime | `dagannothPrime` |
|
||||||
| Dagannoth Rex | `dagannothRex` |
|
| Dagannoth Rex | `dagannothRex` |
|
||||||
| Dagannoth Supreme | `dagannothSupreme` |
|
| Dagannoth Supreme | `dagannothSupreme` |
|
||||||
| Deranged Archaeologist | `derangedArchaeologist` |
|
| Deranged Archaeologist | `derangedArchaeologist` |
|
||||||
| General Graardor | `generalGraardor` |
|
| General Graardor | `generalGraardor` |
|
||||||
| Giant Mole | `giantMole` |
|
| Giant Mole | `giantMole` |
|
||||||
| Grotesque Guardians | `grotesqueGuardians` |
|
| Grotesque Guardians | `grotesqueGuardians` |
|
||||||
| Hespori | `hespori` |
|
| Hespori | `hespori` |
|
||||||
| Kalphite Queen | `kalphiteQueen` |
|
| Kalphite Queen | `kalphiteQueen` |
|
||||||
| King Black Dragon | `kingBlackDragon` |
|
| King Black Dragon | `kingBlackDragon` |
|
||||||
| Kraken | `kraken` |
|
| Kraken | `kraken` |
|
||||||
| Kreearra | `kreeArra` |
|
| Kreearra | `kreeArra` |
|
||||||
| K'ril Tsutsaroth | `krilTsutsaroth` |
|
| K'ril Tsutsaroth | `krilTsutsaroth` |
|
||||||
| Mimic | `mimic` |
|
| Mimic | `mimic` |
|
||||||
| The Nightmare of Ashihama | `nightmare` |
|
| The Nightmare of Ashihama | `nightmare` |
|
||||||
| Obor | `obor` |
|
| Obor | `obor` |
|
||||||
| Sarachnis | `sarachnis` |
|
| Sarachnis | `sarachnis` |
|
||||||
| Scorpia | `scorpia` |
|
| Scorpia | `scorpia` |
|
||||||
| Skotizo | `skotizo` |
|
| Skotizo | `skotizo` |
|
||||||
| Tempoross | `tempoross` |
|
| Tempoross | `tempoross` |
|
||||||
| Gauntlet | `gauntlet` |
|
| The Gauntlet | `gauntlet` |
|
||||||
| Corrupted Gauntlet | `corruptedGauntlet` |
|
| The Corrupted Gauntlet | `corruptedGauntlet` |
|
||||||
| Theatre Of Blood | `theatreOfBlood` |
|
| Theatre Of Blood | `theatreOfBlood` |
|
||||||
| Thermonuclear Smoke Devil | `thermonuclearSmokeDevil` |
|
| Theatre Of Blood: Hard Mode | `theatreOfBloodHardMode` |
|
||||||
| TzKal-Zuk | `tzKalZuk` |
|
| Thermonuclear Smoke Devil | `thermonuclearSmokeDevil` |
|
||||||
| TzTok-Jad | `tzTokJad` |
|
| TzKal-Zuk | `tzKalZuk` |
|
||||||
| Venenatis | `venenatis` |
|
| TzTok-Jad | `tzTokJad` |
|
||||||
| Vetion | `vetion` |
|
| Venenatis | `venenatis` |
|
||||||
| Vorkath | `vorkath` |
|
| Vetion | `vetion` |
|
||||||
| Wintertodt | `wintertodt` |
|
| Vorkath | `vorkath` |
|
||||||
| Zalcano | `zalcano` |
|
| Wintertodt | `wintertodt` |
|
||||||
| Zulrah | `zulrah` |
|
| Zalcano | `zalcano` |
|
||||||
|
| Zulrah | `zulrah` |
|
||||||
|
|
||||||
## What you'll get
|
## What you'll get
|
||||||
|
|
||||||
|
|||||||
@@ -10,7 +10,8 @@ import {
|
|||||||
Stats,
|
Stats,
|
||||||
getPlayerTableURL,
|
getPlayerTableURL,
|
||||||
getSkillPageURL,
|
getSkillPageURL,
|
||||||
getStatsURL
|
getStatsURL,
|
||||||
|
BOSSES
|
||||||
} from '../src/index';
|
} from '../src/index';
|
||||||
|
|
||||||
const B0ATY_NAME = 'B0ATY';
|
const B0ATY_NAME = 'B0ATY';
|
||||||
@@ -122,6 +123,7 @@ test('Parse CSV to json', () => {
|
|||||||
63,375
|
63,375
|
||||||
2870,6
|
2870,6
|
||||||
6984,138
|
6984,138
|
||||||
|
23,923141
|
||||||
4043,2000
|
4043,2000
|
||||||
489,8
|
489,8
|
||||||
967,47
|
967,47
|
||||||
@@ -212,6 +214,7 @@ test('Parse CSV to json', () => {
|
|||||||
gauntlet: { rank: 63, score: 375 },
|
gauntlet: { rank: 63, score: 375 },
|
||||||
corruptedGauntlet: { rank: 2870, score: 6 },
|
corruptedGauntlet: { rank: 2870, score: 6 },
|
||||||
theatreOfBlood: { rank: 6984, score: 138 },
|
theatreOfBlood: { rank: 6984, score: 138 },
|
||||||
|
theatreOfBloodHardMode: { rank: 23, score: 923141 },
|
||||||
thermonuclearSmokeDevil: { rank: 4043, score: 2000 },
|
thermonuclearSmokeDevil: { rank: 4043, score: 2000 },
|
||||||
tzKalZuk: { rank: 489, score: 8 },
|
tzKalZuk: { rank: 489, score: 8 },
|
||||||
tzTokJad: { rank: 967, score: 47 },
|
tzTokJad: { rank: 967, score: 47 },
|
||||||
@@ -439,7 +442,8 @@ test('Get non-existent player', async () => {
|
|||||||
});
|
});
|
||||||
|
|
||||||
test('Get stats by gamemode', async () => {
|
test('Get stats by gamemode', async () => {
|
||||||
const { skills } = await getStatsByGamemode(LYNX_TITAN_FORMATTED_NAME);
|
const { skills, bosses } = await getStatsByGamemode(LYNX_TITAN_FORMATTED_NAME);
|
||||||
|
|
||||||
expect(skills).toMatchObject({
|
expect(skills).toMatchObject({
|
||||||
overall: { rank: expect.any(Number), level: 2277, xp: 4600000000 },
|
overall: { rank: expect.any(Number), level: 2277, xp: 4600000000 },
|
||||||
attack: { rank: expect.any(Number), level: 99, xp: 200000000 },
|
attack: { rank: expect.any(Number), level: 99, xp: 200000000 },
|
||||||
@@ -466,4 +470,9 @@ test('Get stats by gamemode', async () => {
|
|||||||
hunter: { rank: expect.any(Number), level: 99, xp: 200000000 },
|
hunter: { rank: expect.any(Number), level: 99, xp: 200000000 },
|
||||||
construction: { rank: expect.any(Number), level: 99, xp: 200000000 }
|
construction: { rank: expect.any(Number), level: 99, xp: 200000000 }
|
||||||
});
|
});
|
||||||
|
|
||||||
|
const bossKeys = Object.keys(bosses);
|
||||||
|
expect(bossKeys).toStrictEqual(BOSSES);
|
||||||
|
|
||||||
|
expect.assertions(2);
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -15,7 +15,7 @@
|
|||||||
3,99,200000000
|
3,99,200000000
|
||||||
25,99,200000000
|
25,99,200000000
|
||||||
5,99,200000000
|
5,99,200000000
|
||||||
24,99,200000000
|
23,99,200000000
|
||||||
12,99,200000000
|
12,99,200000000
|
||||||
2,99,200000000
|
2,99,200000000
|
||||||
19,99,200000000
|
19,99,200000000
|
||||||
@@ -29,7 +29,8 @@
|
|||||||
-1,-1
|
-1,-1
|
||||||
-1,-1
|
-1,-1
|
||||||
-1,-1
|
-1,-1
|
||||||
344430,22
|
347584,22
|
||||||
|
-1,-1
|
||||||
-1,-1
|
-1,-1
|
||||||
-1,-1
|
-1,-1
|
||||||
-1,-1
|
-1,-1
|
||||||
|
|||||||
|
Can't render this file because it has a wrong number of fields in line 25.
|
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "osrs-json-hiscores",
|
"name": "osrs-json-hiscores",
|
||||||
"version": "2.4.2",
|
"version": "2.5.2",
|
||||||
"description": "The Old School Runescape API wrapper that does more!",
|
"description": "The Old School Runescape API wrapper that does more!",
|
||||||
"main": "lib/index.js",
|
"main": "lib/index.js",
|
||||||
"types": "lib/index.d.ts",
|
"types": "lib/index.d.ts",
|
||||||
|
|||||||
@@ -98,6 +98,7 @@ export type Boss =
|
|||||||
| 'gauntlet'
|
| 'gauntlet'
|
||||||
| 'corruptedGauntlet'
|
| 'corruptedGauntlet'
|
||||||
| 'theatreOfBlood'
|
| 'theatreOfBlood'
|
||||||
|
| 'theatreOfBloodHardMode'
|
||||||
| 'thermonuclearSmokeDevil'
|
| 'thermonuclearSmokeDevil'
|
||||||
| 'tzKalZuk'
|
| 'tzKalZuk'
|
||||||
| 'tzTokJad'
|
| 'tzTokJad'
|
||||||
|
|||||||
@@ -106,6 +106,7 @@ export const BOSSES: Boss[] = [
|
|||||||
'gauntlet',
|
'gauntlet',
|
||||||
'corruptedGauntlet',
|
'corruptedGauntlet',
|
||||||
'theatreOfBlood',
|
'theatreOfBlood',
|
||||||
|
'theatreOfBloodHardMode',
|
||||||
'thermonuclearSmokeDevil',
|
'thermonuclearSmokeDevil',
|
||||||
'tzKalZuk',
|
'tzKalZuk',
|
||||||
'tzTokJad',
|
'tzTokJad',
|
||||||
@@ -173,6 +174,7 @@ export const FORMATTED_BOSS_NAMES: FormattedBossNames = {
|
|||||||
gauntlet: 'The Gauntlet',
|
gauntlet: 'The Gauntlet',
|
||||||
corruptedGauntlet: 'The Corrupted Gauntlet',
|
corruptedGauntlet: 'The Corrupted Gauntlet',
|
||||||
theatreOfBlood: 'Theatre of Blood',
|
theatreOfBlood: 'Theatre of Blood',
|
||||||
|
theatreOfBloodHardMode: 'Theatre of Blood: Hard Mode',
|
||||||
thermonuclearSmokeDevil: 'Thermonuclear Smoke Devil',
|
thermonuclearSmokeDevil: 'Thermonuclear Smoke Devil',
|
||||||
tzKalZuk: 'TzKal-Zuk',
|
tzKalZuk: 'TzKal-Zuk',
|
||||||
tzTokJad: 'TzTok-Jad',
|
tzTokJad: 'TzTok-Jad',
|
||||||
|
|||||||
@@ -4,7 +4,12 @@
|
|||||||
"module": "commonjs",
|
"module": "commonjs",
|
||||||
"declaration": true,
|
"declaration": true,
|
||||||
"outDir": "./lib",
|
"outDir": "./lib",
|
||||||
"strict": true
|
"strict": true,
|
||||||
|
"lib": ["ES2015", "DOM", "DOM.Iterable"],
|
||||||
|
"typeRoots": [
|
||||||
|
"./node_modules/@types",
|
||||||
|
"./src/@types"
|
||||||
|
]
|
||||||
},
|
},
|
||||||
"include": ["src"],
|
"include": ["src"],
|
||||||
"exclude": ["node_modules", "**/__tests__/*"]
|
"exclude": ["node_modules", "**/__tests__/*"]
|
||||||
|
|||||||
24
yarn.lock
24
yarn.lock
@@ -2775,9 +2775,9 @@ has@^1.0.3:
|
|||||||
function-bind "^1.1.1"
|
function-bind "^1.1.1"
|
||||||
|
|
||||||
hosted-git-info@^2.1.4:
|
hosted-git-info@^2.1.4:
|
||||||
version "2.8.8"
|
version "2.8.9"
|
||||||
resolved "https://registry.yarnpkg.com/hosted-git-info/-/hosted-git-info-2.8.8.tgz#7539bd4bc1e0e0a895815a2e0262420b12858488"
|
resolved "https://registry.yarnpkg.com/hosted-git-info/-/hosted-git-info-2.8.9.tgz#dffc0bf9a21c02209090f2aa69429e1414daf3f9"
|
||||||
integrity sha512-f/wzC2QaWBs7t9IYqB4T3sR1xviIViXJRJTWBlx2Gf3g0Xi5vI7Yy4koXQ1c9OYDGHN9sBy1DQ2AB8fqZBWhUg==
|
integrity sha512-mxIDAb9Lsm6DoOJ7xH+5+X4y1LU/4Hi50L9C5sIswK3JzULS4bwk1FvjdBgvYR4bzT4tuUQiC15FE2f5HbLvYw==
|
||||||
|
|
||||||
hosted-git-info@^3.0.0:
|
hosted-git-info@^3.0.0:
|
||||||
version "3.0.8"
|
version "3.0.8"
|
||||||
@@ -4411,9 +4411,9 @@ normalize-path@^3.0.0:
|
|||||||
integrity sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==
|
integrity sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==
|
||||||
|
|
||||||
normalize-url@^4.1.0:
|
normalize-url@^4.1.0:
|
||||||
version "4.5.0"
|
version "4.5.1"
|
||||||
resolved "https://registry.yarnpkg.com/normalize-url/-/normalize-url-4.5.0.tgz#453354087e6ca96957bd8f5baf753f5982142129"
|
resolved "https://registry.yarnpkg.com/normalize-url/-/normalize-url-4.5.1.tgz#0dd90cf1288ee1d1313b87081c9a5932ee48518a"
|
||||||
integrity sha512-2s47yzUxdexf1OhyRi4Em83iQk0aPvwTddtFz4hnSSw9dCEsLEGf6SwIO8ss/19S9iBb5sJaOuTvTGDeZI00BQ==
|
integrity sha512-9UZCFRHQdNrfTpGg8+1INIg93B6zE0aXMVFkw1WFwvO4SlZywU6aLg5Of0Ap/PgcbSw4LNxvMWXMeugwMCX0AA==
|
||||||
|
|
||||||
normalize-version@^1.0.5:
|
normalize-version@^1.0.5:
|
||||||
version "1.0.5"
|
version "1.0.5"
|
||||||
@@ -5968,9 +5968,9 @@ tr46@^2.0.2:
|
|||||||
punycode "^2.1.1"
|
punycode "^2.1.1"
|
||||||
|
|
||||||
trim-newlines@^3.0.0:
|
trim-newlines@^3.0.0:
|
||||||
version "3.0.0"
|
version "3.0.1"
|
||||||
resolved "https://registry.yarnpkg.com/trim-newlines/-/trim-newlines-3.0.0.tgz#79726304a6a898aa8373427298d54c2ee8b1cb30"
|
resolved "https://registry.yarnpkg.com/trim-newlines/-/trim-newlines-3.0.1.tgz#260a5d962d8b752425b32f3a7db0dcacd176c144"
|
||||||
integrity sha512-C4+gOpvmxaSMKuEf9Qc134F1ZuOHVXKRbtEflf4NTtuuJDEIJ9p5PXsalL8SkeRw+qit1Mo+yuvMPAKwWg/1hA==
|
integrity sha512-c1PTsA3tYrIsLGkJkzHF+w9F2EyxfXGo4UyJc4pFL++FMjnq0HJS69T3M7d//gKrFKwy429bouPescbjecU+Zw==
|
||||||
|
|
||||||
ts-jest@^26.5.4:
|
ts-jest@^26.5.4:
|
||||||
version "26.5.4"
|
version "26.5.4"
|
||||||
@@ -6364,9 +6364,9 @@ write-file-atomic@^3.0.0:
|
|||||||
typedarray-to-buffer "^3.1.5"
|
typedarray-to-buffer "^3.1.5"
|
||||||
|
|
||||||
ws@^7.2.3:
|
ws@^7.2.3:
|
||||||
version "7.4.2"
|
version "7.4.6"
|
||||||
resolved "https://registry.yarnpkg.com/ws/-/ws-7.4.2.tgz#782100048e54eb36fe9843363ab1c68672b261dd"
|
resolved "https://registry.yarnpkg.com/ws/-/ws-7.4.6.tgz#5654ca8ecdeee47c33a9a4bf6d28e2be2980377c"
|
||||||
integrity sha512-T4tewALS3+qsrpGI/8dqNMLIVdq/g/85U98HPMa6F0m6xTbvhXU6RCQLqPH3+SlomNV/LdY6RXEbBpMH6EOJnA==
|
integrity sha512-YmhHDO4MzaDLB+M9ym/mDA5z0naX8j7SIlT8f8z+I0VtzsRbekxEutHSme7NPS2qE8StCYQNUnfWdXta/Yu85A==
|
||||||
|
|
||||||
xdg-basedir@^4.0.0:
|
xdg-basedir@^4.0.0:
|
||||||
version "4.0.0"
|
version "4.0.0"
|
||||||
|
|||||||
Reference in New Issue
Block a user