chore: initial commit
This commit is contained in:
44
Assets/Scripts/Player/PlayerAnimationConfigSO.cs
Normal file
44
Assets/Scripts/Player/PlayerAnimationConfigSO.cs
Normal file
@@ -0,0 +1,44 @@
|
||||
using UnityEngine;
|
||||
|
||||
namespace BaseGames.Player
|
||||
{
|
||||
[CreateAssetMenu(menuName = "Player/AnimationConfig")]
|
||||
public class PlayerAnimationConfigSO : ScriptableObject
|
||||
{
|
||||
[Header("移动")]
|
||||
public AnimationClip Idle;
|
||||
public AnimationClip Run;
|
||||
public AnimationClip Jump;
|
||||
public AnimationClip Fall;
|
||||
public AnimationClip Dash;
|
||||
|
||||
[Header("墙")]
|
||||
public AnimationClip WallSlide;
|
||||
|
||||
[Header("受伤 / 死亡")]
|
||||
public AnimationClip Hurt;
|
||||
public AnimationClip Dead;
|
||||
|
||||
[Header("弹簧")]
|
||||
public AnimationClip UseSpring;
|
||||
|
||||
[Header("地面攻击(连招序列)")]
|
||||
public AnimationClip[] GroundAttacks;
|
||||
|
||||
[Header("空中攻击")]
|
||||
public AnimationClip AirAttack;
|
||||
public AnimationClip UpAttack;
|
||||
public AnimationClip DownAttack; // 戳击 (Pogo)
|
||||
|
||||
[Header("弹反")]
|
||||
public AnimationClip ParryStart;
|
||||
public AnimationClip ParrySuccess;
|
||||
|
||||
/// <summary>按连招步骤取地面攻击动画,越界自动取最后一个。</summary>
|
||||
public AnimationClip GetAttackClip(int step)
|
||||
{
|
||||
if (GroundAttacks == null || GroundAttacks.Length == 0) return null;
|
||||
return step < GroundAttacks.Length ? GroundAttacks[step] : GroundAttacks[^1];
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user