So.
I did a lot of investigations. Reading tutorials. Also checking the touch function.
But. In fact.
I will not work. On both devices. The S5 is more powerfull and it slows down later.
But also slows after 4-5 minutes.
###edit
What i did also.
– deactivate the collision lisitener. No effect. Also slow down.
####### FOUND IT ###########
####### SOLUTION ##########
What i did. Particles… I am drawing the flame on the ship.
This is done via Particle engine. But not once!! I drawed every frame a new particle!
With a very short emitter time (duration). But still every frame a new particle.
You cant see that on the screen. But after a while i think the engine is overloaded.
So. Put the “duration” to -1 and draw it one time.
Solved the problem with the touch…
Hope this helps anyone anytime.
####### SOLUTION ##########
FPS drops at 1:00 app…
[media]https://www.youtube.com/watch?v=j1MCiSHxGrM[/media]
-- TOUCH INPUT ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- local TextEvent = display.newText( " ", 500, 460, "font", 24 ) TextEvent:setFillColor( 1, 1, 1 ) function getTouchControls() ---------------------------------------------------------- function touchListener(event) local phase=event.phase local texterid = tostring(event.id) if TouchIdSave==nil then TouchIdSave=texterid end TextEvent.text = ""..TouchIdSave.."" if phase == "began" and TouchIdSave==texterid then tempBody = display.newCircle(event.x, event.y, 24) tempBody:setFillColor( 0.8, 0.2, 0.2,0.5 ) physics.addBody(tempBody) tempBody.isSensor = true tempBody.isVisible=true tempBody.joint = physics.newJoint("touch", tempBody, event.x, event.y) ---------------------------------------------------------- function tempBody.enterFrame(event) if tempBody~=nil then local vx, vy = tempBody:getLinearVelocity() if vx\>=500 then vx=500 elseif vx\<=-500 then vx=-500 end if vy\>=500 then vy=500 elseif vy\<=-500 then vy=-500 end myShip:setLinearVelocity(vx, vy) end end ---------------------------------------------------------- Runtime:addEventListener("enterFrame", tempBody) ---------------------------------------------------------- elseif phase == "moved" and tempBody~=nil and TouchIdSave==texterid then tempBody.joint:setTarget(event.x, event.y) elseif TouchIdSave==texterid and phase == "cancelled" or phase == "ended" then Runtime:removeEventListener("enterFrame", tempBody) if tempBody~=nil then display.remove(tempBody.joint) tempBody.joint=nil display.remove(tempBody) tempBody=nil end if TouchIdSave~=nil then display.remove(TouchIdSave) TouchIdSave=nil end end return true end ---------------------------------------------------------- Runtime:addEventListener("touch", touchListener) end