hi i just wanted to know how to make a ball go forward and backwards forever and also change the speed i have been able to make it go forward and stop at the wanted point and also to come back but then it just goes on forever.
1. What is +x ? x. The + will not change the sign.
2. You want to move between A and B, where A<B?
IF you have advanced "up" to C, where B<C, THEN change direction to "down"
IF you have retreated "down" to D, where D<A, THEN change direction to "up"