Skip to content

helix / Objective

Class: Objective

Defined in: core/frontend/nodes/objective.ts:29

Constructors

Constructor

new Objective(objective, kind?): Objective

Defined in: core/frontend/nodes/objective.ts:30

Parameters

objective

string

kind?

ObjectiveKind = "dummy"

Returns

Objective

Properties

kind

kind: ObjectiveKind = "dummy"

Defined in: core/frontend/nodes/objective.ts:32


objective

objective: string

Defined in: core/frontend/nodes/objective.ts:31

Methods

enable()

enable(ctx, selector): void

Defined in: core/frontend/nodes/objective.ts:52

Parameters

ctx

FunctionContext

selector

Selector

Returns

void


getName()

getName(): string

Defined in: core/frontend/nodes/objective.ts:35

Returns

string


score()

score(target): Score

Defined in: core/frontend/nodes/objective.ts:48

A score holder on this objective. Accepts a Selector directly (selectors are score holders - @a, @s, …) or a ScoreTarget for a fake-player name (#count). A Selector is wrapped, since it is itself a CommandValue.

Parameters

target

ScoreTargetValue | Selector

Returns

Score


toJson()

toJson(): string

Defined in: core/frontend/nodes/objective.ts:39

Returns

string

Released under the MIT License · Credits