Skip to content

pickAttack beta ​

Function of @v12-engine/engine

ts
export declare function pickAttack(world: World, attacker: Entity, target: Entity): number;

Which of an attacker's attacks it uses against a target, by place in UnitTypeDef.attacks, as the game's rules pick it (RuleSettings.combat.pickAttack): -1 for none, its attacks reach not where the target is