StrikeSuccessionInput
A class in Root.Township, the global namespace.
Skill input that counts a run of good tool hits on a matching channel; reaching the target count activates the skill (a power strike) for a short time, and the next hit uses it. Made by StrikeSuccessionInputStructure.
- Listed in Global namespace: S
- Inherits or implements
ISkillInputMethod
Constructors
| Member | What it is |
|---|---|
StrikeSuccessionInput() | Creates a StrikeSuccessionInput with default values. |
Fields
8 private and internal fields
| Member | What it is |
|---|---|
private AltaCoroutine coroutine | The running timer coroutine. |
private int currentCount | Hits counted so far in this run. |
private bool isActive | Whether the power strike is ready. |
private bool isCalledThisFrame | Stops more than one hit counting in the same frame. |
private float lastActiveTime | Real time the skill was last used, for the cool down. |
private PickupBasedSkill skill | The skill to execute on the finishing hit. |
private StrikeSuccessionInputStructure structure | Settings asset with the timings, channel and counts. |
private int targetCount | Hits needed to activate, from the player's skill level. |
Properties
| Member | What it is |
|---|---|
HeldPickupHandler Handler { get; private set; } | The held pickup handler this input belongs to. |
3 private and internal properties
Events
| Member | What it is |
|---|---|
event Action<bool, ISkillInputMethod> ChangedActive | Raised when the power strike becomes ready or runs out. |
static event SuccessionStrikeDelegate StrikeCountUpdate | Static event raised with the player, skill and new count every time the count changes. |
Methods
| Member | What it is |
|---|---|
bool IncreaseCount() | Adds one to the count without a hit (used by BlockingCharge); returns true when it reaches the target and activates. |
void Reset(bool isCallingEvent) | Sets the count to zero, deactivates and stops the timer. |
6 private and internal methods
| Member | What it is |
|---|---|
private void ISkillInputMethod.Clear() | Resets the count and deactivates. |
private bool ISkillInputMethod.ReceiveHit(HeldPickupHandler handler, ImpactHitWithTool hitWithTool, ProfessionSkill skill) | Counts a hit if effective enough and on the target channel, starts timers, activates at the target count and runs the skill on the hit after that. |
private void ISkillInputMethod.RegisterHandler(HeldPickupHandler pickupHandler, SkillInputStructure structure, ProfessionSkill skill) | Stores the handler, skill and structure, and works out the strike count for the player's level. |
private IEnumerator RunTime(float time, Pickup pickup) (iterator) | Coroutine that waits the combo or power strike window, then deactivates and resets the count. |
private void StopCoroutine() | Stops the running timer coroutine. |
private void ISkillInputMethod.Update() | Does nothing. |