I need to remove the timer from the exitScene function as I remove all the listeners but I didn't found how. This is the code:
function scene:enterScene(event)
planeta.enterFrame = rotarPlaneta
Runtime:addEventListener("enterFrame", planeta)
Runtime:addEventListener("touch", touchScreen)
timer.performWithDelay( 1000, throwBrickEnemigo,0 )
end
function scene:exitScene(event)
Runtime:removeEventListener("enterFrame", planeta)
Runtime:removeEventListener("enterFrame", touchScreen)
Runtime:removeEventListener("enterFrame", planeta)
end