@runejs/filestore
Version:
Tools for managing the RuneJS filestore.
40 lines (39 loc) • 1.59 kB
TypeScript
import { type FilestoreChannels } from './data';
import { FileIndex, type IndexId } from './file-index';
import { SpriteStore, MusicStore, BinaryStore, JingleStore, SoundStore, RegionStore, ConfigStore, ModelStore, WidgetStore, FontStore, TextureStore, type ItemStore, type NpcStore, type ObjectStore, type XteaDefinition, type VarbitStore } from './stores';
export declare let fileNames: {
[key: string]: string | null;
};
export declare const getFileName: (nameHash: number) => string | null;
export declare class Filestore {
readonly filestoreDir: string;
readonly configDir: string;
readonly binaryStore: BinaryStore;
readonly configStore: ConfigStore;
readonly fontStore: FontStore;
readonly jingleStore: JingleStore;
readonly modelStore: ModelStore;
readonly musicStore: MusicStore;
readonly regionStore: RegionStore;
readonly soundStore: SoundStore;
readonly spriteStore: SpriteStore;
readonly widgetStore: WidgetStore;
readonly textureStore: TextureStore;
readonly channels: FilestoreChannels;
readonly indexes: Map<number, FileIndex>;
constructor(filestoreDir: string, options?: {
configDir?: string;
xteas?: {
[key: number]: XteaDefinition;
};
});
/**
* Fetches the specified File Index.
* @param indexId The string or numberic ID of the File Index to find.
*/
getIndex(inputIndexId: number | IndexId): FileIndex;
get itemStore(): ItemStore;
get varbitStore(): VarbitStore;
get npcStore(): NpcStore;
get objectStore(): ObjectStore;
}