thank you guys for trying to help me but I found out how to fix the code, I tried to use 'display.remove(obj) and it worked fine:
1-transition.to(object, {time = green.speed, y = -60, onComplete = function(obj) display.remove(obj) end})
this works fine,
I have another question, can I call to functions with ‘onComplete’ ?