Skip to main content

ShakeInputStructure

A class in Root.Township, the global namespace.

Skill input asset for profession skills triggered by shaking a held item. Makes a ShakeInput for each use.

Constructors​

MemberWhat it is
ShakeInputStructure()Use ScriptableObject.CreateInstance instead of new; Unity loads the saved ones from assets.

Fields​

5 private and internal fields
MemberWhat it is
private float fadePerSecondBacking field for FadePerSecond.
private float heldDeactivationBacking field for HeldDeactivation.
private float jumpPerChangeBacking field for JumpPerChange.
private float thresholdBacking field for Threshold.
private float velocityThresholdSquaredBacking field for VelocityThresholdSquared.

Properties​

MemberWhat it is
float FadePerSecond { get; }How fast built-up shake strength fades away.
float HeldDeactivation { get; }Seconds the input stays active after a shake before it switches off again.
float JumpPerChange { get; }Strength added for a full reversal of direction.
float Threshold { get; }Strength needed to count as a shake.
float VelocityThresholdSquared { get; }Squared speed the held item must reach before a direction change counts.

Methods​

MemberWhat it is
override ISkillInputMethod GetNewInput()Returns a new ShakeInput that reads these settings.

Used in​

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