Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How to ping-pong a train?
#4
Hi
1- Once the locomotive reached the end, modify the Position and/or MovementDirection and/or other properties of the other controllers to have them do what they are supposed to do.
2- Add a listener like this
OnEndReached.AddListener(Listener);
while having the following method:
void Listener(CurvySplineMoveEventArgs arg0)
{
//your code
}
3- MovementDirection = MovementDirection.Backward;

Don't forget to look at the existing code (using CTRL+SHIFT+F if using visual studio, or the Find all References entry in the right click menu) to see how some specific member is used, it can help you understand how to use it in the future.

Was all this clear?
Please consider leaving a review for Curvy. This will help a lot keeping Curvy relevant in the eyes of the Asset Store algorithm.
Reply


Messages In This Thread
How to ping-pong a train? - by jamesunity - 07-10-2020, 11:19 AM
RE: How to ping-pong a train? - by _Aka_ - 07-10-2020, 11:34 AM
RE: How to ping-pong a train? - by jamesunity - 07-10-2020, 11:49 AM
RE: How to ping-pong a train? - by _Aka_ - 07-11-2020, 03:05 PM
RE: How to ping-pong a train? - by jamesunity - 07-13-2020, 11:14 AM
RE: How to ping-pong a train? - by _Aka_ - 07-13-2020, 11:56 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
Wink Train carriage with 2 bogies following a path arcadeperfect 9 27 08-25-2023, 02:56 PM
Last Post: arcadeperfect
  Train car orientation on slopes bennidhamma@gmail.com 3 1,027 03-26-2021, 10:30 AM
Last Post: _Aka_
  Player to Train DeadCcell 3 1,211 12-08-2020, 08:07 AM
Last Post: _Aka_
  Train tracks with transparent middle? jh092 4 2,250 07-03-2020, 07:13 PM
Last Post: _Aka_

Forum Jump: