How To Renew the Cycle

That’s pretty much it right there. Just put that if check at the bottom of the for loop (inside the loop) and if true, set y back to 0;

  if (y > 380) {
    y = 0;
  }