Skip to content

five-on-it / apps/client/src/renderer/companions / Companions

Class: Companions ​

Defined in: apps/client/src/renderer/companions.ts:46

The carts before the people that have them: see the module documentation.

Constructors ​

Constructor ​

new Companions(scene, models, drop): Companions

Defined in: apps/client/src/renderer/companions.ts:58

Parameters ​

scene ​

Scene

models ​

ActorModels

drop ​

number

Returns ​

Companions

Accessors ​

count ​

Get Signature ​

get count(): object

Defined in: apps/client/src/renderer/companions.ts:65

How many carts are in the scene, and how many companions shown (the tests' readout).

Returns ​

object

carts ​

carts: number

shown ​

shown: number

Methods ​

begin() ​

begin(): void

Defined in: apps/client/src/renderer/companions.ts:72

Starts a frame: every companion hidden until placed.

Returns ​

void


dispose() ​

dispose(): void

Defined in: apps/client/src/renderer/companions.ts:112

Lets go of every companion.

Returns ​

void


end() ​

end(): void

Defined in: apps/client/src/renderer/companions.ts:99

Ends a frame: the companions nobody placed hidden.

Returns ​

void


place() ​

place(eid, kind, world): void

Defined in: apps/client/src/renderer/companions.ts:80

Places the companion of the person eid (a kind) beside it this frame: world is the person's node's world matrix (its centre, turned its way).

Parameters ​

eid ​

number

kind ​

"cart"

world ​

Matrix

Returns ​

void


release() ​

release(eid): void

Defined in: apps/client/src/renderer/companions.ts:104

Lets go of the companion of the person eid (gone, or no longer of a role that has one).

Parameters ​

eid ​

number

Returns ​

void