Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Moving multiple controllers at once
#13
So after getting side tracked for way too long trying to learn about ways to get around weird quirks in Unity, I'm finally at the point there I can interact with the controllers. Unfortunately I don't understand the syntax on how to do that. Sad

What I want it to make is:
  • A foreach loop and store all the absolute positions of the controllers from this, and store it in a new array.
Code:
var selectedControllers = Selection.transforms.Select(t => t.gameObject.GetComponent<SplineController>()).Where(c => c != null).ToList();
  • How to set those objects to a new absolute position based on the new modified array.
  • How to get the end point of the controllers splines as an absolute value.
Reply


Messages In This Thread
Moving multiple controllers at once - by Lupp_ - 01-15-2020, 07:46 PM
RE: Moving multiple controllers at once - by Lupp_ - 02-02-2020, 04:57 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Distance travelled across multiple splines jh092 1 7 02-23-2024, 09:44 AM
Last Post: _Aka_
  Best practice for controllers slowing down/speeding up along the spline Curry 1 5 08-06-2023, 09:47 PM
Last Post: _Aka_
  Moving object down or up the spline using gravity velikizlivuk 6 19 07-26-2023, 10:06 PM
Last Post: _Aka_
  Multiple Splines and Generators Performantly for Road System drock 1 6 07-17-2023, 10:31 AM
Last Post: _Aka_

Forum Jump: