casc-cdn 0.1.0 → 0.1.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/README.md +2 -7
- package/dist/README.md +2 -7
- package/dist/index.d.ts +1 -0
- package/dist/index.js +5 -2
- package/dist/package.json +1 -5
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -160,13 +160,8 @@ if (soundEntry) {
|
|
|
160
160
|
const fileData = await client.getFile(soundEntry.contentKey);
|
|
161
161
|
|
|
162
162
|
if (fileData) {
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
const lines = content.split('\n');
|
|
166
|
-
|
|
167
|
-
console.log(`File has ${lines.length} lines`);
|
|
168
|
-
console.log('First 10 lines:');
|
|
169
|
-
console.log(lines.slice(0, 10).join('\n'));
|
|
163
|
+
fs.writeFile('output.flac', fileData);
|
|
164
|
+
console.log(`File length ${fileData.length} bytes`);
|
|
170
165
|
}
|
|
171
166
|
}
|
|
172
167
|
```
|
package/dist/README.md
CHANGED
|
@@ -160,13 +160,8 @@ if (soundEntry) {
|
|
|
160
160
|
const fileData = await client.getFile(soundEntry.contentKey);
|
|
161
161
|
|
|
162
162
|
if (fileData) {
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
const lines = content.split('\n');
|
|
166
|
-
|
|
167
|
-
console.log(`File has ${lines.length} lines`);
|
|
168
|
-
console.log('First 10 lines:');
|
|
169
|
-
console.log(lines.slice(0, 10).join('\n'));
|
|
163
|
+
fs.writeFile('output.flac', fileData);
|
|
164
|
+
console.log(`File length ${fileData.length} bytes`);
|
|
170
165
|
}
|
|
171
166
|
}
|
|
172
167
|
```
|
package/dist/index.d.ts
CHANGED
package/dist/index.js
CHANGED
|
@@ -858,7 +858,8 @@ var RootFile = class {
|
|
|
858
858
|
ruRU: false,
|
|
859
859
|
ptBR: false,
|
|
860
860
|
itIT: false,
|
|
861
|
-
ptPT: false
|
|
861
|
+
ptPT: false,
|
|
862
|
+
plPL: false
|
|
862
863
|
};
|
|
863
864
|
if (typeof localeFlag === "string") {
|
|
864
865
|
const prepared = localeFlag.replace(/-\s_/, "");
|
|
@@ -997,7 +998,9 @@ var CascClient = class CascClient {
|
|
|
997
998
|
parseIndexEntry(await this.api.getData(cdn.Hosts[0], cdn.Path, hash, true), hash, "archive").forEach((entry) => {
|
|
998
999
|
this.indices.set(entry.eKey, entry);
|
|
999
1000
|
});
|
|
1000
|
-
} catch (e) {
|
|
1001
|
+
} catch (e) {
|
|
1002
|
+
console.warn(`Failed to load archive index ${hash}`);
|
|
1003
|
+
}
|
|
1001
1004
|
}
|
|
1002
1005
|
/**
|
|
1003
1006
|
* Downloads and decodes a single file by its content key (CKey).
|
package/dist/package.json
CHANGED
|
@@ -1,12 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "casc-cdn",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.1",
|
|
4
4
|
"description": "A modern and minimal TypeScript library for downloading and extracting files from Blizzard's CASC (Content Addressable Storage Container) archives via CDN.",
|
|
5
5
|
"author": "Bogdan Tretyakov <trbogdan@gmail.com>",
|
|
6
|
-
"publishConfig": {
|
|
7
|
-
"access": "public",
|
|
8
|
-
"registry": "https://registry.npmjs.org/"
|
|
9
|
-
},
|
|
10
6
|
"license": "MIT",
|
|
11
7
|
"homepage": "https://github.com/BogdanTretyakov/casc-cdn",
|
|
12
8
|
"bugs": {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "casc-cdn",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.1",
|
|
4
4
|
"description": "A modern and minimal TypeScript library for downloading and extracting files from Blizzard's CASC (Content Addressable Storage Container) archives via CDN.",
|
|
5
5
|
"author": "Bogdan Tretyakov <trbogdan@gmail.com>",
|
|
6
6
|
"license": "MIT",
|