feat: 드로그 기본 루프 게이트를 BT로 이관
- big pattern grace period 판정을 런타임 헬퍼에서 제거하고 BT 조건/액션 노드로 명시 - Increment/Reset Basic Loop Count 노드 추가 및 BT_Drog 재빌드 반영 - Signature Failure Effects 수치를 BT 노드가 직접 보관하도록 정리
This commit is contained in:
@@ -0,0 +1,37 @@
|
||||
using System;
|
||||
|
||||
using Colosseum.Enemy;
|
||||
|
||||
using Unity.Behavior;
|
||||
using Unity.Properties;
|
||||
using UnityEngine;
|
||||
|
||||
using Action = Unity.Behavior.Action;
|
||||
|
||||
/// <summary>
|
||||
/// 마지막 대형/징벌 패턴 이후 기본 루프 누적 횟수를 증가시킵니다.
|
||||
/// </summary>
|
||||
[Serializable, GeneratePropertyBag]
|
||||
[NodeDescription(
|
||||
name: "Increment Basic Loop Count",
|
||||
story: "기본 루프 누적 횟수를 [Count]만큼 증가",
|
||||
category: "Action",
|
||||
id: "fd1dc402-c0d7-4cf7-a97f-79d999c36f8d")]
|
||||
public partial class IncrementBasicLoopCountAction : Action
|
||||
{
|
||||
[SerializeReference]
|
||||
[Tooltip("증가시킬 기본 루프 횟수")]
|
||||
public BlackboardVariable<int> Count = new BlackboardVariable<int>(1);
|
||||
|
||||
protected override Status OnStart()
|
||||
{
|
||||
BossBehaviorRuntimeState runtimeState = GameObject.GetComponent<BossBehaviorRuntimeState>();
|
||||
if (runtimeState == null)
|
||||
return Status.Failure;
|
||||
|
||||
int appliedCount = Mathf.Max(0, Count?.Value ?? 0);
|
||||
runtimeState.IncrementBasicLoopCount(appliedCount);
|
||||
runtimeState.LogDebug(nameof(IncrementBasicLoopCountAction), $"기본 루프 누적 증가: +{appliedCount} => {runtimeState.BasicLoopCountSinceLastBigPattern}");
|
||||
return Status.Success;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user