loop and scroll

fixed loop and scroll