2026-04-13 스킬시스템 진행중

This commit is contained in:
2026-04-13 01:42:32 +09:00
parent ba93dc6d2f
commit b2cceb5b27
20 changed files with 1243 additions and 37 deletions

View File

@@ -116,10 +116,45 @@ private void Awake()
_renderers = GetComponentsInChildren<Renderer>();
}
// 범위 지정 중 회전모드 복구용
private PlayerRotationMode _rotationModeBeforeAreaSelect;
private SkillModule _skillModule;
private void Start()
{
_stateMachine.SetMaxJumpCount(_maxJumpCount);
SetCursorLockState(true);
// 범위 지정 이벤트 구독 — 회전모드만 토글 (이동은 영향 없음)
_skillModule = GetComponent<SkillModule>();
if (_skillModule != null)
{
_skillModule.OnAreaSelectStarted += HandleAreaSelectStarted;
_skillModule.OnAreaSelectEnded += HandleAreaSelectEnded;
}
}
private void OnDestroy()
{
if (_skillModule != null)
{
_skillModule.OnAreaSelectStarted -= HandleAreaSelectStarted;
_skillModule.OnAreaSelectEnded -= HandleAreaSelectEnded;
}
}
private void HandleAreaSelectStarted()
{
_rotationModeBeforeAreaSelect = RotationMode;
RotationMode = PlayerRotationMode.CameraDecoupled;
SetCursorLockState(false); // 마우스 자유 이동
}
private void HandleAreaSelectEnded()
{
RotationMode = _rotationModeBeforeAreaSelect;
SetCursorLockState(true);
}
public void PlayerStart()