기존 시스템 재사용 프로토타입 보존

This commit is contained in:
2026-09-01 08:56:15 +09:00
parent 2f6e80fd57
commit b95c5bdb13
58 changed files with 714 additions and 3298 deletions
+16
View File
@@ -17,6 +17,10 @@ namespace Northbound
[Header("Animation")]
public bool playAnimations = true;
[Header("Secondary Action")]
[Tooltip("우클릭으로 실행할 액션 이름. 비어 있으면 사용하지 않습니다.")]
public string secondaryActionName = "";
private Dictionary<string, IAction> _actions = new Dictionary<string, IAction>();
private Animator _animator;
private NetworkAnimator _networkAnimator;
@@ -103,6 +107,18 @@ namespace Northbound
ExecuteAction("Attack");
}
private void Update()
{
if (!_isInputInitialized || !IsLocalPlayer || string.IsNullOrEmpty(secondaryActionName)) return;
if (Mouse.current != null && Mouse.current.rightButton.wasPressedThisFrame)
{
if (!UpgradeListPopup.IsOpen && (_networkPlayerController == null || !_networkPlayerController.IsDead()))
{
ExecuteAction(secondaryActionName);
}
}
}
public void ExecuteAction(string actionName)
{
if (_actions.TryGetValue(actionName, out IAction action))