feat: 아군 타게팅 시스템 구현 — SingleAlly 투사체형 치유/보호막

- 치유/보호막 스킬을 즉발 자가시전에서 투사체형 아군 1인 타겟팅으로 전환

- TargetType.SingleAlly 추가, targetOverride 매개변수로 외부 타겟 주입 지원

- PlayerSkillInput: 카메라 레이캐스트 기반 아군 탐지, 서버 검증, RPC 타겟 ID 전달

- AllyTargetIndicator: 호버 아군 위에 디스크 인디케이터 표시, 사거리/초과 색상 변경

- SpawnEffect: 타겟 방향 회전 보정

- 투사체 스폰 이펙트 에셋 생성 (치유/보호막 각각)

- 인디케이터 프리팹 + URP/Unlit 머티리얼 생성

- Player 프리팹에 AllyTargetIndicator 컴포넌트 추가 및 설정

- Input.mousePosition → Mouse.current.position.ReadValue() 수정 (Input System 호환)
This commit is contained in:
2026-03-31 23:06:13 +09:00
parent 2c6a65d406
commit 106e53c9aa
22 changed files with 6779 additions and 112 deletions

View File

@@ -87,13 +87,18 @@ namespace Colosseum.Skills.Effects
private Quaternion GetSpawnRotation(GameObject caster, GameObject target)
{
if (target != null && (spawnLocation == SpawnLocation.Target || spawnLocation == SpawnLocation.CasterForward))
// target이 있으면 항상 target 방향 우선 (SingleAlly 타게팅 지원)
if (target != null && target != caster)
{
Vector3 lookDirection = target.transform.position - caster.transform.position;
if (lookDirection.sqrMagnitude > 0.0001f)
return Quaternion.LookRotation(lookDirection);
}
// target이 없으면 spawnLocation 기준
if (spawnLocation == SpawnLocation.Target)
return caster.transform.rotation;
return caster.transform.rotation;
}
}