added lerp, changed main loop