Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
SplineController.AbsolutePosition or SplineController.RelativePosition to WorldPos?
#2
Let me explain:

When you change RelativePosition or AbsolutePosition of a controller, it's TF is changed. The actual position is applied to the transform in the next call to Refresh() then. To get the resulting position immediately after changing the position, use the source spline with RelativePosition, e.g. SplineController.Spline.Interpolate(SplineController.RelativePosition).

Alternatively, add this to CurvyController.cs (currently untested, but should do the trick):

Code:
/// <summary>
/// Applies the current position to the transform
/// </summary>
/// <remarks>Use this to immediately set the transform after changing AbsolutePosition or RelativePosition!</remarks>
public virtual void Apply()
{
      applyPositionAndRotation(mTF);
}

This will be added to 2.0.5
Reply


Messages In This Thread
RE: SplineController.AbsolutePosition or SplineController.RelativePosition to WorldPos? - by Jake - 01-05-2016, 06:28 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
Wink In SplineController OnPositionReachedList Event is missing shimizu 2 13 02-07-2022, 12:47 PM
Last Post: shimizu
  best way to rotate, change offset, and inset position of splinecontroller object smackledorf 1 24 01-17-2022, 01:39 PM
Last Post: _Aka_
  SplineController slows down approaching connections jh092 5 2,542 08-07-2020, 03:56 PM
Last Post: _Aka_
Brick Strange thing happening when setting RelativePosition curvyuser007 1 1,253 05-17-2020, 09:34 PM
Last Post: _Aka_

Forum Jump: