Skip to content
ASArcaneMP Scripting APIScripting reference
Global objectClient APIGenerated

Speech

const Speech: object

Defined in: client/api.d.ts:8764

Spoken incantations from a fixed list built into the client, heard on the voice chat’s microphone. Nothing is cast: a resource listens for ids and decides what each does. A push-to-talk player is heard only while transmitting, a voice-activated one whenever a resource listens. Recognition runs on this machine and sends nothing. A resource’s list ends when it stops.

incantations(): string[]

Every incantation id this client can hear: the spell’s gameplay name, as Spells.loadout() names it. Expulso is said “Bombarda”, Imperius “Imperio” and Wingardium “Wingardium Leviosa”. Fixed in the client.

string[]

isAvailable(): boolean

Whether this client can hear incantations now: the speech model is installed and has not failed to load, and the voice chat microphone is open. False outside a session and with voice chat off or no microphone.

boolean

listen(ids): void

Listens for these incantations, replacing this resource’s list. Throws a TypeError for an id Speech.incantations() does not list.

string[]

Ids from Speech.incantations(); an empty list stops.

void

stop(): void

Stops this resource listening, as Speech.listen([]) does.

void