Parallax - Swipe/Spring Effect need help!

While ago, Brent Sorrentino post a tutorial on the blog called Parallax Simplified

I was wondering if somebody could help me add some swipe and spring effects to the touch event. I’m looking at the same effect as when you scroll with a Tableview in iOS, with some residual movement that slows down gradually when you remove your finger after a swipe and the spring effect when you reach the edge.

Any ideas please??  This is the missing piece before the end of my project! :slight_smile:

This is the touch event code:

 &nbsp; local function touchScreen( event ) &nbsp; &nbsp; &nbsp; local stageID = event.target &nbsp; &nbsp; &nbsp; local refGroup = stageID.refGroup ; local paraGroups = stageID.paraGroups &nbsp; &nbsp; &nbsp; local eventX = event.x ; local eventY = event.y &nbsp; &nbsp; &nbsp; if ( #paraGroups \< 1 ) then return end &nbsp; &nbsp; &nbsp; if ( event.phase == "began" ) then &nbsp; &nbsp; &nbsp; &nbsp; for i=1,#paraGroups do &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; paraGroups[i].offsetX = eventX - refGroup.x &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; paraGroups[i].offsetY = eventY - refGroup.y &nbsp; &nbsp; &nbsp; &nbsp; end &nbsp; &nbsp; &nbsp; elseif ( event.phase == "moved" ) then &nbsp; &nbsp; &nbsp; &nbsp; local xDif = eventX - refGroup.offsetX &nbsp; &nbsp; &nbsp; &nbsp; local yDif = eventY - refGroup.offsetY &nbsp; &nbsp; &nbsp; &nbsp; --If you are NOT limiting the boundaries of your world, comment out these 2 lines. &nbsp; &nbsp; &nbsp; &nbsp; if ( xDif \< stageID.xMin ) then xDif = stageID.xMin elseif ( xDif \> stageID.xMax ) then xDif = stageID.xMax end &nbsp; &nbsp; &nbsp; &nbsp; if ( yDif \< stageID.yMin ) then yDif = stageID.yMin elseif ( yDif \> stageID.yMax ) then yDif = stageID.yMax end &nbsp; &nbsp; &nbsp; &nbsp; for i=1,#paraGroups do &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; local group = paraGroups[i] &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; group.x = xDif \* group.distanceRatio &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; group.y = yDif \* group.distanceRatio &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; group = nil &nbsp; &nbsp; &nbsp; &nbsp; end &nbsp; &nbsp; &nbsp; &nbsp; xDif, yDif = nil,nil &nbsp; &nbsp; &nbsp; end &nbsp; &nbsp; &nbsp; stageID, refGroup, paraGroups, eventX, eventY = nil,nil,nil,nil,nil &nbsp; &nbsp; &nbsp; return true &nbsp; &nbsp; end&nbsp; &nbsp; stage:addEventListener( "touch", touchScreen )&nbsp; &nbsp;