Files
Exiled-Exchange-2/dataParser/vendor/client/tables/index.ts
T
Kvan7 835e43a166 v0.1.4 (#166)
* Fix #132

* Features/python script update (#143)

This closes the following issues:

- #67 
- #68 
- #69 
- #70 
- #110 
- #111 
- #112 
- #139

* [Parse Error] - Dualstring bow #60

* Adds starting for localization

* tests yay, this is terrible Add junit tests :( #74

* revert tests cause they were really terrible

* bump gitignore so i dont lose files

* Features/pseudo-pseudo (#93)

* uhhhhhhhhhhhh, maybe pseudo will get support before GGG

* psesudo only ele

* remove git ignored files

* fix ignore

* working tree

* update parser #67

* bump

* more stuff

* maybe working new desc parsing

* Description parser

* Maybe?

* update

* add ko and cmn-Hant

* Add items and pseudo

* push to main

* force utf-16

* moving data

* uh, miss typed a utf 8 for a utf 16

* revert cause that was worse

* Features/moreLocalizationFixes (#148)

* change data files

* ru client strings

* Revert to search by translated name

REVERT THIS LATER ONCE COPY ADVANCED DESC IS BACK

* ru ko and cmn-Hant parse correctly now

* Change Exalted orb to Perfect Jewelers orb

May change again, but just found out about sidekick and since their program was made before creating this, I'm not going to add conflict of logos.

* change from jewelers to div, didn't like how it looked in ui

* Update README

* Update README.md

* Update README.md

* Revert "change from jewelers to div, didn't like how it looked in ui"

This reverts commit b11d33353d.

* Update README.md

* Update localization for PoE2 #66

Functional. Missing some base types in some languages but will make separate issue

* move .ds_store to ds_store (just unhide)

* Builtin browser opens while disabled in settings #103

* [Not Recognized Modifier] - +2 Charm Slots #137

* Remove calls to poeprices for now

* Version Bump to v0.1.4

* Move store and rename

* file move error

* lint + update app_i18n

* [PoE2] Item gets pinned in-game with CTRL+D (auto-hide on) #124

* add fix to pull-json

* final lint fix
2024-12-24 12:45:31 -06:00

112 lines
2.9 KiB
TypeScript

import * as fs from 'node:fs';
import * as path from 'node:path';
interface ArmourTypeRow {
BaseItemTypesKey: number;
Armour: number;
Evasion: number;
EnergyShield: number;
}
export function ArmourTypes(): ArmourTypeRow[] {
const data = fs.readFileSync(path.join(__dirname, 'ArmourTypes.json'), { encoding: 'utf-8' });
return JSON.parse(data) as ArmourTypeRow[];
}
interface BaseItemTypeRow {
_index: number;
Id: string;
Width: number;
Height: number;
Name: string;
DropLevel: number;
Implicit_ModsKeys: string[];
ItemVisualIdentity: number;
IsCorrupted: boolean;
ItemClassesKey: string;
SiteVisibility: number;
TagsKeys: string[];
}
export function BaseItemTypes(lang: string = 'en'): BaseItemTypeRow[] {
const data = fs.readFileSync(path.join(__dirname, 'BaseItemTypes.json'), { encoding: 'utf-8' });
return JSON.parse(data) as BaseItemTypeRow[];
}
interface ItemClassRow {
Id: string;
}
export function ItemClasses(): ItemClassRow[] {
const data = fs.readFileSync(path.join(__dirname, 'ItemClasses.json'), { encoding: 'utf-8' });
return JSON.parse(data) as ItemClassRow[];
}
interface ItemVisualIdentityRow {
_index: number;
Id: string;
DDSFile: string;
AOFile: string;
}
export function ItemVisualIdentity(): ItemVisualIdentityRow[] {
const data = fs.readFileSync(path.join(__dirname, 'ItemVisualIdentity.json'), { encoding: 'utf-8' });
return JSON.parse(data) as ItemVisualIdentityRow[];
}
interface TagRow {
Id: string;
DisplayString: string;
}
export function Tags(): TagRow[] {
const data = fs.readFileSync(path.join(__dirname, 'Tags.json'), { encoding: 'utf-8' });
return JSON.parse(data) as TagRow[];
}
interface UniqueStashLayoutRow {
WordsKey: number;
ShowIfEmptyChallengeLeague: boolean;
RenamedVersion: number;
UniqueStashTypesKey: number;
ItemVisualIdentityKey: number;
ShowIfEmptyStandard: boolean;
IsAlternateArt: boolean;
}
export function UniquesStashLayout(): UniqueStashLayoutRow[] {
const data = fs.readFileSync(path.join(__dirname, 'UniquesStashLayout.json'), { encoding: 'utf-8' });
return JSON.parse(data) as UniqueStashLayoutRow[];
}
interface WordRow {
_index: number;
Wordlist: number;
Text: string;
SpawnWeight_Tags: number[];
SpawnWeight_Values: number[];
Text2: string;
}
export function Words(lang: string = 'en'): WordRow[] {
const data = fs.readFileSync(path.join(__dirname, 'Words.json'), { encoding: 'utf-8' });
return JSON.parse(data) as WordRow[];
}
interface StatsRow {
Id: string;
IsLocal: boolean;
IsWeaponLocal: boolean;
Semantics: number;
Text: string;
IsVirtual: boolean;
HASH32: number;
BelongsActiveSkillsKey: string[];
IsScalable: boolean;
}
export function Stats(): StatsRow[] {
const data = fs.readFileSync(path.join(__dirname, 'Stats.json'), { encoding: 'utf-8' });
return JSON.parse(data) as StatsRow[];
}