FlinchState Class

Summary

A PlatformerGameKit.Characters.States.CharacterState that plays a PlatformerGameKit.Characters.States.FlinchState.FlinchAnimation when the PlatformerGameKit.Health.CurrentHealth changes and a PlatformerGameKit.Characters.States.FlinchState.DieAnimation when it reaches 0.
Assembly
PlatformerGameKit.dll
Namespace
PlatformerGameKit.Characters.States
Interfaces
Base Types
graph BT Type-->Base0["CharacterState"] click Base0 "/platformer/api/PlatformerGameKit.Characters.States/CharacterState" Base0-->Base1["StateBehaviour"] Type-.->Interface0["IOwnedState<CharacterState>"] Type["FlinchState"] class Type type-node

Syntax

[AddComponentMenu(MenuPrefix + "Flinch State")]
[HelpURL(APIDocumentation + nameof(FlinchState))]
public sealed class FlinchState : CharacterState, IOwnedState<CharacterState>

Remarks

Documentation: Flinch

Attributes

Type Description
AddComponentMenu
HelpURLAttribute

Fields

Name Constant Value Summary
APIDocumentation https://kybernetik.com.au/platformer/api/PlatformerGameKit.Characters.States/
The URL of the website where the PlatformerGameKit.Characters.States API documentation is hosted.
Inherited from CharacterState
static
MenuPrefix Platformer Game Kit/Characters/States/
The menu prefix for UnityEngine.AddComponentMenu.
Inherited from CharacterState
static

Properties

Name Value Summary
CanExitState bool
CanTurn bool
Character Character
The Examples.PlatformerCharacter that owns this state.
Inherited from CharacterState
DieAnimation ClipTransition
FlinchAnimation ClipTransition
MovementSpeedMultiplier float
OwnerStateMachine StateMachine<CharacterState>
Inherited from CharacterState

Methods

Name Value Summary
OnEnterState() void
OnExitState() void
OnValidate() void
[Editor-Only] Ensures that all fields have valid values and finds missing components nearby.
Inherited from CharacterState
ReloadCurrentScene() void
Reloads the current scene.
SetCharacter(Character) void
Sets the PlatformerGameKit.Characters.States.CharacterState.Character.
Inherited from CharacterState