Okay. I hate to admit it but this has me beat.
I have an object which follows an on screen path (which is always changing) autonomously. Behind this I wish to "tow" objects.
I have tried creating extra instances of the main type which, by their nature, follow the path too, but if I want the whole "train" to speed up then due to, I'm guessing, rounding errors etc. the following sprites tend to get closer or further away from the main sprite over time.
There is also the added overhead of having each sprite work out its own path.
I have also tried saving a list of the points that the main sprite passes through and using these to provide the data to position the trailing sprites. Again thats fine until a change of speed is induced, when you get the ripple effect as the saved points get further aparts and so the trailing objects get further away from the leader.
What should I be doing to make the following sprites keep pace with the leader as though they are being towed.
I'm sure I'm overlooking some obvious method.
Graham
I have an object which follows an on screen path (which is always changing) autonomously. Behind this I wish to "tow" objects.
I have tried creating extra instances of the main type which, by their nature, follow the path too, but if I want the whole "train" to speed up then due to, I'm guessing, rounding errors etc. the following sprites tend to get closer or further away from the main sprite over time.
There is also the added overhead of having each sprite work out its own path.
I have also tried saving a list of the points that the main sprite passes through and using these to provide the data to position the trailing sprites. Again thats fine until a change of speed is induced, when you get the ripple effect as the saved points get further aparts and so the trailing objects get further away from the leader.
What should I be doing to make the following sprites keep pace with the leader as though they are being towed.
I'm sure I'm overlooking some obvious method.
Graham