five-on-it / apps/client/src/renderer/heli-view / HeliView
Interface: HeliView
Defined in: apps/client/src/renderer/heli-view.ts:72
The helicopters' view.
Methods
dispose()
dispose():
void
Defined in: apps/client/src/renderer/heli-view.ts:84
Takes every helicopter and the meshes they share out of the scene.
Returns
void
gunOf()
gunOf(
eid): {x:number;y:number;z:number; } |undefined
Defined in: apps/client/src/renderer/heli-view.ts:82
Where a helicopter's door gun is drawn now (its door gunner's laser starts there), or undefined when none of that id is drawn.
Parameters
eid
number
Returns
{ x: number; y: number; z: number; } | undefined
nearest()
nearest(
at):number
Defined in: apps/client/src/renderer/heli-view.ts:80
How far the nearest helicopter in the air is from a point on the ground (m, horizontal), Infinity with none.
Parameters
at
x
number
z
number
Returns
number
render()
render(
now,frame):void
Defined in: apps/client/src/renderer/heli-view.ts:76
One frame: each helicopter where it is now, under the camera's ceiling, its rotors turning, its strobes blinking, its shadow and its searchlight on what is under them.
Parameters
now
number
frame
HeliFrame
Returns
void
shown()
shown():
HeliShown[]
Defined in: apps/client/src/renderer/heli-view.ts:78
The helicopters drawn now (for the tests' window.__poc()).
Returns
update()
update(
entities,now):void
Defined in: apps/client/src/renderer/heli-view.ts:74
A snapshot's entities: the helicopters in it are drawn, those it no longer lists go. now is performance.now() in ms.
Parameters
entities
readonly EntitySnapshot[]
now
number
Returns
void