Skip to content

Class: MockSound

Mock of the X-Ray engine sound action enumeration.

Implements

  • sound

Constructors

Constructor

ts
new MockSound(...args: unknown[]): MockSound;

Parameters

ParameterType
...argsunknown[]

Returns

MockSound

Methods

completed()

ts
completed(): boolean;

Returns

boolean

Whether sound playback is complete.

Implementation of

ts
sound.completed

set_angles()

ts
set_angles(vector: vector): void;

Set sound angles.

Parameters

ParameterTypeDescription
vectorvectorAngles.

Returns

void

Implementation of

ts
sound.set_angles

set_bone()

ts
set_bone(value: string): void;

Set sound bone.

Parameters

ParameterTypeDescription
valuestringBone name.

Returns

void

Implementation of

ts
sound.set_bone

set_position()

ts
set_position(vector: vector): void;

Set sound position.

Parameters

ParameterTypeDescription
vectorvectorPosition.

Returns

void

Implementation of

ts
sound.set_position

set_sound()

ts
set_sound(value: string | sound_object): void;

Set sound by name.

Parameters

ParameterTypeDescription
valuestring | sound_objectSound name.

Returns

void

Implementation of

ts
sound.set_sound

set_sound_type()

ts
set_sound_type(type: TXR_snd_type): void;

Set sound type.

Parameters

ParameterTypeDescription
typeTXR_snd_typeSound type id.

Returns

void

Implementation of

ts
sound.set_sound_type

create()

ts
static create(...args: unknown[]): MockSound;

Parameters

ParameterType
...argsunknown[]

Returns

MockSound


mock()

ts
static mock(...args: unknown[]): sound;

Parameters

ParameterType
...argsunknown[]

Returns

sound

Properties

__name

ts
__name: string = "sound";

LuaBind instance constructor name.

Implementation of

ts
sound.__name

angles

ts
angles: vector | null = null;

args

ts
args: unknown[];

bone

ts
bone: string | null = null;

isCompleted

ts
isCompleted: boolean = false;

position

ts
position: vector | null = null;

sound

ts
sound: string | sound_object | null = null;

soundType

ts
soundType: TXR_snd_type | null = null;

attack

ts
readonly static attack: 3;

Engine enum value for sound.attack.


attack_hit

ts
readonly static attack_hit: 4;

Engine enum value for sound.attack_hit.


die

ts
readonly static die: 7;

Engine enum value for sound.die.


eat

ts
readonly static eat: 2;

Engine enum value for sound.eat.


idle

ts
readonly static idle: 1;

Engine enum value for sound.idle.


panic

ts
readonly static panic: 11;

Engine enum value for sound.panic.


steal

ts
readonly static steal: 10;

Engine enum value for sound.steal.


take_damage

ts
readonly static take_damage: 5;

Engine enum value for sound.take_damage.


threaten

ts
readonly static threaten: 9;

Engine enum value for sound.threaten.