Skip to content

five-on-it / apps/client/src/audio/radio / Radio

Interface: Radio ​

Defined in: apps/client/src/audio/radio.ts:81

The radio.

Properties ​

stations ​

readonly stations: readonly Station[]

Defined in: apps/client/src/audio/radio.ts:82


tunable ​

readonly tunable: boolean

Defined in: apps/client/src/audio/radio.ts:90

Whether the keys tune it now: in a car with a radio, or on foot with earbuds.

Methods ​

dispose() ​

dispose(): void

Defined in: apps/client/src/audio/radio.ts:93

Stops it.

Returns ​

void


step() ​

step(by): void

Defined in: apps/client/src/audio/radio.ts:88

The next station (1) or the one before (−1), off between the last and the first.

Parameters ​

by ​

-1 | 1

Returns ​

void


tune() ​

tune(index): void

Defined in: apps/client/src/audio/radio.ts:86

Tunes to a station by its index, or off (−1); in a car, the car's.

Parameters ​

index ​

number

Returns ​

void


update() ​

update(context): void

Defined in: apps/client/src/audio/radio.ts:84

Follows the player, every frame.

Parameters ​

context ​

RadioContext

Returns ​

void


view() ​

view(): RadioView

Defined in: apps/client/src/audio/radio.ts:91

Returns ​

RadioView