Touch - Swipe one image after another for each swipe

Am not quiet sure which is the best approach for the following situation.

There will be 4 images[sprites] in the screen with the numbers 1 to 4, when the user slide left or right each time, the images 1 to 4 need to slide one after another in the order of swipe from 1 to 4.

The movement need to have a ease in and ease out.

Thanks. Any suggestion would be appreciated.

there are thousands possible ways.
i would prefer an old gui system for this, for me its a simplest way because of my habit… but some others will do it via planes in front of camera, or 2d sprites, or new ui system… its all about your own habits and other project features that could make some of approaches more suitable.

I did able to find a simple way to solve this, may be not a perfect one. But it fits the requirement, Hope in future if some one stumble across this issue, this answer might be helpful.


1.I have created a rigidbody to the images to have a dynamic movement as per the finger touch and drag(Touch screen). If you need a simple movememnt, avoid the rigidbody as it is expensive in terms of memory. But for my case, I have used rigidbody.
2. Created a array of prefabs and referenced it in the inspector.
3. In touch horizontal movement, for each touch swipe, I have added a force to move images [Velocity].
4. Once the image reach its limit, the velocity is set to zero[].

Sounds like you’re looking for a ScrollRect.

Add one to your Canvas hierarchy and add a child GameObject to it, which can act as a parent to the 4 images. Personally, I’d put a HorizontalLayoutGroup on that GameObject too, to handle to layout of the 4 images.

Further reference here.