using UnityEngine;

namespace FishROV.AvoidanceBenchmark
{
    public sealed class UnavailableAvoidanceAdapter : IAvoidanceAdapter
    {
        private readonly AvoidanceFrameworkKind kind;

        public UnavailableAvoidanceAdapter(AvoidanceFrameworkKind kind)
        {
            this.kind = kind;
        }

        public string Name => kind.ToString();
        public bool IsAvailable => false;
        public string Status => "当前方案在这个 worktree 中只是占位；请选择本分支要测试的避障方案。";

        public void Initialize(AvoidanceBenchmarkConfig config)
        {
        }

        public BenchmarkAgent CreateAgent(BenchmarkAgentSpawnInfo spawnInfo, Transform parent)
        {
            return BenchmarkAgent.CreatePrimitive(spawnInfo, parent);
        }

        public void SetPreferredVelocity(BenchmarkAgent agent, Vector3 preferredVelocity)
        {
            agent.ApplyVelocity(preferredVelocity);
        }

        public void SetTarget(BenchmarkAgent agent, Vector3 target)
        {
            agent.Target = target;
        }

        public void Tick(float deltaTime)
        {
        }

        public void Dispose()
        {
        }
    }
}
