Skip to content

five-on-it / apps/level-editor/src/scripts/blocks/container / default

Class: default ​

Defined in: apps/level-editor/src/scripts/blocks/container.ts:16

The block's script: its presence on a node is what marks the node; its fields say what it is and holds.

Implements ​

  • IScript

Constructors ​

Constructor ​

new default(mesh): ContainerBlock

Defined in: apps/level-editor/src/scripts/blocks/container.ts:34

Parameters ​

mesh ​

Mesh

Returns ​

ContainerBlock

Properties ​

items ​

items: string = ''

Defined in: apps/level-editor/src/scripts/blocks/container.ts:23

What it holds: item ids separated by spaces, each with an optional *<count>.


kind ​

kind: string = 'crate'

Defined in: apps/level-editor/src/scripts/blocks/container.ts:19

crate, locker or pickup (items lying on the ground).


lock ​

lock: string = ''

Defined in: apps/level-editor/src/scripts/blocks/container.ts:27

The tag of the item that unlocks it; empty for one that is not locked.


mesh ​

readonly mesh: Mesh

Defined in: apps/level-editor/src/scripts/blocks/container.ts:32

Methods ​

onStart() ​

onStart(): void

Defined in: apps/level-editor/src/scripts/blocks/container.ts:30

Nothing to do at play time: the block is read by npm run level:export.

Returns ​

void

Implementation of ​

IScript.onStart