Skip to content

@temporary-escape/mod-sdk / SpawnArgsView

Class: SpawnArgsView ​

Defined in: templates.ts:611

Read-only view over the spawn arguments a template's onSpawn receives. The backing buffer is owned by the host and only valid for the duration of the hook; copy anything you need to keep.

Methods ​

getAssetBlock() ​

ts
getAssetBlock(key: string): AssetBlock | null;

Defined in: templates.ts:895

Parameters ​

ParameterType
keystring

Returns ​

AssetBlock | null


getAssetBlockCategory() ​

ts
getAssetBlockCategory(key: string): AssetBlockCategory | null;

Defined in: templates.ts:935

Parameters ​

ParameterType
keystring

Returns ​

AssetBlockCategory | null


getAssetFaction() ​

ts
getAssetFaction(key: string): AssetFaction | null;

Defined in: templates.ts:910

Parameters ​

ParameterType
keystring

Returns ​

AssetFaction | null


getAssetImage() ​

ts
getAssetImage(key: string): AssetImage | null;

Defined in: templates.ts:890

Parameters ​

ParameterType
keystring

Returns ​

AssetImage | null


getAssetModel() ​

ts
getAssetModel(key: string): AssetModel | null;

Defined in: templates.ts:900

Parameters ​

ParameterType
keystring

Returns ​

AssetModel | null


getAssetPlanet() ​

ts
getAssetPlanet(key: string): AssetPlanet | null;

Defined in: templates.ts:925

Parameters ​

ParameterType
keystring

Returns ​

AssetPlanet | null


getAssetSectorType() ​

ts
getAssetSectorType(key: string): AssetSectorType | null;

Defined in: templates.ts:920

Parameters ​

ParameterType
keystring

Returns ​

AssetSectorType | null


getAssetShader() ​

ts
getAssetShader(key: string): AssetShader | null;

Defined in: templates.ts:945

Parameters ​

ParameterType
keystring

Returns ​

AssetShader | null


getAssetShipDesign() ​

ts
getAssetShipDesign(key: string): AssetShipDesign | null;

Defined in: templates.ts:915

Parameters ​

ParameterType
keystring

Returns ​

AssetShipDesign | null


getAssetSkybox() ​

ts
getAssetSkybox(key: string): AssetSkybox | null;

Defined in: templates.ts:955

Parameters ​

ParameterType
keystring

Returns ​

AssetSkybox | null


getAssetSound() ​

ts
getAssetSound(key: string): AssetSound | null;

Defined in: templates.ts:940

Parameters ​

ParameterType
keystring

Returns ​

AssetSound | null


getAssetSystemType() ​

ts
getAssetSystemType(key: string): AssetSystemType | null;

Defined in: templates.ts:950

Parameters ​

ParameterType
keystring

Returns ​

AssetSystemType | null


getAssetTexture() ​

ts
getAssetTexture(key: string): AssetTexture | null;

Defined in: templates.ts:905

Parameters ​

ParameterType
keystring

Returns ​

AssetTexture | null


getAssetTurret() ​

ts
getAssetTurret(key: string): AssetTurret | null;

Defined in: templates.ts:930

Parameters ​

ParameterType
keystring

Returns ​

AssetTurret | null


getBool() ​

ts
getBool(key: string, fallback?: bool): bool;

Defined in: templates.ts:738

Parameters ​

ParameterTypeDefault value
keystringundefined
fallbackboolfalse

Returns ​

bool


getBytes() ​

ts
getBytes(key: string): Uint8Array | null;

Defined in: templates.ts:754

Parameters ​

ParameterType
keystring

Returns ​

Uint8Array | null


getF64() ​

ts
getF64(key: string, fallback?: number): number;

Defined in: templates.ts:724

Parameters ​

ParameterTypeDefault value
keystringundefined
fallbacknumber0

Returns ​

number


getI64() ​

ts
getI64(key: string, fallback?: number): number;

Defined in: templates.ts:695

Parameters ​

ParameterTypeDefault value
keystringundefined
fallbacknumber0

Returns ​

number


getMatrix3() ​

ts
getMatrix3(key: string, fallback: Matrix3f): Matrix3f;

