Perform display object transition with objects in a table by table index

Given are three display-objects in a table which should be transformed (here: call transition.blink method).

The objectIdx table should be iterated and trigger the transition by object index.

This only works once per object.

Any solution to trigger the objects till #objectIdx?

-- display objects local objectTable = { o1, o2, o3 } -- object indexes local objectIdx = { 1, 2, 3, 1, 2, 1, 1, 1, 1 } -- blinkObjects listener local function listener( event ) print( objectIdx[event.count] ) transition.blink( objectTable[objectIdx[ event.count] ], { time = 1 } ) end -- "blinkObjects()" local function blinkObjects( ) timer.performWithDelay( 1000, listener, #objectIdx ) end -- start to blink objects blinkObjects( )