Rotation using API transition
Can you do the same with less lines and single-image program?
local numero = display.newImage( "cinco.png" ) numero.x = display.contentCenterX numero.y = display.contentCenterY local listener1 = function( obj ) numero:removeSelf() numero = nil local numero2 = display.newImage( "cinco2.png" ) numero2.x = display.contentCenterX numero2.y = display.contentCenterY transition.to( numero2.path, { time=2000, x1=434, y1=0, x2=434, y2=0, x3=-434, y3=0, x4=-434, y4=0, } ) end transition.to( numero.path, { time=2000, x1=434, y1=0, x2=434, y2=0, x3=-434, y3=0, x4=-434, y4=0, onComplete=listener1 } )