- 다중 젬 슬롯용 타입을 별도 스크립트로 분리하고 테스트 젬/로드아웃 자산 생성 경로를 정리 - 젬 테스트 전용 공격 스킬과 분리된 애니메이션 자산을 추가해 베이스 스킬 검증 경로를 마련 - PlayerSkillDebugMenu와 MPP 디버그 메뉴를 보강해 젬 프리셋 적용, 원격 테스트, 보스 기절 디버그 메뉴를 추가 - BossCombatBehaviorContext와 공통 BT 액션이 기절 상태를 존중하도록 수정해 보스 추적과 패턴 실행을 중단 - Unity 리프레시와 외부 빌드 통과를 확인하고 드로그전 및 MPP 기준 젬 프리셋 적용 흐름을 검증
50 lines
1.5 KiB
C#
50 lines
1.5 KiB
C#
using System;
|
|
|
|
using Colosseum.Enemy;
|
|
|
|
using Unity.Behavior;
|
|
using Unity.Properties;
|
|
using UnityEngine;
|
|
|
|
using Action = Unity.Behavior.Action;
|
|
|
|
/// <summary>
|
|
/// 보스의 주 대상을 갱신하는 공통 Behavior Action입니다.
|
|
/// </summary>
|
|
[Serializable, GeneratePropertyBag]
|
|
[NodeDescription(
|
|
name: "Refresh Primary Target",
|
|
story: "보스 주 대상을 [Target]으로 갱신",
|
|
category: "Action",
|
|
id: "b7dbb1fc0c0d451795e9f02d6f4d3930")]
|
|
public partial class RefreshPrimaryTargetAction : Action
|
|
{
|
|
[SerializeReference]
|
|
public BlackboardVariable<GameObject> Target;
|
|
|
|
protected override Status OnStart()
|
|
{
|
|
BossCombatBehaviorContext context = GameObject.GetComponent<BossCombatBehaviorContext>();
|
|
if (context != null && context.IsBehaviorSuppressed)
|
|
return Status.Failure;
|
|
|
|
EnemyBase enemyBase = GameObject.GetComponent<EnemyBase>();
|
|
if (enemyBase == null)
|
|
return Status.Failure;
|
|
|
|
GameObject currentTarget = Target != null ? Target.Value : null;
|
|
float aggroRange = enemyBase.Data != null ? enemyBase.Data.AggroRange : Mathf.Infinity;
|
|
GameObject resolvedTarget = enemyBase.GetHighestThreatTarget(currentTarget, null, aggroRange);
|
|
|
|
if (resolvedTarget == null)
|
|
{
|
|
resolvedTarget = context != null ? context.FindNearestLivingTarget() : null;
|
|
}
|
|
|
|
if (Target != null)
|
|
Target.Value = resolvedTarget;
|
|
|
|
return resolvedTarget != null ? Status.Success : Status.Failure;
|
|
}
|
|
}
|