@abextm/cache2
Version:
Utilities for reading OSRS "caches"
52 lines • 2.34 kB
TypeScript
import { Typed } from "./reflect.js";
import { ScriptVarChar, ScriptVarID } from "./types.js";
export type BaseVarType = "int" | "string" | "long";
export declare namespace BaseVarType {
function forOrdinal(ordinal: number): BaseVarType;
}
export declare class ScriptVarType {
readonly name: string;
readonly id: ScriptVarID | undefined;
readonly char: ScriptVarChar | undefined;
readonly jagexName: string | undefined;
readonly typeName: string | undefined;
readonly baseType: BaseVarType;
static forChar(c: ScriptVarChar): ScriptVarType | undefined;
static forID(i: ScriptVarID): ScriptVarType | undefined;
static withType<T>(v: T, type: ScriptVarID | ScriptVarType | undefined): Typed.Value<T>;
constructor(name: string, id: ScriptVarID | undefined, char: ScriptVarChar | undefined, jagexName: string | undefined, typeName: string | undefined, baseType: BaseVarType);
asTyped(): Typed.Named | undefined;
withType<T>(v: T): Typed.Value<T>;
private static t;
static readonly int: ScriptVarType;
static readonly bool: ScriptVarType;
static readonly anim: ScriptVarType;
static readonly color: ScriptVarType;
static readonly widget: ScriptVarType;
static readonly kit: ScriptVarType;
static readonly midi: ScriptVarType;
static readonly namedItem: ScriptVarType;
static readonly synth: ScriptVarType;
static readonly stat: ScriptVarType;
static readonly coord: ScriptVarType;
static readonly sprite: ScriptVarType;
static readonly font: ScriptVarType;
static readonly enum: ScriptVarType;
static readonly jingle: ScriptVarType;
static readonly obj: ScriptVarType;
static readonly model: ScriptVarType;
static readonly npc: ScriptVarType;
static readonly item: ScriptVarType;
static readonly string: ScriptVarType;
static readonly spotAnim: ScriptVarType;
static readonly inventory: ScriptVarType;
static readonly texture: ScriptVarType;
static readonly char: ScriptVarType;
static readonly mapSceneIcon: ScriptVarType;
static readonly mapElement: ScriptVarType;
static readonly hitsplat: ScriptVarType;
static readonly struct: ScriptVarType;
static readonly dbRow: ScriptVarType;
static readonly varp: ScriptVarType;
}
//# sourceMappingURL=ScriptVarType.d.ts.map