This commit is contained in:
2026-06-11 22:49:50 +07:00
parent 458c338b27
commit e85e66002f
4105 changed files with 1435727 additions and 11 deletions

View File

@@ -0,0 +1,23 @@
using UnityEngine;
using UnityEditor;
using System.Collections.Generic;
namespace Pathfinding {
[CustomEditor(typeof(AnimationLink))]
public class AnimationLinkEditor : EditorBase {
protected override void Inspector () {
var script = target as AnimationLink;
EditorGUI.BeginDisabledGroup(script.EndTransform == null);
if (GUILayout.Button("Autoposition Endpoint")) {
List<Vector3> buffer = Pathfinding.Pooling.ListPool<Vector3>.Claim();
Vector3 endpos;
script.CalculateOffsets(buffer, out endpos);
script.EndTransform.position = endpos;
Pathfinding.Pooling.ListPool<Vector3>.Release(buffer);
}
EditorGUI.EndDisabledGroup();
base.Inspector();
}
}
}