Skip to content

DenyOptions beta ​

Interface of @v12-engine/engine

ts
export interface DenyOptions

Denying, as in a MOBA (features-plan E): a player may tell their units to attack one of their own side's, which they never do by themselves, once it is low enough on health that the other side would soon have it: the last hit on it is theirs, not the enemy's. Hooks for Rules.hooks:

hooks: [...denying( below: 0.5 )]

Only an attack a player orders (CanAttack.ordered): units never pick their own side to attack, nor fight back at it

Members ​

below ​

ts
below?: number;

How low on health, of its most, one of one's own side has to be to be attacked: below half when left out

denies ​

ts
denies?: (world: World, attacker: Entity, target: Entity) => boolean;

What of one's own side may be attacked, past below: units, not heroes nor structures, when left out. A game's own, to let towers be denied, or only creeps

id ​

ts
id?: string;

The id of the hook, to replace or leave out: deny when left out