Thank you all for helping me out. I got the code to work.
If you look at the original this is what I added.
local number = 0 local textField = display.newText(number, 30, 30, native.systemFont, 25) local function moveIt(event) number = number + 1 textField:removeSelf() textField = display.newText(number, 30, 30, native.systemFont, 25) for i = number,#fruitsTransition do transition.to(event.target, fruitsTransition[i] ) return true end end
This is how the program runs. Now that you see it is there a more efficient way of writing this code? Keep I mind I am looking to make this scalable where it can handle multiple transitions with more objects in various positions on the screen in the future. Consider this level 1.
Any guidance will help. Thank you.
[sharedmedia=core:attachments:7342]