2
안녕하세요이 코드를 사용하여 장면에서 내 개체를 움직이게 (애니메이션 처리)합니다. 하지만 메모리가 누수되어 응답하지 않습니다.corona sdk에서 오브젝트를 이동하는 방법은 무엇입니까?
//transition back
local function goBack()
transition.to (wall2, { time = 10000, x = 100, y = 310, onComplete = startTransition})
transition.to (wall, { time = 10000, x = 700, y = 200, onComplete = startTransition})
transition.to (gate_a, { time = 10000, x = 100, y = 255, onComplete = startTransition})
transition.to (stargate_a, { time = 10000, x = 100, y = 255, onComplete = startTransition})
end
//transition start
function startTransition()
transition.to (wall2, { time = 10000, x = 700, y = 310, onComplete = goBack})
transition.to (wall, { time = 10000, x = 100, y = 200, onComplete = goBack})
transition.to (gate_a, { time = 10000, x = 700, y = 255, onComplete = goBack})
transition.to (stargate_a, { time =10000, x = 700, y = 255, onComplete = goBack})
end
startTransition()
메모리 누수없이 개체를 올바르게 이동하려면 어떻게해야합니까?