Defined in: templates.ts:874

Parameters ​

ParameterType
keystring
fallbackMatrix3f

Returns ​

Matrix3f


getMatrix4() ​

ts
getMatrix4(key: string, fallback: Matrix4f): Matrix4f;

Defined in: templates.ts:882

Parameters ​

ParameterType
keystring
fallbackMatrix4f

Returns ​

Matrix4f


getQuaternion() ​

ts
getQuaternion(key: string, fallback: Quaternion): Quaternion;

Defined in: templates.ts:866

Parameters ​

ParameterType
keystring
fallbackQuaternion

Returns ​

Quaternion


getString() ​

ts
getString(key: string, fallback?: string): string;

Defined in: templates.ts:746

Parameters ​

ParameterTypeDefault value
keystringundefined
fallbackstring""

Returns ​

string


getU64() ​

ts
getU64(key: string, fallback?: number): number;

Defined in: templates.ts:710

Parameters ​

ParameterTypeDefault value
keystringundefined
fallbacknumber0

Returns ​

number


getVector2b() ​

ts
getVector2b(key: string, fallback: Vector2b): Vector2b;

Defined in: templates.ts:838

Parameters ​

ParameterType
keystring
fallbackVector2b

Returns ​

Vector2b


getVector2d() ​

ts
getVector2d(key: string, fallback: Vector2d): Vector2d;

Defined in: templates.ts:812

Parameters ​

ParameterType
keystring
fallbackVector2d

Returns ​

Vector2d


getVector2f() ​

ts
getVector2f(key: string, fallback: Vector2f): Vector2f;

Defined in: templates.ts:762

Parameters ​

ParameterType
keystring
fallbackVector2f

Returns ​

Vector2f


getVector2i() ​

ts
getVector2i(key: string, fallback: Vector2i): Vector2i;

Defined in: templates.ts:788

Parameters ​

ParameterType
keystring
fallbackVector2i

Returns ​

Vector2i


getVector3b() ​

ts
getVector3b(key: string, fallback: Vector3b): Vector3b;

Defined in: templates.ts:846

Parameters ​

ParameterType
keystring
fallbackVector3b

Returns ​

Vector3b


getVector3d() ​

ts
getVector3d(key: string, fallback: Vector3d): Vector3d;

Defined in: templates.ts:820

Parameters ​

ParameterType
keystring
fallbackVector3d

Returns ​

Vector3d


getVector3f() ​

ts
getVector3f(key: string, fallback: Vector3f): Vector3f;

Defined in: templates.ts:770

Parameters ​

ParameterType
keystring
fallbackVector3f

Returns ​

Vector3f


getVector3i() ​

ts
getVector3i(key: string, fallback: Vector3i): Vector3i;

Defined in: templates.ts:796

Parameters ​

ParameterType
keystring
fallbackVector3i

Returns ​

Vector3i


getVector4b() ​

ts
getVector4b(key: string, fallback: Vector4b): Vector4b;

Defined in: templates.ts:856

Parameters ​

ParameterType
keystring
fallbackVector4b

Returns ​

Vector4b


getVector4d() ​

ts
getVector4d(key: string, fallback: Vector4d): Vector4d;

Defined in: templates.ts:828

Parameters ​

ParameterType
keystring
fallbackVector4d

Returns ​

Vector4d


getVector4f() ​

ts
getVector4f(key: string, fallback: Vector4f): Vector4f;

Defined in: templates.ts:778

Parameters ​

ParameterType
keystring
fallbackVector4f

Returns ​

Vector4f


getVector4i() ​

ts
getVector4i(key: string, fallback: Vector4i): Vector4i;

Defined in: templates.ts:804

Parameters ​

ParameterType
keystring
fallbackVector4i

Returns ​

Vector4i


has() ​

ts
has(key: string): bool;

Defined in: templates.ts:691

Parameters ​

ParameterType
keystring

Returns ​

bool


fromRaw() ​

ts
static fromRaw(ptr: number, len: number): SpawnArgsView;

Defined in: templates.ts:616

Parameters ​

ParameterType
ptrnumber
lennumber

Returns ​

SpawnArgsView