Expand description
Native ports for the cast_projectile category — projectile scripts (the
CastProjectile event handler, run via run_event in
logic::fighting::handle_cast_projectile, returning
Vec<OverlordEvent>).
Every shipped projectile script is ctx.attack(CasterEntity, TargetEntity, #{ ... }) with a per-projectile param map, resolved from a sibling ability’s
get_ability_info(<ability_id>, ProjectileLevel):
- plain damage:
#{ power: ability_info.damage } - DoT split:
#{ power: ability_info.damage, dot_power: ability_info.dot } - vampiric:
attack{power}, thenif (damage > 0) heal_entity(caster, damage * vampiric) - counterattack:
#{ power: balance::COUNTERATTACK_POWER, no_counterattack: true }
§RNG
attack consumes the authoritative Random (evasion / counterattack /
deceit / crit / block throws).
§Scope
CasterEntity, TargetEntity, Fight, Random, ProjectileLevel,
CustomEventData, CurrentTick, FightDurationTicks, the event.
Structs§
- Cast
Projectile Ctx - Inputs available to a
cast_projectilenative fn.
Functions§
- arcane_
missiles_ attack 0196a6b3-...—attack(#{ power }), info from ability019589e6.- attack_
power_ dot 01966cbc-...—attack(#{ power: damage, dot_power: dot }), info from ability01958172.- attack_
vampiric 0196a6b4-...— vampiric:attack(#{ power }); if damage dealt (> 0in- bat_
attack 019a0244-aad4-...—attack(#{ power }), info from ability019a0246-cf87.- chipmunk_
attack 019a0244-7a0a-...—attack(#{ power }), info from ability019a0246-5aaf.- counterattack
019aeeed-...— counterattack:attack(#{ power: COUNTERATTACK_POWER, no_counterattack: true }). Noget_ability_info.- damage_
target_ 5 - Port of the test projectile
scriptResult.push(OverlordEventDamage(TargetEntity.id, unsigned(5), CustomEventData()));— raw 5 damage to the target. RNG-free; used bytest_fighting_abilities. - mushroom_
attack 019a0244-4675-...—attack(#{ power }), info from ability019a0245.- register
- Register this category’s native fns.
- shot_
attack 019c009c-...—attack(#{ power }), info from ability019c00a4.
Type Aliases§
- Cast
Projectile Fn - Signature of a
cast_projectilenative fn.