去掉obi,使用自写绳索
This commit is contained in:
@@ -1,23 +0,0 @@
|
||||
using UnityEngine;
|
||||
|
||||
namespace Obi
|
||||
{
|
||||
public class ObiRopeAttach : MonoBehaviour
|
||||
{
|
||||
public ObiPathSmoother smoother;
|
||||
[Range(0,1)]
|
||||
public float m;
|
||||
|
||||
public void LateUpdate()
|
||||
{
|
||||
if (smoother != null && smoother.actor.isLoaded)
|
||||
{
|
||||
var trfm = smoother.actor.solver.transform;
|
||||
ObiPathFrame section = smoother.GetSectionAt(m);
|
||||
transform.position = trfm.TransformPoint(section.position);
|
||||
transform.rotation = trfm.rotation * Quaternion.LookRotation(section.tangent, section.binormal);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user