Skip to main content

WyrmSpitSettings

A class in Root.Township, Alta.Intelligence.Wyrms.

Action settings for a wyrm's spit attack (ActiveSpit), scored by distance, hurt and whether the target is the same as before.

Constructors​

MemberWhat it is
WyrmSpitSettings()Unity makes components itself; use AddComponent or spawn a prefab instead of new.

Fields​

7 private and internal fields
MemberWhat it is
private string animatedAngleBacking field for AnimatedAngle, the animator float set to the aim angle (default Aim Angle).
private float bestRangeBacking field for BestRange, the distance that scores best for spitting.
private float changeTargetMultiplierBacking field for ChangeTargetMultiplier.
private float hurtWeightingBacking field for HurtWeighting.
private float maximumRangeBacking field for MaximumRange, beyond which targets score zero.
private float sameTargetMultiplierBacking field for SameTargetMultiplier.
private string[] spitTriggersAnimator triggers, one picked at random per spit.

Properties​

MemberWhat it is
string AnimatedAngle { get; }Animator float for the aim angle.
float BestRange { get; }Distance it most likes to spit from.
float ChangeTargetMultiplier { get; }Score multiplier when the target is a new one.
float HurtWeighting { get; }Weight of the hurt rule, so targets that hurt it score higher.
float MaximumRange { get; }Furthest distance it spits from.
float SameTargetMultiplier { get; }Score multiplier when the target is the same as before.

Methods​

MemberWhat it is
string GetRandomSpitTrigger()Picks one of the spit animator triggers at random.
protected override IAction GetAction()Creates the ActiveSpit action.

Used in​

Members of other types that take, return or hold a WyrmSpitSettings: