스킬 시스템에 루트 모션 지원 추가

- SkillData: useRootMotion, ignoreRootMotionY 설정 추가
- SkillController: 루트 모션 관련 프로퍼티 노출
- PlayerMovement: OnAnimatorMove로 스킬 애니메이션의 이동/회전 데이터 적용
- Y축 무시 옵션으로 중력 및 충돌 처리 유지 가능

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-03-10 12:34:37 +09:00
parent eff23471d7
commit 680aacf580
4 changed files with 94 additions and 3 deletions

View File

@@ -32,7 +32,10 @@ namespace Colosseum.Skills
public bool IsExecutingSkill => currentSkill != null && !skillEndRequested;
public bool IsPlayingAnimation => currentSkill != null;
public bool UsesRootMotion => currentSkill != null && currentSkill.UseRootMotion;
public bool IgnoreRootMotionY => currentSkill != null && currentSkill.IgnoreRootMotionY;
public SkillData CurrentSkill => currentSkill;
public Animator Animator => animator;
private void Awake()
{

View File

@@ -21,6 +21,12 @@ namespace Colosseum.Skills
[Tooltip("종료 애니메이션 (선택)")]
[SerializeField] private AnimationClip endClip;
[Header("루트 모션")]
[Tooltip("애니메이션의 이동/회전 데이터를 캐릭터에 적용")]
[SerializeField] private bool useRootMotion = false;
[Tooltip("루트 모션 적용 시 Y축 이동 무시 (중력과 충돌)")]
[SerializeField] private bool ignoreRootMotionY = true;
[Header("쿨타임 & 비용")]
[Min(0f)] [SerializeField] private float cooldown = 1f;
[Min(0f)] [SerializeField] private float manaCost = 0f;
@@ -37,6 +43,8 @@ namespace Colosseum.Skills
public AnimationClip EndClip => endClip;
public float Cooldown => cooldown;
public float ManaCost => manaCost;
public bool UseRootMotion => useRootMotion;
public bool IgnoreRootMotionY => ignoreRootMotionY;
public IReadOnlyList<SkillEffect> Effects => effects;
}
}