I need help making a picture move in a scene to a certain point, and then back to it's starting point and loop.
I know how to do the loop, and I know how to move the picture (horizontally)
But how would i make it move from x = -40 to around x = 10, then back down to x = -40 and repeat endlessly?
i made an example of such here of generating a circular pattern: http://forum.chaos-project.com/index.php/topic,12208.0/topicseen.html
all you would have to do is put that in a update method and check it against the x/y value and move acordingly, if your just wanting to go back and forth repetively, you could use a true/false variable to track its current direction, example:
if left_to_right = true
@x += 1
else
@x-= 1
end