title: Trouble with the flow in lua/corona sdk codes
body: <p>I'm very confused about the flow of the programs in corona sdk.</p>
  
  <p>What I want to make is that the flow continues when the transition is over, I know I can use Oncomplete but I do not know how to use it in this case.</p>
  
  <p>I have this code:</p>
  
  <pre><code>while ban == 2 do  
      actual = x
      desplazar = x
      while actual &gt;= 0  do 
          actual = actual - 4
          if inTable(t,actual) then
              while inTable(t,actual) and actual &gt;=0 do
                  actual= actual - 4
              end
          end       
      if actual &gt;= 0 then
           banaux=1  
           if inTable(t, desplazar) then
               block[desplazar].value=0
               block[desplazar]:removeSelf()
               for z=1, tablelength(t) do
                    if t[z] == desplazar then
                    t[z]=32
               end  
           end  
      end   
      transition.to(block[actual], {time=velocity, x=block[desplazar].x, y=block[desplazar].y})
      cambiodesp(actual,desplazar)
      desplazar = desplazar - 4 
    end        
   end
   x = x -1
   if inTable(t,x) then
   else
      ban = 1    
   end    
  end
  </code></pre>
  
  <p>I'm getting a lot of unexpected result because of the transitions, I supposed that the code keep running although the transition haven't finished, I want to make something for run the above code when the transition is complete, but I think I cannot use the oncomplete.</p>
  
  <p>I want to make keep running when this is complete </p>
  
  <pre><code>transition.to(block[actual], {time=velocity, x=block[desplazar].x, y=block[desplazar].y})
  </code></pre>
  
  <p>I'm not understanding how the flow of the code is working, so hope you can explain to me that</p>